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

Side by Side Diff: net/quic/crypto/aes_128_gcm_12_decrypter_test.cc

Issue 82913011: LOG(INFO) tidying in net/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: revert dns_fuzz_stub changes Created 7 years 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « net/quic/congestion_control/quic_congestion_manager.cc ('k') | net/quic/quic_config_test.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "net/quic/crypto/aes_128_gcm_12_decrypter.h" 5 #include "net/quic/crypto/aes_128_gcm_12_decrypter.h"
6 6
7 #include "net/quic/test_tools/quic_test_utils.h" 7 #include "net/quic/test_tools/quic_test_utils.h"
8 8
9 using base::StringPiece; 9 using base::StringPiece;
10 10
(...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after
303 if (!decrypter->Decrypt(nonce, associated_data, ciphertext, 303 if (!decrypter->Decrypt(nonce, associated_data, ciphertext,
304 reinterpret_cast<unsigned char*>(plaintext.get()), 304 reinterpret_cast<unsigned char*>(plaintext.get()),
305 &plaintext_size)) { 305 &plaintext_size)) {
306 return NULL; 306 return NULL;
307 } 307 }
308 return new QuicData(plaintext.release(), plaintext_size, true); 308 return new QuicData(plaintext.release(), plaintext_size, true);
309 } 309 }
310 310
311 TEST(Aes128Gcm12DecrypterTest, Decrypt) { 311 TEST(Aes128Gcm12DecrypterTest, Decrypt) {
312 if (!Aes128Gcm12Decrypter::IsSupported()) { 312 if (!Aes128Gcm12Decrypter::IsSupported()) {
313 LOG(INFO) << "AES GCM not supported. Test skipped."; 313 VLOG(0) << "AES GCM not supported. Test skipped.";
314 return; 314 return;
315 } 315 }
316 316
317 char key[1024]; 317 char key[1024];
318 size_t key_len; 318 size_t key_len;
319 char iv[1024]; 319 char iv[1024];
320 size_t iv_len; 320 size_t iv_len;
321 char ct[1024]; 321 char ct[1024];
322 size_t ct_len; 322 size_t ct_len;
323 char aad[1024]; 323 char aad[1024];
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
377 377
378 ASSERT_EQ(pt_len, decrypted->length()); 378 ASSERT_EQ(pt_len, decrypted->length());
379 test::CompareCharArraysWithHexError("plaintext", decrypted->data(), 379 test::CompareCharArraysWithHexError("plaintext", decrypted->data(),
380 pt_len, pt, pt_len); 380 pt_len, pt, pt_len);
381 } 381 }
382 } 382 }
383 } 383 }
384 384
385 } // namespace test 385 } // namespace test
386 } // namespace net 386 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/congestion_control/quic_congestion_manager.cc ('k') | net/quic/quic_config_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698