VulnDB Executor¶
Category: Vulnerability Scanners
Script: vulndb.py
Integration: REST API (HMAC)
Faraday Plugin: Raw JSON
Website: https://vulndb.flashpoint.io
Description¶
Queries the VulnDB (Flashpoint) vulnerability database for the vulnerabilities that affect a CPE or a vendor/product and imports them into Faraday. VulnDB has no assets of its own, so each query target becomes a synthetic host with the matching vulnerabilities attached.
Prerequisites¶
- A VulnDB (Flashpoint) subscription with API access
- A VulnDB API consumer key and secret
- Network access from the agent to the VulnDB API (
https://vulndb.cyberriskanalytics.comby default)
Configuration¶
Environment Variables (Setup)¶
| Variable | Required | Description |
|---|---|---|
VULNDB_KEY |
Yes | VulnDB API consumer key |
VULNDB_SECRET |
Yes | VulnDB API consumer secret, used to sign each request |
VULNDB_HOST |
No | VulnDB API base URL (default: https://vulndb.cyberriskanalytics.com) |
These variables are also accepted as execution arguments, so a single run can override them.
Execution Arguments¶
| Parameter | Type | Mandatory | Description |
|---|---|---|---|
VULNDB_CPE |
string | No* | CPE 2.3 string to query (e.g., cpe:2.3:a:apache:http_server:2.4.54) |
VULNDB_VENDOR |
string | No* | Vendor name or numeric VulnDB vendor ID (e.g., apache or 15) |
VULNDB_PRODUCT |
string | No | Product name to narrow the vendor query (e.g., http_server). Ignored without VULNDB_VENDOR. |
VULNDB_LIMIT |
integer | No | Maximum number of vulnerabilities to import per query (default: 100) |
* You must set VULNDB_CPE, VULNDB_VENDOR, or both.
YAML Configuration Example¶
executors:
vulndb:
repo_executor: vulndb.py
max_size: 65536
varenvs:
VULNDB_KEY: "<consumer_key>"
VULNDB_SECRET: "<consumer_secret>"
params:
VULNDB_CPE:
mandatory: false
type: string
base: string
VULNDB_VENDOR:
mandatory: false
type: string
base: string
VULNDB_PRODUCT:
mandatory: false
type: string
base: string
VULNDB_LIMIT:
mandatory: false
type: integer
base: integer
How It Works¶
- Signs every request with HMAC-SHA1 using
VULNDB_KEYandVULNDB_SECRET - If
VULNDB_CPEis set, queries/api/v1/vulnerabilities?cpe=<cpe> - If
VULNDB_VENDORis set, resolves a vendor name to its ID with/api/v1/vendorsand queries/api/v1/vendors/{id}/vulnerabilities, filtered byVULNDB_PRODUCTwhen given - Pages through the results (up to 100 per page) until
VULNDB_LIMITis reached - Maps each entry to a vulnerability:
- Name: the VulnDB title
- Description: description, technical description and disclosure date
- Severity: from the CVSS score:
0is info, below4low, below7medium, below9high, otherwise critical. Entries without a score are info. - Resolution: the VulnDB solution
- References: external references and CVE IDs
- External ID: the VulnDB ID
Notes¶
- Each query creates one host with IP
0.0.0.0. Its hostname is the CPE string, orvendor/vendor/productfor vendor queries. Queries that return no vulnerabilities create no host. - When the vendor name has no exact match, the first result of the vendor lookup is used.
- Every vulnerability is tagged
vulndband created with statusopen. - At most 50 pages are read per query.
- TLS certificates are not verified.
- The run fails if the key or secret is rejected (
401). Other API errors stop the query and import what was already fetched. - The shared agent parameters (
AGENT_CONFIG_*tags and severity filters) are not applied by this executor.