Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add NVT tag "deprecated" #1536

Merged
merged 2 commits into from
May 28, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).

## [21.4.1] (unreleased)

### Added
- Add NVT tag "deprecated" [#1536](https://github.com/greenbone/gvmd/pull/1536)

### Fixed
- Improve VT version handling for CVE & OVAL results [#1496](https://github.com/greenbone/gvmd/pull/1496)
- Update subject alternative name in certificate generation [#1503](https://github.com/greenbone/gvmd/pull/1503)
Expand Down
8 changes: 7 additions & 1 deletion src/manage_sql_nvts.c
Original file line number Diff line number Diff line change
Expand Up @@ -1244,7 +1244,7 @@ nvti_from_vt (entity_t vt)
const char *id;
entity_t name, summary, insight, affected, impact, detection, solution;
entity_t creation_time, modification_time;
entity_t refs, ref, custom, family, category;
entity_t refs, ref, custom, family, category, deprecated;
entity_t severities, severity;

entities_t children;
Expand Down Expand Up @@ -1468,6 +1468,12 @@ nvti_from_vt (entity_t vt)
}
nvti_set_category (nvti, atoi (entity_text (category)));

deprecated = entity_child (custom, "deprecated");
if (deprecated)
{
nvti_add_tag (nvti, "deprecated", entity_text (deprecated));
}

return nvti;
}

Expand Down