Home
last modified time | relevance | path

Searched refs:key_len (Results 1 – 12 of 12) sorted by relevance

/system/keymaster/km_openssl/
Dhmac.cpp38 bool HmacSha256::Init(const uint8_t* key, size_t key_len) { in Init() argument
41 key_len_ = key_len; in Init()
42 key_.reset(dup_buffer(key, key_len)); in Init()
Drsa_operation.cpp336 size_t key_len = EVP_PKEY_size(rsa_key_); in SignUndigested() local
342 if (data_.available_read() > key_len) { in SignUndigested()
344 } else if (data_.available_read() < key_len) { in SignUndigested()
345 keymaster_error_t error = zero_pad_left(&zero_padded, key_len, data_); in SignUndigested()
349 bytes_encrypted = RSA_private_encrypt(key_len, to_encrypt, output->peek_write(), rsa.get(), in SignUndigested()
355 if (data_.available_read() + kPkcs1UndigestedSignaturePaddingOverhead > key_len) { in SignUndigested()
431 size_t key_len = RSA_size(rsa.get()); in VerifyUndigested() local
435 if (data_.available_read() > key_len) return KM_ERROR_INVALID_INPUT_LENGTH; in VerifyUndigested()
436 if (key_len != signature.available_read()) return KM_ERROR_VERIFICATION_FAILED; in VerifyUndigested()
440 if (data_.available_read() + kPkcs1UndigestedSignaturePaddingOverhead > key_len) { in VerifyUndigested()
[all …]
/system/keymaster/include/keymaster/key_blob_utils/
Dae.h75 int ae_init(ae_ctx* ctx, const void* key, int key_len, int nonce_len, int tag_len);
/system/security/keystore2/src/crypto/
Dcrypto.cpp184 void generateKeyFromPassword(uint8_t* key, size_t key_len, const char* pw, size_t pw_len, in generateKeyFromPassword() argument
199 if (key_len == kAes128KeySizeBytes) { in generateKeyFromPassword()
203 PKCS5_PBKDF2_HMAC(pw, pw_len, salt, saltSize, 8192, digest, key_len, key); in generateKeyFromPassword()
Dcrypto.hpp37 void generateKeyFromPassword(uint8_t* key, size_t key_len, const char* pw,
/system/gatekeeper/
Dgatekeeper.cpp265 uint32_t key_len = 0; in MintAuthToken() local
266 if (GetAuthTokenKey(&auth_token_key, &key_len)) { in MintAuthToken()
267 ComputeSignature(token.hmac, sizeof(token.hmac), auth_token_key, key_len, in MintAuthToken()
/system/bt/stack/hcic/
Dhciblecmds.cc426 void btsnd_hcic_ble_encrypt(uint8_t* key, uint8_t key_len, uint8_t* plain_text, in btsnd_hcic_ble_encrypt() argument
443 if (key_len > HCIC_BLE_ENCRYPT_KEY_SIZE) key_len = HCIC_BLE_ENCRYPT_KEY_SIZE; in btsnd_hcic_ble_encrypt()
446 ARRAY_TO_STREAM(pp, key, key_len); in btsnd_hcic_ble_encrypt()
447 pp += (HCIC_BLE_ENCRYPT_KEY_SIZE - key_len); in btsnd_hcic_ble_encrypt()
/system/sepolicy/tools/
Dcheck_seapp.c827 int key_len = strlen(k->key); in rule_map_new() local
830 l = l + key_len + val_len; in rule_map_new()
842 strncat(new_map->key, k->key, key_len); in rule_map_new()
/system/bt/test/mock/
Dmock_hcic_hciblecmds.cc94 void btsnd_hcic_ble_encrypt(uint8_t* key, uint8_t key_len, uint8_t* plain_text, in btsnd_hcic_ble_encrypt() argument
/system/keymaster/key_blob_utils/
Docb.c716 int ae_init(ae_ctx* ctx, const void* key, int key_len, int nonce_len, int tag_len) { in ae_init() argument
725 key_len = OCB_KEY_LEN; in ae_init()
727 AES_set_encrypt_key((unsigned char*)key, key_len * 8, &ctx->encrypt_key); in ae_init()
731 AES_set_decrypt_key((unsigned char*)key, (int)(key_len * 8), &ctx->decrypt_key); in ae_init()
/system/bt/btif/src/
Dbtif_storage.cc486 static void btif_read_le_key(const uint8_t key_type, const size_t key_len, in btif_read_le_key() argument
497 key_len) == BT_STATUS_SUCCESS) { in btif_read_le_key()
/system/bt/stack/include/
Dhcimsgs.h590 extern void btsnd_hcic_ble_encrypt(uint8_t* key, uint8_t key_len,