Created
April 13, 2018 08:55
-
-
Save oskar456/c489909a8543bc8f162b2fd8188d76bf to your computer and use it in GitHub Desktop.
Preprocess Certificate Transparency log list for Cert Spotter
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import requests | |
import json | |
log_list = "https://www.gstatic.com/ct/log_list/log_list.json" | |
logs = requests.get(log_list).json() | |
outlogs = [] | |
for log in logs["logs"]: | |
if "disqualified_at" in log: | |
continue | |
log["url"] = log["url"].rstrip("/") | |
outlogs.append(log) | |
print(json.dumps(dict(logs=outlogs), indent=4)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment