From 675d5e126b007d9b6db0223a4c1100a4dc8f55c9 Mon Sep 17 00:00:00 2001 From: "agl@chromium.org" Date: Wed, 16 Jul 2014 22:15:31 +0000 Subject: Switch to BoringSSL. (This is a much larger change than its diff suggests. If it breaks something, please revert first and ask questions later.) R=davidben@chromium.org, eroman@chromium.org, rsleevi@chromium.org Review URL: https://codereview.chromium.org/345063006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@283542 0039d316-1c4b-4281-b951-d872f2087c98 --- crypto/encryptor_openssl.cc | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'crypto/encryptor_openssl.cc') diff --git a/crypto/encryptor_openssl.cc b/crypto/encryptor_openssl.cc index 0bf96b7..0504adb 100644 --- a/crypto/encryptor_openssl.cc +++ b/crypto/encryptor_openssl.cc @@ -19,7 +19,6 @@ namespace { const EVP_CIPHER* GetCipherForKey(SymmetricKey* key) { switch (key->key().length()) { case 16: return EVP_aes_128_cbc(); - case 24: return EVP_aes_192_cbc(); case 32: return EVP_aes_256_cbc(); default: return NULL; } @@ -100,8 +99,8 @@ bool Encryptor::Crypt(bool do_encrypt, DCHECK(cipher); // Already handled in Init(); const std::string& key = key_->key(); - DCHECK_EQ(EVP_CIPHER_iv_length(cipher), static_cast(iv_.length())); - DCHECK_EQ(EVP_CIPHER_key_length(cipher), static_cast(key.length())); + DCHECK_EQ(EVP_CIPHER_iv_length(cipher), iv_.length()); + DCHECK_EQ(EVP_CIPHER_key_length(cipher), key.length()); ScopedCipherCTX ctx; if (!EVP_CipherInit_ex(ctx.get(), cipher, NULL, -- cgit v1.1