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

Fix entries that exist but have no value #71

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
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
@@ -1,3 +1,6 @@
v#.#.# (MMMM YYYY)
- Give a value of n/a even when entries have blank tags

v4.15.0 (December 2024)
- No changes

Expand Down
10 changes: 6 additions & 4 deletions lib/dradis/plugins/nessus/field_processor.rb
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,14 @@ def value(args={})
_, name = field.split('.')

if name.end_with?('entries')
# report_item.bid_entries
# report_item.cve_entries
# report_item.xref_entries
# bid_entries, cve_entries, cwe_entries, see_also_entries, xref_entries,
entries = @nessus_object.try(name)
if entries.any?
entries.to_a.join("\n")
if entries.to_a.join("\n").blank?
'n/a'
else
entries.to_a.join("\n")
end
else
'n/a'
end
Expand Down