Skip to content

Commit

Permalink
Fix: Allow results port to take value package
Browse files Browse the repository at this point in the history
Allow package as a valid value for a result port in notes and
overrides.
  • Loading branch information
a-h-abdelsalam authored and timopollmeier committed Apr 22, 2024
1 parent 111143e commit 058bcf9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/manage_sql.c
Original file line number Diff line number Diff line change
Expand Up @@ -32674,6 +32674,9 @@ validate_results_port (const char *port)
if (!port)
return 1;

if (strcmp (port, "package") == 0)
return 0;

/* "cpe:abc", "general/tcp", "20/udp"
*
* We keep the "general/tcp" case pretty open because it is not clearly
Expand Down
1 change: 1 addition & 0 deletions src/manage_sql_tests.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ Ensure (manage_sql, validate_results_port_validates)
PASS ("1/tcp");
PASS ("8080/tcp");
PASS ("65535/tcp");
PASS ("package");

FAIL (NULL);
FAIL ("cpe:/a:.joomclan:com_joomclip cpe:two");
Expand Down

0 comments on commit 058bcf9

Please sign in to comment.