fix: [stix2 import] Fixed STIX2 parser name

pull/9440/head
Christian Studer 2023-12-12 11:34:05 +01:00
parent 6cdfa7b5f7
commit c5baab3328
No known key found for this signature in database
GPG Key ID: 6BBED1B63A6D639F
1 changed files with 1 additions and 1 deletions

View File

@ -67,7 +67,7 @@ def _process_stix_file(args: argparse.ArgumentParser):
)
stix_version = getattr(bundle, 'version', '2.1')
to_call, arguments = _get_stix_parser(_from_misp(bundle.objects), args)
parser = globals()[f'{to_call}STIX2toMISPParser'](**arguments)
parser = globals()[to_call](**arguments)
parser.load_stix_bundle(bundle)
parser.parse_stix_bundle()
with open(f'{args.input}.out', 'wt', encoding='utf-8') as f: