diff --git a/blockchain_integration/pi_network/pi-stablecoin/utils/crypto.py b/blockchain_integration/pi_network/pi-stablecoin/utils/crypto.py new file mode 100644 index 000000000..0bf387f5e --- /dev/null +++ b/blockchain_integration/pi_network/pi-stablecoin/utils/crypto.py @@ -0,0 +1,9 @@ +import hashlib + +def encrypt(data, key): + encrypted_data = hashlib.sha256(data.encode()).hexdigest() + return encrypted_data + +def decrypt(encrypted_data, key): + decrypted_data = hashlib.sha256(encrypted_data.encode()).hexdigest() + return decrypted_data