MCPcopy Create free account
hub / github.com/mozilla/cipherscan / build_ciphers_lists

Function build_ciphers_lists

analyze.py:398–416  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

396 return exit_status
397
398def build_ciphers_lists():
399 sstlsurl = "https://statics.tls.security.mozilla.org/server-side-tls-conf.json"
400 conf = dict()
401 try:
402 raw = urlopen(sstlsurl).read()
403 conf = json.loads(raw)
404 logging.debug('retrieving online server side tls recommendations from %s' % sstlsurl)
405 except URLError:
406 with open('server-side-tls-conf.json', 'r') as f:
407 conf = json.load(f)
408 logging.debug('Error connecting to %s; using local archive of server side tls recommendations' % sstlsurl)
409 except:
410 print("failed to retrieve JSON configurations from %s" % sstlsurl)
411 sys.exit(23)
412
413 global old, inter, modern
414 old = conf["configurations"]["old"]
415 inter = conf["configurations"]["intermediate"]
416 modern = conf["configurations"]["modern"]
417
418def main():
419 parser = argparse.ArgumentParser(

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected