1 // Copyright 2015 The Chromium OS Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style license that can be 3 // found in the LICENSE file. 4 5 #ifndef SYSTEM_API_DBUS_CRYPTOHOME_DBUS_CONSTANTS_H_ 6 #define SYSTEM_API_DBUS_CRYPTOHOME_DBUS_CONSTANTS_H_ 7 8 namespace cryptohome { 9 const char kCryptohomeInterface[] = "org.chromium.CryptohomeInterface"; 10 const char kCryptohomeServicePath[] = "/org/chromium/Cryptohome"; 11 const char kCryptohomeServiceName[] = "org.chromium.Cryptohome"; 12 // Methods 13 const char kCryptohomeAsyncAddKey[] = "AsyncAddKey"; 14 const char kCryptohomeCheckKey[] = "CheckKey"; 15 const char kCryptohomeMigrateKey[] = "MigrateKey"; 16 const char kCryptohomeRemove[] = "Remove"; 17 const char kCryptohomeGetSystemSalt[] = "GetSystemSalt"; 18 const char kCryptohomeGetSanitizedUsername[] = "GetSanitizedUsername"; 19 const char kCryptohomeIsMounted[] = "IsMounted"; 20 const char kCryptohomeMount[] = "Mount"; 21 const char kCryptohomeMountGuest[] = "MountGuest"; 22 const char kCryptohomeMountPublic[] = "MountPublic"; 23 const char kCryptohomeUnmount[] = "Unmount"; 24 const char kCryptohomeTpmIsReady[] = "TpmIsReady"; 25 const char kCryptohomeTpmIsEnabled[] = "TpmIsEnabled"; 26 const char kCryptohomeTpmIsOwned[] = "TpmIsOwned"; 27 const char kCryptohomeTpmIsBeingOwned[] = "TpmIsBeingOwned"; 28 const char kCryptohomeTpmGetPassword[] = "TpmGetPassword"; 29 const char kCryptohomeTpmCanAttemptOwnership[] = "TpmCanAttemptOwnership"; 30 const char kCryptohomeTpmClearStoredPassword[] = "TpmClearStoredPassword"; 31 const char kCryptohomePkcs11GetTpmTokenInfo[] = "Pkcs11GetTpmTokenInfo"; 32 const char kCryptohomePkcs11GetTpmTokenInfoForUser[] = 33 "Pkcs11GetTpmTokenInfoForUser"; 34 const char kCryptohomePkcs11IsTpmTokenReady[] = "Pkcs11IsTpmTokenReady"; 35 const char kCryptohomePkcs11IsTpmTokenReadyForUser[] = 36 "Pkcs11IsTpmTokenReadyForUser"; 37 const char kCryptohomeAsyncCheckKey[] = "AsyncCheckKey"; 38 const char kCryptohomeAsyncMigrateKey[] = "AsyncMigrateKey"; 39 const char kCryptohomeAsyncMount[] = "AsyncMount"; 40 const char kCryptohomeAsyncMountGuest[] = "AsyncMountGuest"; 41 const char kCryptohomeAsyncMountPublic[] = "AsyncMountPublic"; 42 const char kCryptohomeAsyncRemove[] = "AsyncRemove"; 43 const char kCryptohomeGetStatusString[] = "GetStatusString"; 44 const char kCryptohomeRemoveTrackedSubdirectories[] = 45 "RemoveTrackedSubdirectories"; 46 const char kCryptohomeAsyncRemoveTrackedSubdirectories[] = 47 "AsyncRemoveTrackedSubdirectories"; 48 const char kCryptohomeDoAutomaticFreeDiskSpaceControl[] = 49 "DoAutomaticFreeDiskSpaceControl"; 50 const char kCryptohomeAsyncDoAutomaticFreeDiskSpaceControl[] = 51 "AsyncDoAutomaticFreeDiskSpaceControl"; 52 const char kCryptohomeAsyncDoesUsersExist[] = "AsyncDoesUsersExist"; 53 const char kCryptohomeInstallAttributesGet[] = "InstallAttributesGet"; 54 const char kCryptohomeInstallAttributesSet[] = "InstallAttributesSet"; 55 const char kCryptohomeInstallAttributesCount[] = "InstallAttributesCount"; 56 const char kCryptohomeInstallAttributesFinalize[] = 57 "InstallAttributesFinalize"; 58 const char kCryptohomeInstallAttributesIsReady[] = "InstallAttributesIsReady"; 59 const char kCryptohomeInstallAttributesIsSecure[] = 60 "InstallAttributesIsSecure"; 61 const char kCryptohomeInstallAttributesIsInvalid[] = 62 "InstallAttributesIsInvalid"; 63 const char kCryptohomeInstallAttributesIsFirstInstall[] = 64 "InstallAttributesIsFirstInstall"; 65 const char kCryptohomeStoreEnrollmentState[] = 66 "StoreEnrollmentState"; 67 const char kCryptohomeLoadEnrollmentState[] = 68 "LoadEnrollmentState"; 69 const char kCryptohomeTpmIsAttestationPrepared[] = "TpmIsAttestationPrepared"; 70 const char kCryptohomeTpmIsAttestationEnrolled[] = "TpmIsAttestationEnrolled"; 71 const char kCryptohomeAsyncTpmAttestationCreateEnrollRequest[] = 72 "AsyncTpmAttestationCreateEnrollRequest"; 73 const char kCryptohomeAsyncTpmAttestationCreateEnrollRequestNew[] = 74 "AsyncTpmAttestationCreateEnrollRequestNew"; 75 const char kCryptohomeAsyncTpmAttestationEnroll[] = "AsyncTpmAttestationEnroll"; 76 const char kCryptohomeAsyncTpmAttestationEnrollNew[] = 77 "AsyncTpmAttestationEnrollNew"; 78 const char kCryptohomeAsyncTpmAttestationCreateCertRequest[] = 79 "AsyncTpmAttestationCreateCertRequest"; 80 const char kCryptohomeAsyncTpmAttestationCreateCertRequestByProfile[] = 81 "AsyncTpmAttestationCreateCertRequestByProfile"; 82 const char kCryptohomeAsyncTpmAttestationFinishCertRequest[] = 83 "AsyncTpmAttestationFinishCertRequest"; 84 const char kCryptohomeTpmAttestationDoesKeyExist[] = 85 "TpmAttestationDoesKeyExist"; 86 const char kCryptohomeTpmAttestationGetCertificate[] = 87 "TpmAttestationGetCertificate"; 88 const char kCryptohomeTpmAttestationGetPublicKey[] = 89 "TpmAttestationGetPublicKey"; 90 const char kCryptohomeTpmAttestationRegisterKey[] = "TpmAttestationRegisterKey"; 91 const char kCryptohomeTpmAttestationSignEnterpriseChallenge[] = 92 "TpmAttestationSignEnterpriseChallenge"; 93 const char kCryptohomeTpmAttestationSignSimpleChallenge[] = 94 "TpmAttestationSignSimpleChallenge"; 95 const char kCryptohomeTpmAttestationGetKeyPayload[] = 96 "TpmAttestationGetKeyPayload"; 97 const char kCryptohomeTpmAttestationSetKeyPayload[] = 98 "TpmAttestationSetKeyPayload"; 99 const char kCryptohomeTpmAttestationDeleteKeys[] = 100 "TpmAttestationDeleteKeys"; 101 const char kCryptohomeGetKeyDataEx[] = "GetKeyDataEx"; 102 const char kCryptohomeCheckKeyEx[] = "CheckKeyEx"; 103 const char kCryptohomeMountEx[] = "MountEx"; 104 const char kCryptohomeAddKeyEx[] = "AddKeyEx"; 105 const char kCryptohomeUpdateKeyEx[] = "UpdateKeyEx"; 106 const char kCryptohomeRemoveKeyEx[] = "RemoveKeyEx"; 107 const char kCryptohomeSignBootLockbox[] = "SignBootLockbox"; 108 const char kCryptohomeVerifyBootLockbox[] = "VerifyBootLockbox"; 109 const char kCryptohomeFinalizeBootLockbox[] = "FinalizeBootLockbox"; 110 const char kCryptohomeGetBootAttribute[] = "GetBootAttribute"; 111 const char kCryptohomeSetBootAttribute[] = "SetBootAttribute"; 112 const char kCryptohomeFlushAndSignBootAttributes[] = 113 "FlushAndSignBootAttributes"; 114 const char kCryptohomeGetLoginStatus[] = "GetLoginStatus"; 115 const char kCryptohomeGetTpmStatus[] = "GetTpmStatus"; 116 const char kCryptohomeGetEndorsementInfo[] = "GetEndorsementInfo"; 117 118 // Signals 119 const char kSignalAsyncCallStatus[] = "AsyncCallStatus"; 120 const char kSignalAsyncCallStatusWithData[] = "AsyncCallStatusWithData"; 121 const char kSignalTpmInitStatus[] = "TpmInitStatus"; 122 const char kSignalCleanupUsersRemoved[] = "CleanupUsersRemoved"; 123 // Error code 124 enum MountError { 125 MOUNT_ERROR_NONE = 0, 126 MOUNT_ERROR_FATAL = 1 << 0, 127 MOUNT_ERROR_KEY_FAILURE = 1 << 1, 128 MOUNT_ERROR_MOUNT_POINT_BUSY = 1 << 2, 129 MOUNT_ERROR_TPM_COMM_ERROR = 1 << 3, 130 MOUNT_ERROR_TPM_DEFEND_LOCK = 1 << 4, 131 MOUNT_ERROR_USER_DOES_NOT_EXIST = 1 << 5, 132 MOUNT_ERROR_TPM_NEEDS_REBOOT = 1 << 6, 133 MOUNT_ERROR_RECREATED = 1 << 31, 134 }; 135 } // namespace cryptohome 136 137 #endif // SYSTEM_API_DBUS_CRYPTOHOME_DBUS_CONSTANTS_H_ 138