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.1.44.tar.gz
(18.4 kB
view details)
Built Distribution
File details
Details for the file baseblock-0.1.44.tar.gz
.
File metadata
- Download URL: baseblock-0.1.44.tar.gz
- Upload date:
- Size: 18.4 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 | faa467f5fe64f8ea38087b5b19fb160f3f18cec1d501d42a5490a7b07cbe2337 |
|
MD5 | 54ac66042ad6954b437003a900a87bfe |
|
BLAKE2b-256 | a79bcdc9e84d2ced550ab9ee6891fc9baf207f2954a580fef02351958e865204 |
File details
Details for the file baseblock-0.1.44-py3-none-any.whl
.
File metadata
- Download URL: baseblock-0.1.44-py3-none-any.whl
- Upload date:
- Size: 21.4 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 | 64fdc57357313bf353a130da55b2030a7a0ada583851160864c19d1d47b63a09 |
|
MD5 | 7bbec9824703fd0b9e23314ed278eaf1 |
|
BLAKE2b-256 | 24599e4a0416762630f8d464b8792533cd2f2f08eccc3734bdea60af7d0c3e23 |