diff options
author | Devtools Arcadia <arcadia-devtools@yandex-team.ru> | 2022-02-07 18:08:42 +0300 |
---|---|---|
committer | Devtools Arcadia <arcadia-devtools@mous.vla.yp-c.yandex.net> | 2022-02-07 18:08:42 +0300 |
commit | 1110808a9d39d4b808aef724c861a2e1a38d2a69 (patch) | |
tree | e26c9fed0de5d9873cce7e00bc214573dc2195b7 /certs/update-certs.py | |
download | ydb-1110808a9d39d4b808aef724c861a2e1a38d2a69.tar.gz |
intermediate changes
ref:cde9a383711a11544ce7e107a78147fb96cc4029
Diffstat (limited to 'certs/update-certs.py')
-rwxr-xr-x | certs/update-certs.py | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/certs/update-certs.py b/certs/update-certs.py new file mode 100755 index 0000000000..13a2dabc94 --- /dev/null +++ b/certs/update-certs.py @@ -0,0 +1,21 @@ +#!/usr/bin/env python2 +# -*- coding: utf-8 -*- + +import urllib2 + +COMMON_ROOT_CAS_URL = "https://mkcert.org/generate" +YANDEX_INTERNAL_CAS_URL = "https://crls.yandex.net/allCAs.pem" + +def get_text(url): + return urllib2.urlopen(url).read() + +common_root_cas = get_text(COMMON_ROOT_CAS_URL) +yandex_internal_cas = get_text(YANDEX_INTERNAL_CAS_URL) + +with open("cacert.pem", "wt") as target: + target.write(common_root_cas) + target.write(yandex_internal_cas) + +with open("yandex_internal.pem", "wt") as target: + target.write(yandex_internal_cas) + |