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

Unified Diff: net/tools/transport_security_state_generator/resources/transport_security_state_static.template

Issue 2726873003: Make transport security state data source configurable. (Closed)
Patch Set: ternary Created 3 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/http/transport_security_state_static.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/tools/transport_security_state_generator/resources/transport_security_state_static.template
diff --git a/net/tools/transport_security_state_generator/resources/transport_security_state_static.template b/net/tools/transport_security_state_generator/resources/transport_security_state_static.template
index 87a2511da7dabf6c4c3712bd61cdc7283321d2bc..1d33a46a59a4930aa609d057db8a7eda09c082b6 100644
--- a/net/tools/transport_security_state_generator/resources/transport_security_state_static.template
+++ b/net/tools/transport_security_state_generator/resources/transport_security_state_static.template
@@ -9,6 +9,8 @@
#include <stdint.h>
+#include "net/http/transport_security_state_source.h"
+
enum SecondLevelDomainName [[DOMAIN_IDS]];
// These are SubjectPublicKeyInfo hashes for public key pinning. The
@@ -29,13 +31,7 @@ static const char kNoReportURI[] = "";
[[ACCEPTABLE_CERTS]]
-struct Pinset {
- const char* const* const accepted_pins;
- const char* const* const rejected_pins;
- const char* const report_uri;
-};
-
-static const struct Pinset kPinsets[] = [[PINSETS]];
+static const net::TransportSecurityStateSource::Pinset kPinsets[] = [[PINSETS]];
// kHSTSHuffmanTree describes a Huffman tree. The nodes of the tree are pairs
// of uint8s. The last node in the array is the root of the tree. Each pair is
@@ -49,4 +45,16 @@ static const uint8_t kPreloadedHSTSData[] = [[HSTS_TRIE]];
static const unsigned kPreloadedHSTSBits = [[HSTS_TRIE_BITS]];
static const unsigned kHSTSRootPosition = [[HSTS_TRIE_ROOT]];
+static const net::TransportSecurityStateSource kHSTSSource = {
+ kHSTSHuffmanTree,
+ sizeof(kHSTSHuffmanTree),
+ kPreloadedHSTSData,
+ kPreloadedHSTSBits,
+ kHSTSRootPosition,
+ kExpectCTReportURIs,
+ kExpectStapleReportURIs,
+ kPinsets,
+ arraysize(kPinsets)
+};
+
#endif // NET_HTTP_TRANSPORT_SECURITY_STATE_STATIC_H_
« no previous file with comments | « net/http/transport_security_state_static.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698