Long key
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2021-04-25 19:15:08 +02:00
parent c5d4859326
commit 45bab9c9f3
5 changed files with 12 additions and 4 deletions

View File

@@ -12,7 +12,7 @@ def generatePrivateKeyForUser(auth: Authetication,username: str, user_passphrase
with open(auth.CONFIG_FILE_LOCATION) as json_file:
data = json.load(json_file)
private_key = RSA.generate(2048)
private_key = RSA.generate(8192)
public_key = private_key.publickey()
private_key_value = bytes.hex(private_key.exportKey('DER', passphrase=user_passphrase, pkcs=8))
public_key_value = bytes.hex(public_key.exportKey('DER', pkcs=8))
@@ -44,7 +44,7 @@ def generatePrivateKeyForServer(auth: Authetication,passphrase: str) -> str:
data = json.load(json_file)
json_file.close()
private_key = RSA.generate(2048)
private_key = RSA.generate(8192)
public_key = private_key.publickey()
private_key_value = bytes.hex(private_key.exportKey('DER', passphrase=passphrase, pkcs=8, protection="scryptAndAES128-CBC"))
public_key_value = bytes.hex(public_key.exportKey('DER', pkcs=8))