OLD | NEW |
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 Loading... |
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 |
OLD | NEW |