Index: net/ssl/token_binding.h |
diff --git a/net/ssl/token_binding.h b/net/ssl/token_binding.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..70924cb7e44230cafa6f955768cbe596f54f1f4a |
--- /dev/null |
+++ b/net/ssl/token_binding.h |
@@ -0,0 +1,27 @@ |
+// Copyright 2015 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef NET_SSL_TOKEN_BINDING_H_ |
+#define NET_SSL_TOKEN_BINDING_H_ |
+ |
+#include <string> |
+#include <vector> |
+ |
+namespace net { |
+ |
+// Given a vector of serialized TokenBinding structs (as defined in |
+// draft-ietf-tokbind-protocol-02), this function combines them to form the |
+// serialized TokenBindingMessage struct in |*out|. This function returns a net |
+// error. |
+// |
+// struct { |
+// TokenBinding tokenbindings<0..2^16-1>; |
+// } TokenBindingMessage; |
+int BuildTokenBindingMessageFromTokenBindings( |
+ const std::vector<std::string>& token_bindings, |
+ std::string* out); |
+ |
+} // namespace net |
+ |
+#endif // NET_SSL_TOKEN_BINDING_H_ |