Searched defs:ciphertext (Results 1 - 7 of 7) sorted by relevance

/system/keymaster/
H A Docb_utils.cpp122 KeymasterKeyBlob* ciphertext, Buffer* tag) {
123 assert(ciphertext && tag);
137 if (!ciphertext->Reset(plaintext.key_material_size))
142 0 /* additional data length */, ciphertext->writable_data(),
157 const KeymasterKeyBlob& ciphertext, const Buffer& nonce,
173 if (!plaintext->Reset(ciphertext.key_material_size))
176 int ae_err = ae_decrypt(ctx.get(), nonce.peek_read(), ciphertext.key_material,
177 ciphertext.key_material_size, NULL /* additional data */,
190 assert(ae_err == static_cast<int>(ciphertext.key_material_size));
118 OcbEncryptKey(const AuthorizationSet& hw_enforced, const AuthorizationSet& sw_enforced, const AuthorizationSet& hidden, const KeymasterKeyBlob& master_key, const KeymasterKeyBlob& plaintext, const Buffer& nonce, KeymasterKeyBlob* ciphertext, Buffer* tag) argument
154 OcbDecryptKey(const AuthorizationSet& hw_enforced, const AuthorizationSet& sw_enforced, const AuthorizationSet& hidden, const KeymasterKeyBlob& master_key, const KeymasterKeyBlob& ciphertext, const Buffer& nonce, const Buffer& tag, KeymasterKeyBlob* plaintext) argument
H A Dandroid_keymaster_test.cpp1832 string ciphertext = EncryptMessage(message, KM_MODE_ECB, KM_PAD_PKCS7); local
1833 string plaintext = DecryptMessage(ciphertext, KM_MODE_ECB, KM_PAD_PKCS7);
1886 string ciphertext = EncryptMessage(message, KM_PAD_NONE); local
1887 EXPECT_EQ(256U / 8, ciphertext.size());
1890 string plaintext = DecryptMessage(ciphertext, KM_PAD_NONE);
2007 string ciphertext = EncryptMessage(string(message), KM_DIGEST_SHA_2_256, KM_PAD_RSA_OAEP); local
2008 EXPECT_EQ(key_size / 8, ciphertext.size());
2010 string plaintext = DecryptMessage(ciphertext, KM_DIGEST_SHA_2_256, KM_PAD_RSA_OAEP);
2024 string ciphertext = EncryptMessage(string(message), KM_DIGEST_SHA_2_224, KM_PAD_RSA_OAEP); local
2025 EXPECT_EQ(key_size / 8, ciphertext
2084 string ciphertext = EncryptMessage(string(message), KM_DIGEST_SHA_2_256, KM_PAD_RSA_OAEP); local
2128 string ciphertext = EncryptMessage(string(message), KM_DIGEST_SHA_2_256, KM_PAD_RSA_OAEP); local
2169 string ciphertext = EncryptMessage(message, KM_PAD_RSA_PKCS1_1_5_ENCRYPT); local
2207 string ciphertext = EncryptMessage(message, digest, padding); local
2240 string ciphertext = EncryptMessage(string(message), KM_PAD_RSA_PKCS1_1_5_ENCRYPT); local
2342 string ciphertext; local
2357 string ciphertext = EncryptMessage(message, KM_MODE_ECB, KM_PAD_PKCS7); local
2391 string ciphertext = EncryptMessage(message, KM_MODE_ECB, KM_PAD_PKCS7); local
2449 string ciphertext; local
2480 const char* ciphertext; member in struct:keymaster::test::AesCtrSp80038aTestVector
2519 const string ciphertext = hex2str(test.ciphertext); local
2667 string ciphertext; local
2704 string ciphertext = EncryptMessage(message, KM_MODE_CBC, KM_PAD_PKCS7, &iv); local
2732 string ciphertext; local
2798 string ciphertext; local
2824 uint8_t ciphertext[] = { local
2897 string ciphertext; local
2938 string ciphertext; local
3010 string ciphertext; local
3064 string ciphertext; local
3108 string ciphertext; local
3150 string ciphertext; local
3593 string ciphertext = EncryptMessage(message, KM_MODE_ECB, KM_PAD_NONE); local
3639 string ciphertext = EncryptMessage(message, KM_PAD_NONE); local
[all...]
H A Dandroid_keymaster_test_utils.cpp470 string ciphertext = local
479 return ciphertext;
501 string ciphertext = local
510 return ciphertext;
520 string ciphertext = local
529 return ciphertext;
540 string Keymaster2Test::DecryptMessage(const string& ciphertext, keymaster_padding_t padding) { argument
545 return ProcessMessage(KM_PURPOSE_DECRYPT, ciphertext, begin_params, update_params);
548 string Keymaster2Test::DecryptMessage(const string& ciphertext, keymaster_digest_t digest, argument
555 return ProcessMessage(KM_PURPOSE_DECRYPT, ciphertext, begin_param
558 DecryptMessage(const string& ciphertext, keymaster_block_mode_t block_mode, keymaster_padding_t padding) argument
568 DecryptMessage(const string& ciphertext, keymaster_digest_t digest, keymaster_padding_t padding, const string& nonce) argument
579 DecryptMessage(const string& ciphertext, keymaster_block_mode_t block_mode, keymaster_padding_t padding, const string& nonce) argument
590 DecryptMessage(const AuthorizationSet& update_params, const string& ciphertext, keymaster_digest_t digest, keymaster_padding_t padding, const string& nonce) argument
646 string ciphertext = local
[all...]
/system/tpm/trunks/
H A Dtpm_utility_test.cc469 std::string output_ciphertext("ciphertext");
470 std::string ciphertext; local
487 &ciphertext));
488 EXPECT_EQ(0, ciphertext.compare(output_ciphertext));
494 std::string ciphertext; local
507 plaintext, nullptr, &ciphertext));
513 std::string ciphertext; local
522 plaintext, nullptr, &ciphertext));
528 std::string output_ciphertext("ciphertext");
529 std::string ciphertext; local
555 std::string ciphertext; local
580 std::string ciphertext; local
606 std::string ciphertext; local
627 std::string ciphertext; local
644 std::string ciphertext; local
655 std::string ciphertext; local
683 std::string ciphertext; local
[all...]
H A Dtrunks_client_test.cc475 std::string ciphertext; local
478 "plaintext", nullptr, &ciphertext);
492 scoped_key.get(), TPM_ALG_NULL, TPM_ALG_NULL, ciphertext,
638 std::string ciphertext; local
640 "plaintext", nullptr, &ciphertext);
660 ciphertext, policy_session->GetDelegate(),
760 std::string ciphertext; local
762 "plaintext", nullptr, &ciphertext);
781 ciphertext, policy_session->GetDelegate(),
991 std::string ciphertext; local
[all...]
H A Dtpm_utility_impl.cc412 std::string* ciphertext) {
463 ciphertext->assign(StringFrom_TPM2B_PUBLIC_KEY_RSA(out_message));
470 const std::string& ciphertext,
520 TPM2B_PUBLIC_KEY_RSA in_message = Make_TPM2B_PUBLIC_KEY_RSA(ciphertext);
407 AsymmetricEncrypt(TPM_HANDLE key_handle, TPM_ALG_ID scheme, TPM_ALG_ID hash_alg, const std::string& plaintext, AuthorizationDelegate* delegate, std::string* ciphertext) argument
467 AsymmetricDecrypt(TPM_HANDLE key_handle, TPM_ALG_ID scheme, TPM_ALG_ID hash_alg, const std::string& ciphertext, AuthorizationDelegate* delegate, std::string* plaintext) argument
/system/vold/
H A DKeyStorage.cpp218 const KeyBuffer& message, std::string* ciphertext) {
237 *ciphertext = nonce + body + mac;
243 const std::string& ciphertext, KeyBuffer* message) {
244 auto nonce = ciphertext.substr(0, GCM_NONCE_BYTES);
245 auto bodyAndMac = ciphertext.substr(GCM_NONCE_BYTES);
328 const KeyBuffer& plaintext, std::string* ciphertext) {
331 if (!readRandomBytesOrLog(GCM_NONCE_BYTES, ciphertext)) return false;
340 reinterpret_cast<const uint8_t*>(ciphertext->data()))) {
344 ciphertext->resize(GCM_NONCE_BYTES + plaintext.size() + GCM_MAC_BYTES);
347 reinterpret_cast<uint8_t*>(&(*ciphertext)[
216 encryptWithKeymasterKey(Keymaster& keymaster, const std::string& dir, const AuthorizationSet &keyParams, const KeyBuffer& message, std::string* ciphertext) argument
241 decryptWithKeymasterKey(Keymaster& keymaster, const std::string& dir, const AuthorizationSet &keyParams, const std::string& ciphertext, KeyBuffer* message) argument
327 encryptWithoutKeymaster(const std::string& preKey, const KeyBuffer& plaintext, std::string* ciphertext) argument
373 decryptWithoutKeymaster(const std::string& preKey, const std::string& ciphertext, KeyBuffer* plaintext) argument
[all...]

Completed in 667 milliseconds