mirror of
https://github.com/valitydev/Cortex-Analyzers.git
synced 2024-11-07 01:25:21 +00:00
Update Shodan CVE now count and return result if less than 3
This commit is contained in:
parent
a21e603237
commit
f0bb403d31
@ -58,8 +58,11 @@ class ShodanAnalyzer(Analyzer):
|
||||
if 'asn' in raw['host']:
|
||||
taxonomies.append(self.build_taxonomy(level, namespace, 'ASN', raw['host']['asn']))
|
||||
if 'vulns' in raw['host']:
|
||||
taxonomies.append(self.build_taxonomy(levelorange, namespace, 'VULNS', raw['host']['vulns']))
|
||||
|
||||
totalcve = len(raw['host']['vulns'])
|
||||
if totalcve < 3:
|
||||
taxonomies.append(self.build_taxonomy(levelorange, namespace, 'VULNS', raw['host']['vulns']))
|
||||
else:
|
||||
taxonomies.append(self.build_taxonomy(levelorange, namespace, 'VULNS', totalcve))
|
||||
elif self.service == 'info_domain':
|
||||
if 'ips' in raw['infos_domain']:
|
||||
value = "{}".format(len(raw['infos_domain']['ips']))
|
||||
|
Loading…
Reference in New Issue
Block a user