summaryrefslogtreecommitdiff
path: root/tools/submitcert.py
diff options
context:
space:
mode:
Diffstat (limited to 'tools/submitcert.py')
-rwxr-xr-xtools/submitcert.py19
1 files changed, 19 insertions, 0 deletions
diff --git a/tools/submitcert.py b/tools/submitcert.py
index 7844dda..702ffb3 100755
--- a/tools/submitcert.py
+++ b/tools/submitcert.py
@@ -13,12 +13,31 @@ certfile = sys.argv[2]
lookup_in_log = True
+publickeys = {
+ "https://ct.googleapis.com/pilot/":
+ "MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEfahLEimAoz2t01p3uMziiLOl/fHTD"
+ "M0YDOhBRuiBARsV4UvxG2LdNgoIGLrtCzWE0J5APC2em4JlvR8EEEFMoA==",
+
+ "https://127.0.0.1:8080/":
+ "MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE4qWq6afhBUi0OdcWUYhyJLNXTkGqQ9"
+ "PMS5lqoCgkV2h1ZvpNjBH2u8UbgcOQwqDo66z6BWQJGolozZYmNHE2kQ==",
+
+ "https://flimsy.ct.nordu.net/":
+ "MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE4qWq6afhBUi0OdcWUYhyJLNXTkGqQ9"
+ "PMS5lqoCgkV2h1ZvpNjBH2u8UbgcOQwqDo66z6BWQJGolozZYmNHE2kQ==",
+}
+
+
certs = get_certs_from_file(certfile)
result = add_chain(baseurl, {"chain":certs})
print result
+publickey = base64.decodestring(publickeys[baseurl])
+
+check_signature(publickey, base64.decodestring(certs[0]), result)
+
for cert in certs:
print get_cert_info(base64.decodestring(cert))