Env-driven secrets loading and security primitives: .env resolution, password hashing, and JWT token utilities.
Project description
abstract_security
Env-driven secrets loading and security primitives: .env resolution,
password hashing, token utilities, and a library of type/path/ssh helpers.
abstract_security is the foundation layer of the Abstract Secure Backend
stack. Everything else builds on it for locating .env files, reading secrets,
hashing passwords, and issuing/validating tokens.
Where this fits
abstract-securefiles React/TypeScript UI components
abstract_logins Flask blueprints: auth + secure files
abstract_queries Domain query managers (users, uploads, ...)
abstract_database Lazy PostgreSQL connection + helpers
abstract_security <-- you are here: env loading, hashing, tokens, utilities
Dependencies flow downward; this layer depends only on abstract_utilities and
python-dotenv.
Install
pip install abstract_security
Requires Python ≥ 3.6.
Usage
from abstract_security import get_env_value, get_env_path
# Resolve a value from a .env file, searching sensible default locations
# (cwd, home, and ~/.envy_all) unless an explicit path is given.
db_url = get_env_value("ABSTRACT_DATABASE_URL")
env_file = get_env_path() # where the .env was found
It also exposes password/token helpers (bcrypt hashing, JWT) and a broad set of
utility modules (type_utils, path_utils, ssh_utils, string_utils,
compare_utils, …) shared across the stack.
Design notes
- Flexible
.envdiscovery — looks in the current working directory, the home directory, and a dedicated~/.envy_alldirectory, or an explicit path. - One definition per symbol — shared primitives like
SingletonMetaare defined once, so behaviour is predictable across the stack.
License
MIT.
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file abstract_security-0.82.tar.gz.
File metadata
- Download URL: abstract_security-0.82.tar.gz
- Upload date:
- Size: 7.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
accfdc23d5aef17dc348b6e6dbae62346ef54d3051bebf7889269a5fdec552e8
|
|
| MD5 |
107517cd181a2d5d5658f9d0e9a1f8d5
|
|
| BLAKE2b-256 |
d2fd68c4e2933fa360404eed3b00a6f87e9ad8f1d865242b96f981cee87c3d78
|
File details
Details for the file abstract_security-0.82-py3-none-any.whl.
File metadata
- Download URL: abstract_security-0.82-py3-none-any.whl
- Upload date:
- Size: 9.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fe88b131051eed84f63d20780aa44b195fa9084b37792a7d1032198e05738712
|
|
| MD5 |
3ef4011f85b7a8e3b1b5ebdc74babda9
|
|
| BLAKE2b-256 |
545c463d7e7e5aed648e8ddabd5bf1ff57b55c710ac66964ebcd09dd36eae901
|