Android keymaster的介绍和总结
生活随笔
收集整理的這篇文章主要介紹了
Android keymaster的介绍和总结
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
快速鏈接:
.
👉👉👉 個人博客筆記導讀目錄(全部) 👈👈👈
相關推薦:
1、Android keymaster4.0- device集成筆記
2、Android keystore/Keymaster的代碼導讀
文章目錄
- 一、keymaster需求/要求
- 1、keymaster提供的功能:
- 2、keymaster執行環境要求:
- 4、keymaster對算法的要求:
- 5、訪問權限的約束:
- 二、keystore/keymaster的框圖
- 三、相關API
- 1、package android.security.keystore包含哪些API
- 2、KeyStoreService包含哪些API
- 3、keymaster HAL包含哪些API
- 四、錯誤碼
一、keymaster需求/要求
1、keymaster提供的功能:
- 密鑰生成
- 非對稱密鑰的導入和導出(導出僅限pubkey)
- 導入原始對稱密鑰
- 非對稱加密和解密
- 非對稱簽名和驗證
- 對稱加密和解密,包括 AEAD 模式
- 對稱消息認證碼的生成和驗證(share hmackey)
- 設備證明(attestation)
2、keymaster執行環境要求:
- (1)、Isolated execution environments,例如:
- a separate virtual machine
- hypervisor
- TEE
總之需要獨立于android Kernel/Userspace之外的地址空間
- (2)、StrongBox (完全獨立、特殊目的、經過認證的安全CPU),例如:
- ese (embedded secure elements)
- SPU (on-SOC secure processing unit)
4、keymaster對算法的要求:
(1)、RSA
- must support 2048, 3072 and 4096-bit keys. If strongbox, must support 2048-bit keys
- Public exponent F4 (2^16+1)
- Unpadded, RSASSA-PSS and RSASSA-PKCS1-v1_5 padding modes for RSA signing
- must support MD5, SHA1, SHA-2 224, SHA-2 256, SHA-2 384 and SHA-2 512 digest modes for RSA signing
- Unpadded, RSAES-OAEP and RSAES-PKCS1-v1_5 padding modes for RSA encryption
(2)、ECDSA
- must support NIST curves P-224, P-256, P-384, P-521. If strongbox, must support NIST curve P-256
- must support SHA1, SHA-2 224, SHA-2 256, SHA-2, 384 and SHA-2 512 digest modes. If strongbox, must support SHA-2 256
(3)、AES
- 128 and 256-bit keys
- CBC, CTR, ECB and GCM modes
- GCM mode的tags大于96,nonce長度不能是96
- CBC and ECB modes must support unpadded and PKCS7 padding modes. 如果沒有padding,且輸入不是完整block,將報錯:ErrorCode::INVALID_INPUT_LENGTH
- With PKCS7 padding, GCM and CTR operations must fail with ErrorCode::INCOMPATIBLE_PADDING_MODE
(4)、3DES
- 168-bit keys.
- CBC and ECB mode.
- CBC and ECB modes must support unpadded and PKCS7 padding modes. 如果沒有padding,且輸入不是完整block,將報錯:ErrorCode::INVALID_INPUT_LENGTH
(5)、HMAC
- keysize是64-512,必需是8的倍數
- must support MD-5, SHA1, SHA-2-224, SHA-2-256, SHA-2-384 and SHA-2-512. If strongbox, must support SHA-2 256
5、訪問權限的約束:
1、基于硬件的密鑰永遠不能導出來
二、keystore/keymaster的框圖
三、相關API
1、package android.security.keystore包含哪些API
public InvalidKeyException getInvalidKeyException(String keystoreKeyAlias, int uid,int errorCode) public static KeyStoreException getKeyStoreException(int errorCode) public boolean isConfirmationPromptSupported() public int cancelConfirmationPrompt(IBinder listener) public int presentConfirmationPrompt(IBinder listener, String promptText, byte[] extraData,String locale, int uiOptionsAsFlags) public void onDeviceOffBody() public int attestDeviceIds(KeymasterArguments params, KeymasterCertificateChain outChain) public int attestKey(String alias, KeymasterArguments params, KeymasterCertificateChain outChain) public boolean onUserPasswordChanged(String newPassword) public void onUserRemoved(int userId) public void onUserAdded(int userId) public boolean onUserPasswordChanged(int userId, String newPassword) public int addAuthToken(byte[] authToken) public int abort(IBinder token) public int getLastError() public boolean clearUid(int uid) public boolean isHardwareBacked(String keyType) public boolean isHardwareBacked() public long getmtime(String key) public boolean ungrant(String key, int uid) public String grant(String key, int uid) public boolean isEmpty() public boolean lock() public boolean unlock(String password) public String[] list(String prefix) public int[] listUidsOfAuthBoundKeys()begin、update、finish generateKey、exportKey、importWrappedKey、importKey、 getKeyCharacteristics、addRngEntropy、delete2、KeyStoreService包含哪些API
(system/keymaster/include/keymaster/android_keymaster.h) class AndroidKeymaster {public:AndroidKeymaster(KeymasterContext* context, size_t operation_table_size);virtual ~AndroidKeymaster();AndroidKeymaster(AndroidKeymaster&&);void GetVersion(const GetVersionRequest& request, GetVersionResponse* response);void SupportedAlgorithms(const SupportedAlgorithmsRequest& request,SupportedAlgorithmsResponse* response);void SupportedBlockModes(const SupportedBlockModesRequest& request,SupportedBlockModesResponse* response);void SupportedPaddingModes(const SupportedPaddingModesRequest& request,SupportedPaddingModesResponse* response);void SupportedDigests(const SupportedDigestsRequest& request,SupportedDigestsResponse* response);void SupportedImportFormats(const SupportedImportFormatsRequest& request,SupportedImportFormatsResponse* response);void SupportedExportFormats(const SupportedExportFormatsRequest& request,SupportedExportFormatsResponse* response);GetHmacSharingParametersResponse GetHmacSharingParameters();ComputeSharedHmacResponse ComputeSharedHmac(const ComputeSharedHmacRequest& request);VerifyAuthorizationResponse VerifyAuthorization(const VerifyAuthorizationRequest& request);void AddRngEntropy(const AddEntropyRequest& request, AddEntropyResponse* response);void Configure(const ConfigureRequest& request, ConfigureResponse* response);void GenerateKey(const GenerateKeyRequest& request, GenerateKeyResponse* response);void GetKeyCharacteristics(const GetKeyCharacteristicsRequest& request,GetKeyCharacteristicsResponse* response);void ImportKey(const ImportKeyRequest& request, ImportKeyResponse* response);void ImportWrappedKey(const ImportWrappedKeyRequest& request,ImportWrappedKeyResponse* response);void ExportKey(const ExportKeyRequest& request, ExportKeyResponse* response);void AttestKey(const AttestKeyRequest& request, AttestKeyResponse* response);void UpgradeKey(const UpgradeKeyRequest& request, UpgradeKeyResponse* response);void DeleteKey(const DeleteKeyRequest& request, DeleteKeyResponse* response);void DeleteAllKeys(const DeleteAllKeysRequest& request, DeleteAllKeysResponse* response);void BeginOperation(const BeginOperationRequest& request, BeginOperationResponse* response);void UpdateOperation(const UpdateOperationRequest& request, UpdateOperationResponse* response);void FinishOperation(const FinishOperationRequest& request, FinishOperationResponse* response);void AbortOperation(const AbortOperationRequest& request, AbortOperationResponse* response);bool has_operation(keymaster_operation_handle_t op_handle) const;private:keymaster_error_t LoadKey(const keymaster_key_blob_t& key_blob,const AuthorizationSet& additional_params,const KeyFactory** factory, UniquePtr<Key>* key);UniquePtr<KeymasterContext> context_;UniquePtr<OperationTable> operation_table_; };3、keymaster HAL包含哪些API
(IKeymasterDevice.hal)
getHardwareInfo() generates (SecurityLevel securityLevel, string keymasterName, string keymasterAuthorName); 返回:securityLevel、keymasterName、keymasterAuthorNamegetHmacSharingParameters() generates (ErrorCode error, HmacSharingParameters params); computeSharedHmac(vec<HmacSharingParameters> params) generates (ErrorCode error, vec<uint8_t> sharingCheck);verifyAuthorization(uint64_t operationHandle, vec<KeyParameter> parametersToVerify,HardwareAuthToken authToken)generates (ErrorCode error, VerificationToken token); 驗證authToken,返回tokenaddRngEntropy(vec<uint8_t> data) generates (ErrorCode error); Keymaster使用的RNG增加熵generateKey(vec<KeyParameter> keyParams)generates (ErrorCode error, vec<uint8_t> keyBlob, KeyCharacteristics keyCharacteristics);importKey(vec<KeyParameter> keyParams, KeyFormat keyFormat, vec<uint8_t> keyData)generates (ErrorCode error, vec<uint8_t> keyBlob, KeyCharacteristics keyCharacteristics);importWrappedKey(vec<uint8_t> wrappedKeyData, vec<uint8_t> wrappingKeyBlob,vec<uint8_t> maskingKey, vec<KeyParameter> unwrappingParams,uint64_t passwordSid, uint64_t biometricSid)generates(ErrorCode error, vec<uint8_t> keyBlob, KeyCharacteristics keyCharacteristics);getKeyCharacteristics(vec<uint8_t> keyBlob, vec<uint8_t> clientId, vec<uint8_t> appData)generates (ErrorCode error, KeyCharacteristics keyCharacteristics);exportKey(KeyFormat keyFormat, vec<uint8_t> keyBlob, vec<uint8_t> clientId,vec<uint8_t> appData) generates (ErrorCode error, vec<uint8_t> keyMaterial);attestKey(vec<uint8_t> keyToAttest, vec<KeyParameter> attestParams)generates (ErrorCode error, vec<vec<uint8_t>> certChain); // 使用attestationkey生成一個簽名upgradeKey(vec<uint8_t> keyBlobToUpgrade, vec<KeyParameter> upgradeParams)generates (ErrorCode error, vec<uint8_t> upgradedKeyBlob);deleteKey(vec<uint8_t> keyBlob) generates (ErrorCode error);deleteAllKeys() generates (ErrorCode error);destroyAttestationIds() generates (ErrorCode error);begin(KeyPurpose purpose, vec<uint8_t> keyBlob, vec<KeyParameter> inParams,HardwareAuthToken authToken)generates (ErrorCode error, vec<KeyParameter> outParams, OperationHandle operationHandle);update(OperationHandle operationHandle, vec<KeyParameter> inParams, vec<uint8_t> input,HardwareAuthToken authToken, VerificationToken verificationToken)generates (ErrorCode error, uint32_t inputConsumed, vec<KeyParameter> outParams,vec<uint8_t> output);finish(OperationHandle operationHandle, vec<KeyParameter> inParams, vec<uint8_t> input,vec<uint8_t> signature, HardwareAuthToken authToken, VerificationToken verificationToken)generates (ErrorCode error, vec<KeyParameter> outParams, vec<uint8_t> output);四、錯誤碼
上層
(frameworks/base/core/java/android/security/keymaster/KeymasterDefs.java)// Error codes. public static final int KM_ERROR_OK = ErrorCode.OK; public static final int KM_ERROR_ROOT_OF_TRUST_ALREADY_SET =ErrorCode.ROOT_OF_TRUST_ALREADY_SET; // -1; public static final int KM_ERROR_UNSUPPORTED_PURPOSE =ErrorCode.UNSUPPORTED_PURPOSE; // -2; public static final int KM_ERROR_INCOMPATIBLE_PURPOSE =ErrorCode.INCOMPATIBLE_PURPOSE; // -3; public static final int KM_ERROR_UNSUPPORTED_ALGORITHM =ErrorCode.UNSUPPORTED_ALGORITHM; // -4; public static final int KM_ERROR_INCOMPATIBLE_ALGORITHM =ErrorCode.INCOMPATIBLE_ALGORITHM; // -5; public static final int KM_ERROR_UNSUPPORTED_KEY_SIZE =ErrorCode.UNSUPPORTED_KEY_SIZE; // -6; public static final int KM_ERROR_UNSUPPORTED_BLOCK_MODE =ErrorCode.UNSUPPORTED_BLOCK_MODE; // -7; public static final int KM_ERROR_INCOMPATIBLE_BLOCK_MODE =ErrorCode.INCOMPATIBLE_BLOCK_MODE; // -8; public static final int KM_ERROR_UNSUPPORTED_MAC_LENGTH =ErrorCode.UNSUPPORTED_MAC_LENGTH; // -9; public static final int KM_ERROR_UNSUPPORTED_PADDING_MODE =ErrorCode.UNSUPPORTED_PADDING_MODE; // -10; public static final int KM_ERROR_INCOMPATIBLE_PADDING_MODE =ErrorCode.INCOMPATIBLE_PADDING_MODE; // -11; public static final int KM_ERROR_UNSUPPORTED_DIGEST =ErrorCode.UNSUPPORTED_DIGEST; // -12; public static final int KM_ERROR_INCOMPATIBLE_DIGEST =ErrorCode.INCOMPATIBLE_DIGEST; // -13; public static final int KM_ERROR_INVALID_EXPIRATION_TIME =ErrorCode.INVALID_EXPIRATION_TIME; // -14; public static final int KM_ERROR_INVALID_USER_ID =ErrorCode.INVALID_USER_ID; // -15; public static final int KM_ERROR_INVALID_AUTHORIZATION_TIMEOUT =ErrorCode.INVALID_AUTHORIZATION_TIMEOUT; // -16; public static final int KM_ERROR_UNSUPPORTED_KEY_FORMAT =ErrorCode.UNSUPPORTED_KEY_FORMAT; // -17; public static final int KM_ERROR_INCOMPATIBLE_KEY_FORMAT =ErrorCode.INCOMPATIBLE_KEY_FORMAT; // -18; public static final int KM_ERROR_UNSUPPORTED_KEY_ENCRYPTION_ALGORITHM =ErrorCode.UNSUPPORTED_KEY_ENCRYPTION_ALGORITHM; // -19; public static final int KM_ERROR_UNSUPPORTED_KEY_VERIFICATION_ALGORITHM =ErrorCode.UNSUPPORTED_KEY_VERIFICATION_ALGORITHM; // -20; public static final int KM_ERROR_INVALID_INPUT_LENGTH =ErrorCode.INVALID_INPUT_LENGTH; // -21; public static final int KM_ERROR_KEY_EXPORT_OPTIONS_INVALID =ErrorCode.KEY_EXPORT_OPTIONS_INVALID; // -22; public static final int KM_ERROR_DELEGATION_NOT_ALLOWED =ErrorCode.DELEGATION_NOT_ALLOWED; // -23; public static final int KM_ERROR_KEY_NOT_YET_VALID =ErrorCode.KEY_NOT_YET_VALID; // -24; public static final int KM_ERROR_KEY_EXPIRED =ErrorCode.KEY_EXPIRED; // -25; public static final int KM_ERROR_KEY_USER_NOT_AUTHENTICATED =ErrorCode.KEY_USER_NOT_AUTHENTICATED; // -26; public static final int KM_ERROR_OUTPUT_PARAMETER_NULL =ErrorCode.OUTPUT_PARAMETER_NULL; // -27; public static final int KM_ERROR_INVALID_OPERATION_HANDLE =ErrorCode.INVALID_OPERATION_HANDLE; // -28; public static final int KM_ERROR_INSUFFICIENT_BUFFER_SPACE =ErrorCode.INSUFFICIENT_BUFFER_SPACE; // -29; public static final int KM_ERROR_VERIFICATION_FAILED =ErrorCode.VERIFICATION_FAILED; // -30; public static final int KM_ERROR_TOO_MANY_OPERATIONS =ErrorCode.TOO_MANY_OPERATIONS; // -31; public static final int KM_ERROR_UNEXPECTED_NULL_POINTER =ErrorCode.UNEXPECTED_NULL_POINTER; // -32; public static final int KM_ERROR_INVALID_KEY_BLOB =ErrorCode.INVALID_KEY_BLOB; // -33; public static final int KM_ERROR_IMPORTED_KEY_NOT_ENCRYPTED =ErrorCode.IMPORTED_KEY_NOT_ENCRYPTED; // -34; public static final int KM_ERROR_IMPORTED_KEY_DECRYPTION_FAILED =ErrorCode.IMPORTED_KEY_DECRYPTION_FAILED; // -35; public static final int KM_ERROR_IMPORTED_KEY_NOT_SIGNED =ErrorCode.IMPORTED_KEY_NOT_SIGNED; // -36; public static final int KM_ERROR_IMPORTED_KEY_VERIFICATION_FAILED =ErrorCode.IMPORTED_KEY_VERIFICATION_FAILED; // -37; public static final int KM_ERROR_INVALID_ARGUMENT =ErrorCode.INVALID_ARGUMENT; // -38; public static final int KM_ERROR_UNSUPPORTED_TAG =ErrorCode.UNSUPPORTED_TAG; // -39; public static final int KM_ERROR_INVALID_TAG =ErrorCode.INVALID_TAG; // -40; public static final int KM_ERROR_MEMORY_ALLOCATION_FAILED =ErrorCode.MEMORY_ALLOCATION_FAILED; // -41; public static final int KM_ERROR_IMPORT_PARAMETER_MISMATCH =ErrorCode.IMPORT_PARAMETER_MISMATCH; // -44; public static final int KM_ERROR_SECURE_HW_ACCESS_DENIED =ErrorCode.SECURE_HW_ACCESS_DENIED; // -45; public static final int KM_ERROR_OPERATION_CANCELLED =ErrorCode.OPERATION_CANCELLED; // -46; public static final int KM_ERROR_CONCURRENT_ACCESS_CONFLICT =ErrorCode.CONCURRENT_ACCESS_CONFLICT; // -47; public static final int KM_ERROR_SECURE_HW_BUSY =ErrorCode.SECURE_HW_BUSY; // -48; public static final int KM_ERROR_SECURE_HW_COMMUNICATION_FAILED =ErrorCode.SECURE_HW_COMMUNICATION_FAILED; // -49; public static final int KM_ERROR_UNSUPPORTED_EC_FIELD =ErrorCode.UNSUPPORTED_EC_FIELD; // -50; public static final int KM_ERROR_MISSING_NONCE =ErrorCode.MISSING_NONCE; // -51; public static final int KM_ERROR_INVALID_NONCE =ErrorCode.INVALID_NONCE; // -52; public static final int KM_ERROR_MISSING_MAC_LENGTH =ErrorCode.MISSING_MAC_LENGTH; // -53; public static final int KM_ERROR_KEY_RATE_LIMIT_EXCEEDED =ErrorCode.KEY_RATE_LIMIT_EXCEEDED; // -54; public static final int KM_ERROR_CALLER_NONCE_PROHIBITED =ErrorCode.CALLER_NONCE_PROHIBITED; // -55; public static final int KM_ERROR_KEY_MAX_OPS_EXCEEDED =ErrorCode.KEY_MAX_OPS_EXCEEDED; // -56; public static final int KM_ERROR_INVALID_MAC_LENGTH =ErrorCode.INVALID_MAC_LENGTH; // -57; public static final int KM_ERROR_MISSING_MIN_MAC_LENGTH =ErrorCode.MISSING_MIN_MAC_LENGTH; // -58; public static final int KM_ERROR_UNSUPPORTED_MIN_MAC_LENGTH =ErrorCode.UNSUPPORTED_MIN_MAC_LENGTH; // -59; public static final int KM_ERROR_CANNOT_ATTEST_IDS =ErrorCode.CANNOT_ATTEST_IDS; // -66; public static final int KM_ERROR_HARDWARE_TYPE_UNAVAILABLE =ErrorCode.HARDWARE_TYPE_UNAVAILABLE; // -68; public static final int KM_ERROR_DEVICE_LOCKED =ErrorCode.DEVICE_LOCKED; // -72; public static final int KM_ERROR_MISSING_NOT_BEFORE =ErrorCode.MISSING_NOT_BEFORE; // -80; public static final int KM_ERROR_MISSING_NOT_AFTER =ErrorCode.MISSING_NOT_AFTER; // -80; public static final int KM_ERROR_UNIMPLEMENTED =ErrorCode.UNIMPLEMENTED; // -100; public static final int KM_ERROR_VERSION_MISMATCH =ErrorCode.VERSION_MISMATCH; // -101; public static final int KM_ERROR_UNKNOWN_ERROR =ErrorCode.UNKNOWN_ERROR; // -1000;底層
(hardware/libhardware/include/hardware/keymaster_defs.h)typedef enum {KM_ERROR_OK = 0,KM_ERROR_ROOT_OF_TRUST_ALREADY_SET = -1,KM_ERROR_UNSUPPORTED_PURPOSE = -2,KM_ERROR_INCOMPATIBLE_PURPOSE = -3,KM_ERROR_UNSUPPORTED_ALGORITHM = -4,KM_ERROR_INCOMPATIBLE_ALGORITHM = -5,KM_ERROR_UNSUPPORTED_KEY_SIZE = -6,KM_ERROR_UNSUPPORTED_BLOCK_MODE = -7,KM_ERROR_INCOMPATIBLE_BLOCK_MODE = -8,KM_ERROR_UNSUPPORTED_MAC_LENGTH = -9,KM_ERROR_UNSUPPORTED_PADDING_MODE = -10,KM_ERROR_INCOMPATIBLE_PADDING_MODE = -11,KM_ERROR_UNSUPPORTED_DIGEST = -12,KM_ERROR_INCOMPATIBLE_DIGEST = -13,KM_ERROR_INVALID_EXPIRATION_TIME = -14,KM_ERROR_INVALID_USER_ID = -15,KM_ERROR_INVALID_AUTHORIZATION_TIMEOUT = -16,KM_ERROR_UNSUPPORTED_KEY_FORMAT = -17,KM_ERROR_INCOMPATIBLE_KEY_FORMAT = -18,KM_ERROR_UNSUPPORTED_KEY_ENCRYPTION_ALGORITHM = -19, /* For PKCS8 & PKCS12 */KM_ERROR_UNSUPPORTED_KEY_VERIFICATION_ALGORITHM = -20, /* For PKCS8 & PKCS12 */KM_ERROR_INVALID_INPUT_LENGTH = -21,KM_ERROR_KEY_EXPORT_OPTIONS_INVALID = -22,KM_ERROR_DELEGATION_NOT_ALLOWED = -23,KM_ERROR_KEY_NOT_YET_VALID = -24,KM_ERROR_KEY_EXPIRED = -25,KM_ERROR_KEY_USER_NOT_AUTHENTICATED = -26,KM_ERROR_OUTPUT_PARAMETER_NULL = -27,KM_ERROR_INVALID_OPERATION_HANDLE = -28,KM_ERROR_INSUFFICIENT_BUFFER_SPACE = -29,KM_ERROR_VERIFICATION_FAILED = -30,KM_ERROR_TOO_MANY_OPERATIONS = -31,KM_ERROR_UNEXPECTED_NULL_POINTER = -32,KM_ERROR_INVALID_KEY_BLOB = -33,KM_ERROR_IMPORTED_KEY_NOT_ENCRYPTED = -34,KM_ERROR_IMPORTED_KEY_DECRYPTION_FAILED = -35,KM_ERROR_IMPORTED_KEY_NOT_SIGNED = -36,KM_ERROR_IMPORTED_KEY_VERIFICATION_FAILED = -37,KM_ERROR_INVALID_ARGUMENT = -38,KM_ERROR_UNSUPPORTED_TAG = -39,KM_ERROR_INVALID_TAG = -40,KM_ERROR_MEMORY_ALLOCATION_FAILED = -41,KM_ERROR_IMPORT_PARAMETER_MISMATCH = -44,KM_ERROR_SECURE_HW_ACCESS_DENIED = -45,KM_ERROR_OPERATION_CANCELLED = -46,KM_ERROR_CONCURRENT_ACCESS_CONFLICT = -47,KM_ERROR_SECURE_HW_BUSY = -48,KM_ERROR_SECURE_HW_COMMUNICATION_FAILED = -49,KM_ERROR_UNSUPPORTED_EC_FIELD = -50,KM_ERROR_MISSING_NONCE = -51,KM_ERROR_INVALID_NONCE = -52,KM_ERROR_MISSING_MAC_LENGTH = -53,KM_ERROR_KEY_RATE_LIMIT_EXCEEDED = -54,KM_ERROR_CALLER_NONCE_PROHIBITED = -55,KM_ERROR_KEY_MAX_OPS_EXCEEDED = -56,KM_ERROR_INVALID_MAC_LENGTH = -57,KM_ERROR_MISSING_MIN_MAC_LENGTH = -58,KM_ERROR_UNSUPPORTED_MIN_MAC_LENGTH = -59,KM_ERROR_UNSUPPORTED_KDF = -60,KM_ERROR_UNSUPPORTED_EC_CURVE = -61,KM_ERROR_KEY_REQUIRES_UPGRADE = -62,KM_ERROR_ATTESTATION_CHALLENGE_MISSING = -63,KM_ERROR_KEYMASTER_NOT_CONFIGURED = -64,KM_ERROR_ATTESTATION_APPLICATION_ID_MISSING = -65,KM_ERROR_CANNOT_ATTEST_IDS = -66,KM_ERROR_ROLLBACK_RESISTANCE_UNAVAILABLE = -67,KM_ERROR_NO_USER_CONFIRMATION = -71,KM_ERROR_DEVICE_LOCKED = -72,KM_ERROR_EARLY_BOOT_ENDED = -73,KM_ERROR_ATTESTATION_KEYS_NOT_PROVISIONED = -74,KM_ERROR_ATTESTATION_IDS_NOT_PROVISIONED = -75,KM_ERROR_INCOMPATIBLE_MGF_DIGEST = -78,KM_ERROR_UNSUPPORTED_MGF_DIGEST = -79,KM_ERROR_MISSING_NOT_BEFORE = -80,KM_ERROR_MISSING_NOT_AFTER = -81,KM_ERROR_MISSING_ISSUER_SUBJECT = -82,KM_ERROR_INVALID_ISSUER_SUBJECT = -83,KM_ERROR_BOOT_LEVEL_EXCEEDED = -84,KM_ERROR_UNIMPLEMENTED = -100,KM_ERROR_VERSION_MISMATCH = -101,KM_ERROR_UNKNOWN_ERROR = -1000, } keymaster_error_t;總結
以上是生活随笔為你收集整理的Android keymaster的介绍和总结的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: Android fingerprint指
- 下一篇: optee的栈指针和栈内存的介绍