MCPcopy Create free account
hub / github.com/IQEngine/IQEngine / encrypt

Function encrypt

api/helpers/cipher.py:26–32  ·  view source on GitHub ↗
(sas_token: SecretStr)

Source from the content-addressed store, hash-verified

24
25
26def encrypt(sas_token: SecretStr):
27 key = get_key()
28 if not key:
29 return None
30 cipher_suite = Fernet(key)
31 cipher_text = cipher_suite.encrypt(sas_token.get_secret_value().encode())
32 return cipher_text.decode("utf-8")

Callers 2

createFunction · 0.90
update_datasourceFunction · 0.90

Calls 1

get_keyFunction · 0.85

Tested by

no test coverage detected