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

Side by Side Diff: net/quic/core/crypto/aead_base_encrypter.cc

Issue 2599143003: Add a new QUIC platform API quic_aligned.h for the alignment macro definitions. (Closed)
Patch Set: windows Created 3 years, 12 months 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
« no previous file with comments | « net/net.gypi ('k') | net/quic/core/quic_arena_scoped_ptr.h » ('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/core/crypto/aead_base_encrypter.h" 5 #include "net/quic/core/crypto/aead_base_encrypter.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "net/quic/core/quic_types.h"
10 #include "net/quic/core/quic_utils.h" 9 #include "net/quic/core/quic_utils.h"
10 #include "net/quic/platform/api/quic_aligned.h"
11 #include "third_party/boringssl/src/include/openssl/err.h" 11 #include "third_party/boringssl/src/include/openssl/err.h"
12 #include "third_party/boringssl/src/include/openssl/evp.h" 12 #include "third_party/boringssl/src/include/openssl/evp.h"
13 13
14 using base::StringPiece; 14 using base::StringPiece;
15 15
16 namespace net { 16 namespace net {
17 17
18 namespace { 18 namespace {
19 19
20 // The maximum size in bytes of the nonce, including 8 bytes of sequence number. 20 // The maximum size in bytes of the nonce, including 8 bytes of sequence number.
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
153 153
154 StringPiece AeadBaseEncrypter::GetNoncePrefix() const { 154 StringPiece AeadBaseEncrypter::GetNoncePrefix() const {
155 if (nonce_prefix_size_ == 0) { 155 if (nonce_prefix_size_ == 0) {
156 return StringPiece(); 156 return StringPiece();
157 } 157 }
158 return StringPiece(reinterpret_cast<const char*>(nonce_prefix_), 158 return StringPiece(reinterpret_cast<const char*>(nonce_prefix_),
159 nonce_prefix_size_); 159 nonce_prefix_size_);
160 } 160 }
161 161
162 } // namespace net 162 } // namespace net
OLDNEW
« no previous file with comments | « net/net.gypi ('k') | net/quic/core/quic_arena_scoped_ptr.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698