Home
last modified time | relevance | path

Searched refs:digest_len (Results 1 – 8 of 8) sorted by relevance

/system/keymaster/km_openssl/
Dhmac.cpp49 bool HmacSha256::Sign(const Buffer& data, uint8_t* out_digest, size_t digest_len) const { in Sign()
50 return Sign(data.peek_read(), data.available_read(), out_digest, digest_len); in Sign()
54 size_t digest_len) const { in Sign()
55 assert(digest_len); in Sign()
59 if (digest_len >= SHA256_DIGEST_LENGTH) digest = out_digest; in Sign()
64 if (digest_len < SHA256_DIGEST_LENGTH) memcpy(out_digest, tmp, digest_len); in Sign()
75 size_t digest_len) const { in Verify()
76 if (digest_len != SHA256_DIGEST_LENGTH) return false; in Verify()
Dhmac_operation.cpp174 unsigned int digest_len; in Finish() local
175 if (!HMAC_Final(&ctx_, digest, &digest_len)) return TranslateLastOpenSslError(); in Finish()
179 if (mac_length_ > digest_len) return KM_ERROR_UNSUPPORTED_MAC_LENGTH; in Finish()
185 if (siglen > digest_len || siglen < kMinHmacLengthBits / 8) in Finish()
Dsoft_keymaster_enforcement.cpp99 unsigned digest_len = SHA256_DIGEST_LENGTH; in hmacSha256() local
100 if (!output->Reset(digest_len)) return KM_ERROR_MEMORY_ALLOCATION_FAILED; in hmacSha256()
115 if (!HMAC_Final(ctx.get(), output->writable_data(), &digest_len)) { in hmacSha256()
119 if (digest_len != output->data_length) return KM_ERROR_UNKNOWN_ERROR; in hmacSha256()
/system/keymaster/include/keymaster/km_openssl/
Dhmac.h40 bool Sign(const Buffer& data, uint8_t* digest, size_t digest_len) const;
41 bool Sign(const uint8_t* data, size_t data_len, uint8_t* digest, size_t digest_len) const;
51 size_t digest_len) const;
/system/keymaster/legacy_support/
Dkeymaster1_engine.cpp317 int Keymaster1Engine::ecdsa_sign(const uint8_t* digest, size_t digest_len, uint8_t* sig, in ecdsa_sign() argument
324 if (digest_len > max_input_len) digest_len = max_input_len; in ecdsa_sign()
326 keymaster_blob_t input = {digest, digest_len}; in ecdsa_sign()
/system/security/keystore-engine/
Dkeystore2_engine.cpp84 extern "C" int ecdsa_sign(const uint8_t* digest, size_t digest_len, uint8_t* sig,
297 extern "C" int ecdsa_sign(const uint8_t* digest, size_t digest_len, uint8_t* sig, in ecdsa_sign() argument
309 auto output = keystore2_sign(**key_backend, std::vector<uint8_t>(digest, digest + digest_len), in ecdsa_sign()
/system/keymaster/include/keymaster/legacy_support/
Dkeymaster1_engine.h107 static int ecdsa_sign(const uint8_t* digest, size_t digest_len, uint8_t* sig,
/system/core/fs_mgr/libfs_avb/
Davb_util.cpp182 hash_desc->digest = BytesToHex(desc_digest, hash_desc->digest_len); in GetHashDescriptor()