Renamed _memory_use in cryptography into MEMORY_USAGE

This commit is contained in:
StNicolay 2022-11-07 21:02:13 +03:00
parent a1bed9014d
commit 559ee8f6d8

View File

@ -3,14 +3,14 @@ import os
from cryptography.exceptions import InvalidKey
from cryptography.hazmat.primitives.kdf.scrypt import Scrypt
_memory_use = 2**14
MEMORY_USAGE = 2**14
def _get_kdf(salt: bytes) -> Scrypt:
kdf = Scrypt(
salt=salt,
length=128,
n=_memory_use,
n=MEMORY_USAGE,
r=8,
p=1,
)