port to python3
This commit is contained in:
parent
14f426afd4
commit
8e27b9f76e
51 changed files with 272 additions and 248 deletions
|
|
@ -19,9 +19,9 @@ def generate_ssl():
|
|||
key = OpenSSL.crypto.PKey()
|
||||
key.generate_key(OpenSSL.crypto.TYPE_RSA, 2048)
|
||||
with open(settings.ssl_key_path, 'wb') as fd:
|
||||
os.chmod(settings.ssl_key_path, 0600)
|
||||
os.chmod(settings.ssl_key_path, 0o600)
|
||||
fd.write(OpenSSL.crypto.dump_privatekey(OpenSSL.crypto.FILETYPE_PEM, key))
|
||||
os.chmod(settings.ssl_key_path, 0400)
|
||||
os.chmod(settings.ssl_key_path, 0o400)
|
||||
|
||||
ca = OpenSSL.crypto.X509()
|
||||
ca.set_version(2)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue