We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent eb468ae commit ec0e445Copy full SHA for ec0e445
conditional/config.py
@@ -1,7 +1,6 @@
1
-import random
2
-import string
3
-
+import secrets
4
from os import environ as env
+
5
from conditional import __version__
6
7
# Flask config
@@ -36,8 +35,7 @@
36
35
}
37
38
# Openshift secret
39
-SECRET_KEY = env.get("CONDITIONAL_SECRET_KEY", default=''.join(
40
- random.SystemRandom().choice(string.ascii_uppercase + string.digits) for _ in range(64)))
+SECRET_KEY = env.get("CONDITIONAL_SECRET_KEY", default=''.join(secrets.token_hex(16)))
41
42
# General config
43
DUES_PER_SEMESTER = env.get("CONDITIONAL_DUES_PER_SEMESTER", 80)
0 commit comments