Skip to content

Commit 1b7db4f

Browse files
authored
Merge pull request #557 from secureCodeBox/maintenance/make-findings-schema-stricter
Name, Severity and Category are now required Findings attributes
2 parents 37139ba + e14724f commit 1b7db4f

File tree

5 files changed

+496
-493
lines changed

5 files changed

+496
-493
lines changed

parser-sdk/nodejs/findings-schema.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,10 @@
6262
},
6363
"required": [
6464
"id",
65-
"parsed_at"
65+
"parsed_at",
66+
"severity",
67+
"category",
68+
"name"
6669
]
6770
}
6871
}

scanners/nmap/parser/parser.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ function transformToFindings(hosts) {
2121

2222
return openPorts.map(openPort => {
2323
return {
24-
name: openPort.service,
24+
name: openPort.service ? `Open Port: ${openPort.port} (${openPort.service})`: `Open Port: ${openPort.port}`,
2525
description: `Port ${openPort.port} is ${openPort.state} using ${openPort.protocol} protocol.`,
2626
category: 'Open Port',
2727
location: `${openPort.protocol}://${hostInfo.ip}:${openPort.port}`,

0 commit comments

Comments
 (0)