Docker API Enumeration Tools
These scripts query the Docker Engine HTTP API to collect information about containers and secrets.
They are designed for security assessments and administrative auditing, providing quick insights into environment variables, secrets, and general engine configuration.
Warning: Exposing the Docker Engine API without TLS or authentication is a serious security risk.
Use these scripts only against environments you are authorized to assess.
Install
From pip:
pip install docker-enumsensitive
From github:
git clone https://github.com/DefensiveOrigins/DockerEngineAPI-EnumSensitive.git
Scripts
docker-enum-envvars / EnumEnvVars.py`
Enumerates running and stopped containers, extracts their environment variables, and prints them to the console.
Can also save the results in structured JSON.
docker-enum-secrets / EnumSecrets.py
Enumerates Secrets from Docker Swarm mode, attempting to read their values if specified. Can also save the results in structured JSON.
docker-enum-images / EnumImages.py
Inspects the contents of images for sensitive information such as tokens, keys, etc.
Usage
Environment Variables Enumeration
# Local Docker API (default: http://localhost:2375)
python EnumEnvVars.py
docker-enum-envvars
# Remote engine and save to file
python EnumEnvVars.py --url http://docker-host:2375 --out results.json
docker-enum-envvars --url http://docker-host:2375 --out results.json
# Include full /info JSON
python EnumEnvVars.py --show-info-json
docker-enum-envvars --show-info-json
Secrets Enumeration
# Local secrets enumeration
python EnumSecrets.py
docker-enum-secrets
# Remote engine, attempt values, save to file
python EnumSecrets.py --url http://docker-host:2375 --attempt-values --out secrets.json
docker-enum-secrets --url http://docker-host:2375 --attempt-values --out secrets.json
# Include full /info JSON
python EnumSecrets.py --show-info-json
docker-enum-secrets --show-info-json
Metadata
Release files for docker-enumsensitive 0.1.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| docker_enumsensitive-0.1.7.tar.gz | 9.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| docker_enumsensitive-0.1.7-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 21.5 kB
Release files / docker_enumsensitive-0.1.7.tar.gz
| Download URL | docker_enumsensitive-0.1.7.tar.gz |
|---|---|
| Size | 9.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
fa9120b2f23bd52291fd96f3a6c4308db31587512f2e78b20df32e305acf574e
|
|
BLAKE2b-256 checksum How to use checksums |
5eeea0c100bf8166140c7572fd1d3cd9f0bb9df47a992f7c51f47972cb2ddcf3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.14
|
Release files / docker_enumsensitive-0.1.7-py3-none-any.whl
| Download URL | docker_enumsensitive-0.1.7-py3-none-any.whl |
|---|---|
| Size | 12.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
04a3c71374e69f341c3011d5f85d517a5e2dfac31f6f38fbf2bb510ca2e64ed5
|
|
BLAKE2b-256 checksum How to use checksums |
fd4a2d8b72a07c4caad25ea6e7c73a53fb019db9018ca70d867f8976967d2c4c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.14
|