mirror of
https://github.com/bookwyrm-social/bookwyrm.git
synced 2024-10-31 22:19:00 +00:00
increasing rsa key size
This commit is contained in:
parent
db207065ce
commit
2093c4760b
1 changed files with 1 additions and 1 deletions
|
@ -15,7 +15,7 @@ MAX_SIGNATURE_AGE = 300
|
||||||
def create_key_pair():
|
def create_key_pair():
|
||||||
"""a new public/private key pair, used for creating new users"""
|
"""a new public/private key pair, used for creating new users"""
|
||||||
random_generator = Random.new().read
|
random_generator = Random.new().read
|
||||||
key = RSA.generate(1024, random_generator)
|
key = RSA.generate(2048, random_generator)
|
||||||
private_key = key.export_key().decode("utf8")
|
private_key = key.export_key().decode("utf8")
|
||||||
public_key = key.public_key().export_key().decode("utf8")
|
public_key = key.public_key().export_key().decode("utf8")
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue