/system/webservd/webservd/ |
H A D | fake_encryptor.cc | 22 // ciphertext. Obviously, this should be used only for testing. 26 std::string* ciphertext) override { 27 *ciphertext = brillo::data_encoding::Base64Encode(plaintext); 31 bool DecryptWithAuthentication(const std::string& ciphertext, 33 return brillo::data_encoding::Base64Decode(ciphertext, plaintext);
|
H A D | encryptor.h | 29 // |ciphertext|. Returns true on success. 31 std::string* ciphertext) = 0; 33 // Decrypts and authenticates the given |ciphertext| and emits the 35 virtual bool DecryptWithAuthentication(const std::string& ciphertext,
|
H A D | fake_encryptor.h | 25 // ciphertext. Obviously, this should be used only for testing. 29 std::string* ciphertext) override; 31 bool DecryptWithAuthentication(const std::string& ciphertext,
|
H A D | keystore_encryptor.cc | 40 std::string* ciphertext) { 42 ciphertext); 45 bool KeystoreEncryptor::DecryptWithAuthentication(const std::string& ciphertext, argument 47 return keystore_->decryptWithAuthentication(kWebserverKeyName, ciphertext, 39 EncryptWithAuthentication(const std::string& plaintext, std::string* ciphertext) argument
|
H A D | keystore_encryptor.h | 36 std::string* ciphertext) override; 37 bool DecryptWithAuthentication(const std::string& ciphertext,
|
/system/connectivity/shill/ |
H A D | crypto_rot47.cc | 31 bool CryptoROT47::Encrypt(const string& plaintext, string* ciphertext) { argument 37 *ciphertext = plaintext; 38 for (auto& ch : *ciphertext) { 48 bool CryptoROT47::Decrypt(const string& ciphertext, string* plaintext) { argument 50 return Encrypt(ciphertext, plaintext);
|
H A D | crypto_interface.h | 32 // Encrypts |plaintext| into |ciphertext|. Returns true on success. 34 std::string* ciphertext) = 0; 36 // Decrypts |ciphertext| into |plaintext|. Returns true on success. 37 virtual bool Decrypt(const std::string& ciphertext,
|
H A D | crypto_provider.cc | 49 string ciphertext; local 50 if (crypto->Encrypt(plaintext, &ciphertext)) { 52 return prefix + ciphertext; 59 string CryptoProvider::Decrypt(const string& ciphertext) { argument 62 if (base::StartsWith(ciphertext, prefix, base::CompareCase::SENSITIVE)) { 63 string to_decrypt = ciphertext; 74 return ciphertext;
|
H A D | crypto_rot47.h | 37 virtual bool Encrypt(const std::string& plaintext, std::string* ciphertext); 38 virtual bool Decrypt(const std::string& ciphertext, std::string* plaintext);
|
H A D | crypto_des_cbc.h | 50 virtual bool Encrypt(const std::string& plaintext, std::string* ciphertext); 51 virtual bool Decrypt(const std::string& ciphertext, std::string* plaintext);
|
H A D | crypto_des_cbc.cc | 42 bool CryptoDESCBC::Encrypt(const string& plaintext, string* ciphertext) { argument 48 bool CryptoDESCBC::Decrypt(const string& ciphertext, string* plaintext) { argument 52 string b64_ciphertext = ciphertext; 53 if (base::StartsWith(ciphertext, kVersion2Prefix, 61 LOG(ERROR) << "Unable to base64-decode DEC-CBC ciphertext."; 68 LOG(ERROR) << "Invalid DES-CBC ciphertext size: " << data.size();
|
H A D | crypto_provider.h | 41 // Returns |ciphertext| decrypted by the highest priority available crypto 43 // |ciphertext| as is. 44 std::string Decrypt(const std::string& ciphertext);
|
H A D | crypto_des_cbc_unittest.cc | 97 string ciphertext; local 98 EXPECT_FALSE(crypto_.Encrypt(kPlainText, &ciphertext));
|
/system/weaved/buffet/ |
H A D | fake_encryptor.cc | 26 std::string* ciphertext) override { 27 *ciphertext = brillo::data_encoding::Base64Encode(plaintext); 31 bool DecryptWithAuthentication(const std::string& ciphertext, 33 return brillo::data_encoding::Base64Decode(ciphertext, plaintext);
|
H A D | keystore_encryptor.cc | 40 std::string* ciphertext) { 42 ciphertext); 45 bool KeystoreEncryptor::DecryptWithAuthentication(const std::string& ciphertext, argument 47 return keystore_->decryptWithAuthentication(kBuffetKeyName, ciphertext, 39 EncryptWithAuthentication(const std::string& plaintext, std::string* ciphertext) argument
|
H A D | encryptor.h | 32 // |ciphertext|. Returns true on success. 34 std::string* ciphertext) = 0; 36 // Decrypts and authenticates the given |ciphertext| and emits the 38 virtual bool DecryptWithAuthentication(const std::string& ciphertext,
|
H A D | keystore_encryptor.h | 36 std::string* ciphertext) override; 37 bool DecryptWithAuthentication(const std::string& ciphertext,
|
H A D | buffet_config_unittest.cc | 94 std::string* ciphertext) override { 95 *ciphertext = brillo::data_encoding::Base64Encode(plaintext); 98 bool DecryptWithAuthentication(const std::string& ciphertext, 101 brillo::data_encoding::Base64Decode(ciphertext, plaintext);
|
/system/keymaster/ |
H A D | ocb_utils.h | 38 KeymasterKeyBlob* ciphertext, Buffer* tag); 43 const KeymasterKeyBlob& ciphertext, const Buffer& nonce,
|
H A D | ocb_utils.cpp | 122 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 D | android_keymaster_test.cpp | 1916 string ciphertext = EncryptMessage(message, KM_MODE_ECB, KM_PAD_PKCS7); local 1917 string plaintext = DecryptMessage(ciphertext, KM_MODE_ECB, KM_PAD_PKCS7); 1970 string ciphertext = EncryptMessage(message, KM_PAD_NONE); local 1971 EXPECT_EQ(256U / 8, ciphertext.size()); 1974 string plaintext = DecryptMessage(ciphertext, KM_PAD_NONE); 2092 string ciphertext = EncryptMessage(string(message), KM_DIGEST_SHA_2_256, KM_PAD_RSA_OAEP); local 2093 EXPECT_EQ(key_size / 8, ciphertext.size()); 2095 string plaintext = DecryptMessage(ciphertext, KM_DIGEST_SHA_2_256, KM_PAD_RSA_OAEP); 2109 string ciphertext = EncryptMessage(string(message), KM_DIGEST_SHA_2_224, KM_PAD_RSA_OAEP); local 2110 EXPECT_EQ(key_size / 8, ciphertext 2169 string ciphertext = EncryptMessage(string(message), KM_DIGEST_SHA_2_256, KM_PAD_RSA_OAEP); local 2213 string ciphertext = EncryptMessage(string(message), KM_DIGEST_SHA_2_256, KM_PAD_RSA_OAEP); local 2254 string ciphertext = EncryptMessage(message, KM_PAD_RSA_PKCS1_1_5_ENCRYPT); local 2292 string ciphertext = EncryptMessage(message, digest, padding); local 2325 string ciphertext = EncryptMessage(string(message), KM_PAD_RSA_PKCS1_1_5_ENCRYPT); local 2427 string ciphertext; local 2445 string ciphertext = EncryptMessage(message, KM_MODE_ECB, KM_PAD_PKCS7); local 2479 string ciphertext = EncryptMessage(message, KM_MODE_ECB, KM_PAD_PKCS7); local 2537 string ciphertext; local 2568 const char* ciphertext; member in struct:keymaster::test::AesCtrSp80038aTestVector 2607 const string ciphertext = hex2str(test.ciphertext); local 2755 string ciphertext; local 2792 string ciphertext = EncryptMessage(message, KM_MODE_CBC, KM_PAD_PKCS7, &iv); local 2820 string ciphertext; local 2886 string ciphertext; local 2912 uint8_t ciphertext[] = { local 2985 string ciphertext; local 3026 string ciphertext; local 3098 string ciphertext; local 3152 string ciphertext; local 3196 string ciphertext; local 3238 string ciphertext; local 3678 string ciphertext = EncryptMessage(message, KM_MODE_ECB, KM_PAD_NONE); local 3724 string ciphertext = EncryptMessage(message, KM_PAD_NONE); local [all...] |
H A D | android_keymaster_test_utils.cpp | 475 string ciphertext = local 484 return ciphertext; 506 string ciphertext = local 515 return ciphertext; 525 string ciphertext = local 534 return ciphertext; 545 string Keymaster2Test::DecryptMessage(const string& ciphertext, keymaster_padding_t padding) { argument 550 return ProcessMessage(KM_PURPOSE_DECRYPT, ciphertext, begin_params, update_params); 553 string Keymaster2Test::DecryptMessage(const string& ciphertext, keymaster_digest_t digest, argument 560 return ProcessMessage(KM_PURPOSE_DECRYPT, ciphertext, begin_param 563 DecryptMessage(const string& ciphertext, keymaster_block_mode_t block_mode, keymaster_padding_t padding) argument 573 DecryptMessage(const string& ciphertext, keymaster_digest_t digest, keymaster_padding_t padding, const string& nonce) argument 584 DecryptMessage(const string& ciphertext, keymaster_block_mode_t block_mode, keymaster_padding_t padding, const string& nonce) argument 595 DecryptMessage(const AuthorizationSet& update_params, const string& ciphertext, keymaster_digest_t digest, keymaster_padding_t padding, const string& nonce) argument 651 string ciphertext = local [all...] |
H A D | android_keymaster_test_utils.h | 261 std::string DecryptMessage(const std::string& ciphertext, keymaster_padding_t padding); 262 std::string DecryptMessage(const std::string& ciphertext, keymaster_digest_t digest, 264 std::string DecryptMessage(const std::string& ciphertext, keymaster_block_mode_t block_mode, 266 std::string DecryptMessage(const std::string& ciphertext, keymaster_digest_t digest, 268 std::string DecryptMessage(const std::string& ciphertext, keymaster_block_mode_t block_mode, 270 std::string DecryptMessage(const AuthorizationSet& update_params, const std::string& ciphertext, 273 std::string DecryptMessage(const AuthorizationSet& update_params, const std::string& ciphertext,
|
/system/vold/ |
H A D | KeyStorage.cpp | 141 const std::string& message, std::string* ciphertext) { 160 *ciphertext = nonce + body + mac; 166 const std::string& ciphertext, std::string* message) { 167 auto nonce = ciphertext.substr(0, GCM_NONCE_BYTES); 168 auto bodyAndMac = ciphertext.substr(GCM_NONCE_BYTES); 139 encryptWithKeymasterKey(Keymaster& keymaster, const std::string& key, const KeyAuthentication& auth, const std::string& appId, const std::string& message, std::string* ciphertext) argument 164 decryptWithKeymasterKey(Keymaster& keymaster, const std::string& key, const KeyAuthentication& auth, const std::string& appId, const std::string& ciphertext, std::string* message) argument
|
/system/tpm/trunks/ |
H A D | trunks_client_test.cc | 479 std::string ciphertext; local 483 &ciphertext); 497 TPM_ALG_NULL, ciphertext, 644 std::string ciphertext; local 646 "plaintext", nullptr, &ciphertext); 666 ciphertext, policy_session->GetDelegate(), 766 std::string ciphertext; local 768 "plaintext", nullptr, &ciphertext); 787 ciphertext, policy_session->GetDelegate(), 962 std::string ciphertext; local [all...] |