PyMISP icon indicating copy to clipboard operation
PyMISP copied to clipboard

Event reports not exported in Feed generator

Open cvandeplas opened this issue 2 years ago • 1 comments

The event reports are not exported by the Feed generator

cvandeplas avatar Nov 30 '21 11:11 cvandeplas

+1 for this feature request.

MISPEvent.to_feed() currently discards event reports.

It's easy enough to do something quick and dirty like:

event_feed = event_misp.to_feed(with_meta=True)
event_reports = misp.get_event_reports(event_misp.id)
event_feed['Event']['EventReport'] = [x['EventReport'] for x in event_reports]

But I really think they should just be included by this function in the first place.

UFOSmuggler avatar Feb 22 '22 01:02 UFOSmuggler

Another +1 for this. The workaround from @UFOSmuggler worked well for me but the event report provides important context you'd want in the feed output.

chorsley avatar Mar 14 '23 21:03 chorsley

Whacked in a PR to add this functionality as a kwarg boolean: https://github.com/MISP/PyMISP/pull/952

UFOSmuggler avatar Mar 15 '23 02:03 UFOSmuggler

PR merged, thanks!

Rafiot avatar Mar 15 '23 09:03 Rafiot