Index: crypto/encryptor_openssl.cc |
diff --git a/crypto/encryptor_openssl.cc b/crypto/encryptor_openssl.cc |
index 0504adbcb9f74d3c8f9506a69671d7cb4dfd871b..0bf96b79df2df6da140a51e9ed73330e077b8273 100644 |
--- a/crypto/encryptor_openssl.cc |
+++ b/crypto/encryptor_openssl.cc |
@@ -19,6 +19,7 @@ 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; |
} |
@@ -99,8 +100,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), iv_.length()); |
- DCHECK_EQ(EVP_CIPHER_key_length(cipher), key.length()); |
+ DCHECK_EQ(EVP_CIPHER_iv_length(cipher), static_cast<int>(iv_.length())); |
+ DCHECK_EQ(EVP_CIPHER_key_length(cipher), static_cast<int>(key.length())); |
ScopedCipherCTX ctx; |
if (!EVP_CipherInit_ex(ctx.get(), cipher, NULL, |