mirror of https://github.com/MISP/mail_to_misp
fixed file upload
parent
ee4be71e19
commit
cf51e183b0
|
@ -273,7 +273,8 @@ if stdin_used:
|
|||
_, output_path = tempfile.mkstemp()
|
||||
output = open(output_path, 'wb')
|
||||
output.write(part.get_payload(decode=True))
|
||||
misp.upload_sample(filename, output_path, new_event, distribution=None, to_ids=True, category=None, comment=None, info='My Info', analysis=None, threat_level_id=None)
|
||||
event_id = new_event['Event']['id']
|
||||
misp.upload_sample(filename, output_path, event_id, distribution=None, to_ids=True, category=None, comment=None, info='My Info', analysis=None, threat_level_id=None)
|
||||
output.close()
|
||||
|
||||
syslog.syslog("Job finished.")
|
||||
|
|
Loading…
Reference in New Issue