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

Side by Side Diff: net/ssl/token_binding.h

Issue 2332473002: Use new BoringSSL scopers in //crypto (Closed)
Patch Set: rebase Created 4 years, 2 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 | « extensions/browser/api/cast_channel/BUILD.gn ('k') | net/ssl/token_binding.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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 #ifndef NET_SSL_TOKEN_BINDING_H_ 5 #ifndef NET_SSL_TOKEN_BINDING_H_
6 #define NET_SSL_TOKEN_BINDING_H_ 6 #define NET_SSL_TOKEN_BINDING_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/strings/string_piece.h" 11 #include "base/strings/string_piece.h"
12 #include "crypto/ec_private_key.h"
13 #include "net/base/net_errors.h" 12 #include "net/base/net_errors.h"
14 #include "net/base/net_export.h" 13 #include "net/base/net_export.h"
15 14
15 namespace crypto {
16 class ECPrivateKey;
17 }
18
16 namespace net { 19 namespace net {
17 20
18 enum class TokenBindingType { 21 enum class TokenBindingType {
19 PROVIDED = 0, 22 PROVIDED = 0,
20 REFERRED = 1, 23 REFERRED = 1,
21 }; 24 };
22 25
23 // Takes an exported keying material value |ekm| from the TLS layer, the type of 26 // Takes an exported keying material value |ekm| from the TLS layer, the type of
24 // Token Binding |type|, and a token binding key |key| and concatenates the 27 // Token Binding |type|, and a token binding key |key| and concatenates the
25 // Token Binding type, key type, and ekm. This concatenation is signed with 28 // Token Binding type, key type, and ekm. This concatenation is signed with
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 // the signature verifies and false if it doesn't or some other error occurs in 112 // the signature verifies and false if it doesn't or some other error occurs in
110 // verification. This function is only provided for testing. 113 // verification. This function is only provided for testing.
111 NET_EXPORT_PRIVATE bool VerifyTokenBindingSignature(base::StringPiece ec_point, 114 NET_EXPORT_PRIVATE bool VerifyTokenBindingSignature(base::StringPiece ec_point,
112 base::StringPiece signature, 115 base::StringPiece signature,
113 TokenBindingType type, 116 TokenBindingType type,
114 base::StringPiece ekm); 117 base::StringPiece ekm);
115 118
116 } // namespace net 119 } // namespace net
117 120
118 #endif // NET_SSL_TOKEN_BINDING_H_ 121 #endif // NET_SSL_TOKEN_BINDING_H_
OLDNEW
« no previous file with comments | « extensions/browser/api/cast_channel/BUILD.gn ('k') | net/ssl/token_binding.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698