chg: [onyphe] fix #252

pipenv
Alexandre Dulaunoy 2018-11-11 15:49:14 +01:00
parent 2ccc8fd405
commit 5d1583d88b
No known key found for this signature in database
GPG Key ID: 09E2CD4944E6CBCD
3 changed files with 7 additions and 7 deletions

View File

@ -65,16 +65,16 @@ def handle_expansion(api, ip, misperrors):
for r in result['results']:
if r['@category'] == 'pastries':
if r['@type'] == 'pastebin':
if r['source'] == 'pastebin':
urls_pasties.append('https://pastebin.com/raw/%s' % r['key'])
elif r['@category'] == 'synscan':
asn_list.append(r['asn'])
os_target = r['os']
if os_target != 'Unknown':
os_list.append(r['os'])
elif r['@category'] == 'resolver' and r['@type'] =='reverse':
elif r['@category'] == 'resolver' and r['type'] =='reverse':
domains_resolver.append(r['reverse'])
elif r['@category'] == 'resolver' and r['@type'] =='forward':
elif r['@category'] == 'resolver' and r['type'] =='forward':
domains_forward.append(r['forward'])
result_filtered['results'].append({'types': ['url'], 'values': urls_pasties,
@ -105,4 +105,4 @@ def introspection():
def version():
moduleinfo['config'] = moduleconfig
return moduleinfo
return moduleinfo

View File

@ -315,7 +315,7 @@ def expand_pastries(api, misperror, **kwargs):
status_ok = True
for item in result['results']:
if item['@category'] == 'pastries':
if item['@type'] == 'pastebin':
if item['source'] == 'pastebin':
urls_pasties.append('https://pastebin.com/raw/%s' % item['key'])
if 'domain' in item:
@ -374,4 +374,4 @@ def introspection():
def version():
moduleinfo['config'] = moduleconfig
return moduleinfo
return moduleinfo

View File

@ -1 +1 @@
{"module": "hashdd", "md5": "838DE99E82C5B9753BAC96D82C1A8DCB"}
{"module": "hashdd", "md5": "838DE99E82C5B9753BAC96D82C1A8DCC"}