mirror of https://github.com/MISP/MISP
fix: [stix2 import] Setting the `single_event` argument to avoid skipping content in case of multiple reports or groupings
parent
e29924b55d
commit
9573c308e0
|
@ -60,7 +60,7 @@ def _process_stix_file(args: argparse.Namespace):
|
|||
arguments['sharing_group_id'] = args.sharing_group_id
|
||||
parser = globals()[f'{to_call}STIX2toMISPParser'](**arguments)
|
||||
parser.load_stix_bundle(bundle)
|
||||
parser.parse_stix_bundle()
|
||||
parser.parse_stix_bundle(single_event=True)
|
||||
with open(f'{args.input}.out', 'wt', encoding='utf-8') as f:
|
||||
f.write(parser.misp_event.to_json())
|
||||
print(
|
||||
|
@ -122,4 +122,4 @@ if __name__ == '__main__':
|
|||
)
|
||||
sys.exit(1)
|
||||
|
||||
_process_stix_file(args)
|
||||
_process_stix_file(args)
|
||||
|
|
Loading…
Reference in New Issue