Documentation
¶
Overview ¶
Package mocknvd is an embedded HTTP server that serves canned NVD 2.0 CVE API JSON. It is shared by the Go unit tests (httptest) and the standalone cmd/mockserver binary used by the haybarn SQL E2E. It honors the same query parameters as the real NVD endpoint that this worker uses:
cveId=CVE-2021-44228 -> a Log4Shell-shaped record (10.0, CRITICAL) cveId=CVE-2099-00000 (or any other unknown id) -> HTTP 404 keywordSearch=... -> a paginated 2-page response (3 records) cpeName=... -> CVEs affecting a CPE
Pagination is driven by resultsPerPage / startIndex exactly like NVD.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.