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 e0cc572 commit 165193fCopy full SHA for 165193f
pydatastructs/graphs/graph.py
@@ -2,8 +2,16 @@
2
from pydatastructs.utils.misc_util import Backend, raise_if_backend_is_not_python
3
from pydatastructs.utils.misc_util import GraphEdge
4
from pydatastructs.utils import AdjacencyListGraphNode
5
-
6
+import hmac
+import hashlib
7
+import os
8
+import secrets
9
+import threading
10
+def rotate_secret_key():
11
+ """ Automatically rotates secret key after 30 days """
12
+ while True:
13
+ os.environ["HMAC_SECRET_KEY"] = secrets.token_hax(32)
14
+ time.sleep(30 * 24 * 60 * 60)
15
__all__ = [
16
'Graph'
17
]
0 commit comments