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.14.tar.gz
(19.7 kB
view details)
Built Distribution
File details
Details for the file baseblock-0.2.14.tar.gz
.
File metadata
- Download URL: baseblock-0.2.14.tar.gz
- Upload date:
- Size: 19.7 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 | 1e682a0662422210ed4c1710bbd48f2961b21a20de8c697a59c975a4bc844667 |
|
MD5 | 92d961516edfa70f27a095f957c407c7 |
|
BLAKE2b-256 | 591f8527f468638675b5c93b01a088179bef02ef2febc5e064b96c5b1b64b20f |
File details
Details for the file baseblock-0.2.14-py3-none-any.whl
.
File metadata
- Download URL: baseblock-0.2.14-py3-none-any.whl
- Upload date:
- Size: 22.7 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 | 1203812c04f69d25348030975718f53b46dc571c2651863e6401d12e9d1589db |
|
MD5 | 2ca804791d9f4f912d9676e45e2b584a |
|
BLAKE2b-256 | cb51f3d65966b66400e5081cab7b173c062e7e3d16e4e8885838b29a99a21240 |