Skip to content

Fix: exclude NASL include libraries from VT information - #2452

Closed
pcbeingused333 wants to merge 1 commit into
greenbone:mainfrom
pcbeingused333:fix/exclude-nasl-includes-from-vt-api
Closed

pcbeingused333 wants to merge 1 commit into
greenbone:mainfrom
pcbeingused333:fix/exclude-nasl-includes-from-vt-api

Conversation

@pcbeingused333

Copy link
Copy Markdown
Contributor

Fixes #2451

GET /vts?information=1 loads every row from the plugin table. NASL .inc files are stored there as empty VTData records so feed integrity checks can track them. They are not vulnerability tests: the tag is empty and there is no severity. gvmd reads those records as NVT metadata, logs SEVERITY missing value, and retries the direct-OpenVASD feed sync indefinitely.

GET /vts already hides the same rows. get_oids selects oid NOT LIKE '%inc'. get_vts did not, so information=1 still returned the include libraries.

get_vts now uses that same filter. The include rows stay in the plugin table for the integrity check.

database::sqlite::vts::tests::get_oids syncs the example feed, requires that no returned oid or VT filename ends in .inc, and checks that plugin_feed_info.inc is still stored. That assertion fails on the unfiltered query and passes with the filter. api_tests::get_vts_with_information matches the updated response, which no longer contains plugin_feed_info.inc.

This change was prepared with the assistance of an AI coding tool.

GET /vts?information=1 read every plugin row, including the empty
VTData records stored for NASL .inc integrity checks. Those records
have no severity, so gvmd rejects them and retries the feed sync.

Use the same oid filter as get_oids. The include rows stay stored.

Signed-off-by: Alex Castillo <alex.castillog33@gmail.com>
@pcbeingused333
pcbeingused333 requested a review from a team as a code owner November 13, 2026 06:50
@github-actions github-actions Bot added needs_review Needs a review. This means the PR was either newly opened or the last review has been addressed patch_release creates a patch release and removed needs_review Needs a review. This means the PR was either newly opened or the last review has been addressed labels Nov 13, 2026
@tehforsch

Copy link
Copy Markdown
Contributor

Thanks, closing as already done in #2454

@tehforsch tehforsch closed this Nov 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs_review Needs a review. This means the PR was either newly opened or the last review has been addressed patch_release creates a patch release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

openvasd: exclude NASL include libraries from VT API responses

2 participants