/system/keymaster/ |
D | ecdsa_operation.cpp | 99 if (!data_.write(input.peek_read(), input.available_read())) { in StoreData() 131 if (EVP_DigestSignUpdate(&digest_ctx_, input.peek_read(), input.available_read()) != 1) in Update() 152 if (!ECDSA_sign(0 /* type -- ignored */, data_.peek_read(), data_.available_read(), in Finish() 192 if (EVP_DigestVerifyUpdate(&digest_ctx_, input.peek_read(), input.available_read()) != 1) in Update() 208 ECDSA_verify(0 /* type -- ignored */, data_.peek_read(), data_.available_read(), in Finish() 209 signature.peek_read(), signature.available_read(), ecdsa.get()); in Finish() 214 } else if (!EVP_DigestVerifyFinal(&digest_ctx_, signature.peek_read(), in Finish()
|
D | hmac.cpp | 35 return Init(key.peek_read(), key.available_read()); in Init() 51 return Sign(data.peek_read(), data.available_read(), out_digest, digest_len); in Sign() 73 return Verify(data.peek_read(), data.available_read(), digest.peek_read(), in Verify()
|
D | rsa_operation.cpp | 170 if (!data_.write(input.peek_read(), input.available_read())) { in StoreData() 283 if (EVP_DigestSignUpdate(&digest_ctx_, input.peek_read(), input.available_read()) != 1) in Update() 327 const uint8_t* to_encrypt = data_.peek_read(); in SignUndigested() 348 bytes_encrypted = RSA_private_encrypt(data_.available_read(), data_.peek_read(), in SignUndigested() 402 if (EVP_DigestVerifyUpdate(&digest_ctx_, input.peek_read(), input.available_read()) != 1) in Update() 448 int bytes_decrypted = RSA_public_decrypt(signature.available_read(), signature.peek_read(), in VerifyUndigested() 465 if (memcmp_s(compare_pos, data_.peek_read(), bytes_to_compare) != 0 || zero_check_result != 0) in VerifyUndigested() 471 if (!EVP_DigestVerifyFinal(&digest_ctx_, signature.peek_read(), signature.available_read())) in VerifyDigested() 531 if (EVP_PKEY_encrypt(ctx.get(), nullptr /* out */, &outlen, data_.peek_read(), in Finish() 538 const uint8_t* to_encrypt = data_.peek_read(); in Finish() [all …]
|
D | hkdf.cpp | 33 Rfc5869HmacSha256Kdf(secret.peek_read(), secret.available_read(), salt.peek_read(), in Rfc5869HmacSha256Kdf() 34 salt.available_read(), info.peek_read(), info.available_read(), in Rfc5869HmacSha256Kdf()
|
D | ocb_utils.cpp | 140 int ae_err = ae_encrypt(ctx.get(), nonce.peek_read(), plaintext.key_material, in OcbEncryptKey() 176 int ae_err = ae_decrypt(ctx.get(), nonce.peek_read(), ciphertext.key_material, in OcbDecryptKey() 179 tag.peek_read(), 1 /* final */); in OcbDecryptKey()
|
D | hmac_operation.cpp | 153 if (!HMAC_Update(&ctx_, input.peek_read(), input.available_read())) in Update() 184 if (CRYPTO_memcmp(signature.peek_read(), digest, siglen) != 0) in Finish()
|
D | aes_operation.cpp | 204 if (!InternalUpdate(input.peek_read(), input.available_read(), output, &error)) in Update() 561 if (!InternalUpdate(input.peek_read(), input.available_read(), output, &error)) in Update() 569 BufferCandidateTagData(input.peek_read(), input.available_read()); in ProcessAllButTagLengthBytes() 586 if (!InternalUpdate(input.peek_read(), to_process_from_input, output, &error)) in ProcessAllButTagLengthBytes() 589 BufferCandidateTagData(input.peek_read() + to_process_from_input, in ProcessAllButTagLengthBytes()
|
D | hkdf_test.cpp | 86 EXPECT_EQ(0, memcmp(expected.data(), secret_key.peek_read(), expected.size())); in TEST()
|
D | android_keymaster_messages_test.cpp | 278 EXPECT_EQ(0, memcmp(deserialized->input.peek_read(), "foo", 3)); in TEST() 306 EXPECT_EQ(0, memcmp(deserialized->output.peek_read(), "foo", 3)); in TEST() 345 EXPECT_EQ(0, memcmp(deserialized->signature.peek_read(), "bar", 3)); in TEST() 369 EXPECT_EQ(0, memcmp(msg.output.peek_read(), deserialized->output.peek_read(), in TEST() 510 EXPECT_EQ(0, memcmp("foo", deserialized->random_data.peek_read(), 3)); in TEST()
|
D | serializable.cpp | 143 return append_size_and_data_to_buf(buf, end, peek_read(), available_read()); in Serialize()
|
D | android_keymaster.cpp | 159 response->error = context_->AddRngEntropy(request.random_data.peek_read(), in AddRngEntropy()
|
D | soft_keymaster_device.cpp | 892 memcpy(tmp, response.output.peek_read(), output->data_length); in update() 931 memcpy(tmp, response.output.peek_read(), output->data_length); in finish()
|
/system/keymaster/include/keymaster/ |
D | serializable.h | 205 return Reinitialize(buffer.peek_read(), buffer.available_read()); in Reinitialize() 208 const uint8_t* begin() const { return peek_read(); } in begin() 209 const uint8_t* end() const { return peek_read() + available_read(); } in end() 219 const uint8_t* peek_read() const { return buffer_.get() + read_position_; } in peek_read() function
|