Home
last modified time | relevance | path

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

/system/keymaster/
Dhmac.cpp50 bool HmacSha256::Sign(const Buffer& data, uint8_t* out_digest, size_t digest_len) const { in Sign()
51 return Sign(data.peek_read(), data.available_read(), out_digest, digest_len); in Sign()
55 size_t digest_len) const { in Sign()
56 assert(digest_len); in Sign()
60 if (digest_len >= SHA256_DIGEST_LENGTH) in Sign()
66 if (digest_len < SHA256_DIGEST_LENGTH) in Sign()
67 memcpy(out_digest, tmp, digest_len); in Sign()
78 size_t digest_len) const { in Verify()
79 if (digest_len != SHA256_DIGEST_LENGTH) in Verify()
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;
Dhmac_operation.cpp171 unsigned int digest_len; in Finish() local
172 if (!HMAC_Final(&ctx_, digest, &digest_len)) in Finish()
177 if (mac_length_ > digest_len) in Finish()
184 if (siglen > digest_len || siglen < kMinHmacLengthBits / 8) in Finish()
Dkeymaster0_engine.cpp271 int Keymaster0Engine::ecdsa_sign(const uint8_t* digest, size_t digest_len, uint8_t* sig, in ecdsa_sign() argument
273 ALOGV("ecdsa_sign(%p, %u, %p)", digest, (unsigned)digest_len, ec_key); in ecdsa_sign()
275 return instance_->EcdsaSign(digest, digest_len, sig, sig_len, ec_key); in ecdsa_sign()
361 int Keymaster0Engine::EcdsaSign(const uint8_t* digest, size_t digest_len, uint8_t* sig, in EcdsaSign() argument
371 if (digest_len > max_input_len) in EcdsaSign()
372 digest_len = max_input_len; in EcdsaSign()
377 if (!Keymaster0Sign(&sign_params, *key_blob, digest, digest_len, &signature, in EcdsaSign()
396 ALOGV("ecdsa_sign(%p, %u, %p) => success", digest, (unsigned)digest_len, ec_key); in EcdsaSign()
Dkeymaster0_engine.h75 static int ecdsa_sign(const uint8_t* digest, size_t digest_len, uint8_t* sig,
88 int EcdsaSign(const uint8_t* digest, size_t digest_len, uint8_t* sig, unsigned int* sig_len,
Dkeymaster1_engine.cpp339 int Keymaster1Engine::ecdsa_sign(const uint8_t* digest, size_t digest_len, uint8_t* sig, in ecdsa_sign() argument
347 if (digest_len > max_input_len) in ecdsa_sign()
348 digest_len = max_input_len; in ecdsa_sign()
350 keymaster_blob_t input = {digest, digest_len}; in ecdsa_sign()
Dkeymaster1_engine.h107 static int ecdsa_sign(const uint8_t* digest, size_t digest_len, uint8_t* sig,
/system/security/keystore-engine/
Dandroid_engine.cpp235 static int ecdsa_sign(const uint8_t* digest, size_t digest_len, uint8_t* sig, in ecdsa_sign() argument
237 ALOGV("ecdsa_sign(%p, %u, %p)", digest, (unsigned) digest_len, ec_key); in ecdsa_sign()
259 digest, digest_len, &reply, &reply_len); in ecdsa_sign()
279 ALOGV("ecdsa_sign(%p, %u, %p) => success", digest, (unsigned)digest_len, in ecdsa_sign()