Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1668)

Unified Diff: net/quic/crypto/aes_128_gcm_12_encrypter_nss.cc

Issue 83123006: Conver DLOG(INFO) to DVLOG(1) in QUIC code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix new messages Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/quic/crypto/aes_128_gcm_12_decrypter_nss.cc ('k') | net/quic/crypto/p256_key_exchange_nss.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/crypto/aes_128_gcm_12_encrypter_nss.cc
diff --git a/net/quic/crypto/aes_128_gcm_12_encrypter_nss.cc b/net/quic/crypto/aes_128_gcm_12_encrypter_nss.cc
index e100edee192998b3e2fc5f51f4418210d752f5cf..2cd072af461783721d7ecd4972d67599612dfc21 100644
--- a/net/quic/crypto/aes_128_gcm_12_encrypter_nss.cc
+++ b/net/quic/crypto/aes_128_gcm_12_encrypter_nss.cc
@@ -138,7 +138,7 @@ SECStatus My_Encrypt(PK11SymKey* key,
DCHECK_EQ(param->len, sizeof(CK_GCM_PARAMS));
if (max_len < static_cast<unsigned int>(Aes128Gcm12Encrypter::kAuthTagSize)) {
- DLOG(INFO) << "max_len is less than kAuthTagSize";
+ DVLOG(1) << "max_len is less than kAuthTagSize";
PORT_SetError(SEC_ERROR_OUTPUT_LEN);
return SECFailure;
}
@@ -149,7 +149,7 @@ SECStatus My_Encrypt(PK11SymKey* key,
DCHECK_EQ(gcm_params->ulTagBits,
static_cast<CK_ULONG>(Aes128Gcm12Encrypter::kAuthTagSize * 8));
if (gcm_params->ulIvLen != 12u) {
- DLOG(INFO) << "ulIvLen is not equal to 12";
+ DVLOG(1) << "ulIvLen is not equal to 12";
PORT_SetError(SEC_ERROR_INPUT_LEN);
return SECFailure;
}
@@ -161,20 +161,20 @@ SECStatus My_Encrypt(PK11SymKey* key,
crypto::ScopedPK11Context ctx(PK11_CreateContextBySymKey(
CKM_AES_ECB, CKA_ENCRYPT, key, &my_param));
if (!ctx) {
- DLOG(INFO) << "PK11_CreateContextBySymKey failed";
+ DVLOG(1) << "PK11_CreateContextBySymKey failed";
return SECFailure;
}
int output_len;
if (PK11_CipherOp(ctx.get(), ghash_key, &output_len, sizeof(ghash_key),
ghash_key, sizeof(ghash_key)) != SECSuccess) {
- DLOG(INFO) << "PK11_CipherOp failed";
+ DVLOG(1) << "PK11_CipherOp failed";
return SECFailure;
}
PK11_Finalize(ctx.get());
if (output_len != sizeof(ghash_key)) {
- DLOG(INFO) << "Wrong output length";
+ DVLOG(1) << "Wrong output length";
PORT_SetError(SEC_ERROR_LIBRARY_FAILURE);
return SECFailure;
}
@@ -195,7 +195,7 @@ SECStatus My_Encrypt(PK11SymKey* key,
ctx.reset(PK11_CreateContextBySymKey(CKM_AES_CTR, CKA_ENCRYPT, key,
&my_param));
if (!ctx) {
- DLOG(INFO) << "PK11_CreateContextBySymKey failed";
+ DVLOG(1) << "PK11_CreateContextBySymKey failed";
return SECFailure;
}
@@ -203,11 +203,11 @@ SECStatus My_Encrypt(PK11SymKey* key,
unsigned char tag_mask[16] = {0};
if (PK11_CipherOp(ctx.get(), tag_mask, &output_len, sizeof(tag_mask),
tag_mask, sizeof(tag_mask)) != SECSuccess) {
- DLOG(INFO) << "PK11_CipherOp failed";
+ DVLOG(1) << "PK11_CipherOp failed";
return SECFailure;
}
if (output_len != sizeof(tag_mask)) {
- DLOG(INFO) << "Wrong output length";
+ DVLOG(1) << "Wrong output length";
PORT_SetError(SEC_ERROR_LIBRARY_FAILURE);
return SECFailure;
}
@@ -217,21 +217,21 @@ SECStatus My_Encrypt(PK11SymKey* key,
// https://bugzilla.mozilla.org/show_bug.cgi?id=808218).
if (PK11_CipherOp(ctx.get(), out, &output_len, max_len,
const_cast<unsigned char*>(data), data_len) != SECSuccess) {
- DLOG(INFO) << "PK11_CipherOp failed";
+ DVLOG(1) << "PK11_CipherOp failed";
return SECFailure;
}
PK11_Finalize(ctx.get());
if (static_cast<unsigned int>(output_len) != data_len) {
- DLOG(INFO) << "Wrong output length";
+ DVLOG(1) << "Wrong output length";
PORT_SetError(SEC_ERROR_LIBRARY_FAILURE);
return SECFailure;
}
if ((max_len - Aes128Gcm12Encrypter::kAuthTagSize) <
static_cast<unsigned int>(output_len)) {
- DLOG(INFO) << "(max_len - kAuthTagSize) is less than output_len";
+ DVLOG(1) << "(max_len - kAuthTagSize) is less than output_len";
PORT_SetError(SEC_ERROR_OUTPUT_LEN);
return SECFailure;
}
@@ -300,7 +300,7 @@ bool Aes128Gcm12Encrypter::Encrypt(StringPiece nonce,
PK11_FreeSlot(slot);
slot = NULL;
if (!aes_key) {
- DLOG(INFO) << "PK11_ImportSymKey failed";
+ DVLOG(1) << "PK11_ImportSymKey failed";
return false;
}
@@ -323,12 +323,12 @@ bool Aes128Gcm12Encrypter::Encrypt(StringPiece nonce,
output, &output_len, ciphertext_size,
reinterpret_cast<const unsigned char*>(plaintext.data()),
plaintext.size()) != SECSuccess) {
- DLOG(INFO) << "My_Encrypt failed";
+ DVLOG(1) << "My_Encrypt failed";
return false;
}
if (output_len != ciphertext_size) {
- DLOG(INFO) << "Wrong output length";
+ DVLOG(1) << "Wrong output length";
return false;
}
« no previous file with comments | « net/quic/crypto/aes_128_gcm_12_decrypter_nss.cc ('k') | net/quic/crypto/p256_key_exchange_nss.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698