Base Block of Common Enterprise Python Utilities
Project description
Base Block (baseblock)
Base Block of Common Enterprise Python Utilities
Crypto Base
Usage
from baseblock import CryptoBase
key = CryptoBase.generate_private_key()
The key
is used to both encrypt and decrypt text, like this:
input_text = "Hello, World!"
crypt = CryptoBase(key)
x = crypt.encrypt_str(input_text)
y = crypt.decrypt_str(x)
assert input_text == y
The key can also be stored in the environment under BASEBLOCK_CRYPTO_KEY.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
baseblock-0.2.18.tar.gz
(20.0 kB
view details)
Built Distribution
File details
Details for the file baseblock-0.2.18.tar.gz
.
File metadata
- Download URL: baseblock-0.2.18.tar.gz
- Upload date:
- Size: 20.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.13 CPython/3.8.5 Windows/10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8e1aa2229af5a7ba31272091e0e0b1058804f2908700e832d27429c39d84bf24 |
|
MD5 | b63b70473119507de25c8a7037365b6a |
|
BLAKE2b-256 | 3b38e77d8500a637acec448a1dec87e87fa26c53c28ff26a97702dbf1db9fe9e |
File details
Details for the file baseblock-0.2.18-py3-none-any.whl
.
File metadata
- Download URL: baseblock-0.2.18-py3-none-any.whl
- Upload date:
- Size: 23.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.13 CPython/3.8.5 Windows/10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f0cc3a737280478dabb4ac7aff88498332fd09fd6e35e1a8f4be899457207d84 |
|
MD5 | dc2870c8c6e9c014149813a4409de7ec |
|
BLAKE2b-256 | 2a2d0db31864811468a8c6de56eb0566e7693db4cc9a2bc1f293e1f9b194f053 |