Implementation:ARCANGEL0 EVA search vulnx
Appearance
| Knowledge Sources | |
|---|---|
| Domains | Vulnerability_Research, External_Tool_Integration |
| Last Updated | 2026-10-29 14:00 GMT |
Overview
Concrete tool for searching the Vulnx vulnerability database via the `vulnx` CLI subprocess, returning compacted CVE records with CVSS scores, provided by the Mitsu search module.
Description
The search_vulnx function invokes the `vulnx` command-line tool as a subprocess to search a vulnerability database. It:
- Auto-detects the binary using `shutil.which("vulnx")`.
- Runs with JSON output (`vulnx search <query> --limit 8 --json --silent`).
- Compacts records — extracts relevant fields (cve_id, name, description, severity, cvss_score, poc, references) and truncates each to a maximum length.
- Limits to 8 records and truncates output to 32KB.
- Handles errors — returns an error string if vulnx is not installed, times out (30s), or returns non-zero exit.
This is an External Tool Doc — it documents how the Mitsu repo wraps an external CLI tool.
Usage
- Vulnerability search orchestration: Called by `search_vulnerabilities` for the first 2 queries.
Code Reference
Source Location
- Repository: Mitsu
- File: search/vulnerabilities.py
Signature
def search_vulnx(
query: str,
executable: str | None = None,
prefix: tuple[str, ...] = (),
) -> tuple[str, str | None]:
Import
from mitsu.search.vulnerabilities import search_vulnx
I/O Contract
Inputs
| Name | Type | Required | Description |
|---|---|---|---|
| query | str | Yes | Search query string |
| executable | None | No | Path to vulnx binary (auto-detected if None) |
| prefix | tuple[str, ...] | No | Additional CLI arguments |
Outputs
| Name | Type | Description |
|---|---|---|
| returns[0] | str | JSON output (≤32KB) with CVE records, or empty on error |
| returns[1] | None | Error message or None on success |
Usage Examples
Search Vulnx Database
from mitsu.search.vulnerabilities import search_vulnx
result, error = search_vulnx("nginx 1.18")
if error:
print(f"Error: {error}")
else:
print(result) # JSON with CVE records
Related Pages
Implements Principle
Requires Environment
Page Connections
Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment