⚡ Quick Start
Prerequisites
- Python 3.11+
pip- Docker (optional, for running tests)
Installation
Install the core package:
pip install .
For full feature support (AWS, Database, Security checks):
pip install ".[db,aws,security]"
Run
Run the verifier against your local .env file:
vault-check --env-file .env
Demo
Copy-paste this snippet to see vault-check in action with a dummy configuration:
# Create a dummy .env file
echo "DATABASE_URL=postgres://user:pass@localhost:5432/db" > .env
echo "JWT_SECRET=supersecretpassword123" >> .env
# Run a dry-run check (validates format and entropy only)
vault-check --dry-run
✨ Features
🛡️ Security & Core
- Entropy Analysis: Automatically detects weak secrets using
zxcvbn(e.g., warns on "password123"). - Live Probes: Performs actual network connections (e.g.,
SELECT 1for DBs,/getMefor Telegram Bots) to verify credentials. - Async & Concurrent: Built on
asyncioandaiohttpfor high-performance parallel verification.
🔌 Integrations
- Multi-Source Loading: Fetch secrets from
.env, Doppler, AWS SSM, or HashiCorp Vault. - Broad Protocol Support: Verifiers for PostgreSQL, Redis, Telegram API, Google OAuth, Razorpay, and more.
📊 Observability
- Web Dashboard: Built-in dashboard to visualize verification reports and trigger runs.
- Actionable Reports: JSON output and detailed logging for CI/CD pipelines.
🛠️ Configuration
Environment Variables
vault-check automatically detects and verifies these keys in your environment:
| Variable Name | Description | Required |
|---|---|---|
*_DB_URL |
Database connection string (Postgres/SQLite). | No |
*_REDIS_URL |
Redis connection URL. | No |
SESSION_ENCRYPTION_KEY |
Fernet encryption key (checked for entropy). | No |
JWT_SECRET |
JWT signing secret (checked for entropy). | No |
JWT_EXPIRATION_MINUTES |
JWT expiration time (integer). | No |
API_ID / API_HASH |
Telegram Client API credentials. | No |
*_BOT_TOKEN |
Telegram Bot Token (checked via live API call). | No |
OWNER_TELEGRAM_ID |
Telegram User ID of the bot owner. | No |
ACCOUNTS_API_KEY |
Key for internal Accounts API. | No |
RAZORPAY_KEY_ID |
Razorpay public key. | No |
GOOGLE_CLIENT_ID |
Google OAuth client ID. | No |
CLI Arguments
| Flag | Description | Default |
|---|---|---|
--env-file |
Path to the .env file. |
.env |
--doppler-project |
Doppler project name. | bot-platform |
--aws-ssm-prefix |
Prefix for AWS SSM parameters. | None |
--log-level |
Logging verbosity (DEBUG, INFO, WARNING, ERROR). | INFO |
--concurrency |
Number of concurrent verifier tasks. | 5 |
--dry-run |
Validate formats/entropy without network calls. | False |
--dashboard |
Launch the web dashboard. | False |
--dashboard-port |
Port for the web dashboard. | 8000 |
--output-json |
Path to save the verification report as JSON. | None |
🏗️ Architecture
Directory Tree
src/vault_check/
├── cli.py # Entry point, argument parsing
├── runner.py # Orchestrates async verification tasks
├── secrets.py # Loads secrets from Env, Doppler, AWS
├── registry.py # Manages discovery of verifier plugins
├── dashboard.py # Web server for the dashboard UI
├── verifiers/ # Individual verification logic
│ ├── database.py # DB connection checks
│ ├── http_check.py # Generic HTTP checks
│ └── ...
└── config.py # Configuration constants and schemas
Data Flow
- Input: The user invokes the CLI, specifying secret sources (local file, Doppler, AWS).
- Load:
secrets.pyaggregates secrets into a unified dictionary. - Discover:
runner.pyinspects the secrets and matches them against registered verifiers inregistry.py. - Execute: The
ExecutionEngineruns matched verifiers concurrently. Each verifier performs syntax checks (dry-run) or live probes. - Report: Results (errors, warnings, suggestions) are collected and output to the console, a JSON file, or the Dashboard.
🐞 Troubleshooting
| Error Message | Possible Solution |
|---|---|
Connection refused |
Ensure the service (DB, Redis) is running and reachable from the host. |
Authentication failed |
Check that the username/password in the secret is correct. |
Entropy too low |
The secret is too weak (e.g. "123456"). Generate a stronger key. |
ModuleNotFoundError |
Ensure you installed optional dependencies (pip install ".[db]"). |
Debug Mode
To see detailed logs of what vault-check is doing (including HTTP requests and secret loading details), use the --log-level flag:
vault-check --log-level DEBUG
🤝 Contributing
We welcome contributions!
Dev Setup
-
Clone the repository:
git clone https://github.com/dhruv13x/vault-check.git cd vault-check
-
Install development dependencies:
pip install -e ".[dev,db,aws,security]"
-
Run the tests to ensure everything is working:
pytest
-
Install pre-commit hooks to enforce code quality:
pre-commit install
Please follow standard GitHub Pull Request workflows.
🗺️ Roadmap
- Plugin System: Fully documented guide for creating 3rd-party verifiers.
- GitHub Action: Official action for CI/CD integration.
- Pre-commit Hook: Native pre-commit hook support.
- Automated Rotation: Integration to rotate weak secrets automatically.
- AI Anomaly Detection: Analyze secret usage patterns for security risks.
Metadata
Release files for vault-check 8.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| vault_check-8.0.0.tar.gz | 33.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| vault_check-8.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 72.3 kB
Release files / vault_check-8.0.0.tar.gz
| Download URL | vault_check-8.0.0.tar.gz |
|---|---|
| Size | 33.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ea500fdaa432d07406819cb176eb2b3464554ee2b2db96afadcf3ea60e0c9d11
|
|
BLAKE2b-256 checksum How to use checksums |
ac296001ccb52e3de19fedc92010b64118bc6a246c676130b25fa855bafbe203
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 2, 2026.
Transparency logRelease files / vault_check-8.0.0-py3-none-any.whl
| Download URL | vault_check-8.0.0-py3-none-any.whl |
|---|---|
| Size | 38.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
2b590d1d5b5f7811e7d5e490943861bb31a6dd6e4eb19869e46bac829b87fd8b
|
|
BLAKE2b-256 checksum How to use checksums |
e5c200bcd1ef9b2418bdbe2ae3458bf1fb7713e61506615b59e321d00ed674bc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 2, 2026.
Transparency log