Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG][MISP] KeyError: 'external_id' #626

Closed
mwatermolen opened this issue Mar 8, 2022 · 1 comment
Closed

[BUG][MISP] KeyError: 'external_id' #626

mwatermolen opened this issue Mar 8, 2022 · 1 comment
Labels
bug use for describing something not working as expected solved use to identify issue that has been solved (must be linked to the solving PR)

Comments

@mwatermolen
Copy link
Contributor

Description

On MISP sync from the CIRCL EU Feed we receive KeyError: 'external_id'

Environment

  1. OS (where OpenCTI server runs): Ubuntu 20.04
  2. OpenCTI version: 5.2.0
  3. OpenCTI client: N/A
  4. Other environment details: Running on RKE kubernetes

Reproducible Steps

Steps to create the smallest reproducible scenario:

  1. Ingest MISP feed
  2. You would need the data causing this though - contact me and I can see if I can get access to the misp feed

Expected Output

Sync w/o errors

Actual Output

INFO:pika.channel:Closing channel (0): 'Normal shutdown' on <Channel number=1 OPEN conn=<SelectConnection OPEN transport=<pika.adapters.utils.io_services_utils._AsyncPlaintextTransport object at 0x7f35b06f0640> params=<ConnectionParameters host=opencti-5-1646404219-rabbitmq port=5672 virtual_host=/ ssl=False>>>
INFO:pika.channel:Received <Channel.CloseOk> on <Channel number=1 CLOSING conn=<SelectConnection OPEN transport=<pika.adapters.utils.io_services_utils._AsyncPlaintextTransport object at 0x7f35b06f0640> params=<ConnectionParameters host=opencti-5-1646404219-rabbitmq port=5672 virtual_host=/ ssl=False>>>
INFO:root:Processing event 5a9d518e-d610-4209-b609-08550acd0835
Traceback (most recent call last):
  File "/opt/opencti-connector-misp/misp.py", line 1697, in <module>
    mispConnector.run()
  File "/opt/opencti-connector-misp/misp.py", line 296, in run
    event_timestamp = self.process_events(work_id, events)
  File "/opt/opencti-connector-misp/misp.py", line 420, in process_events
    event_elements = self.prepare_elements(
  File "/opt/opencti-connector-misp/misp.py", line 1326, in prepare_elements
    "x_mitre_id": galaxy_entity["meta"]["external_id"][
KeyError: 'external_id'

Additional information

N/A

Screenshots (optional)

image
image

@mwatermolen mwatermolen changed the title [MISP] KeyError: 'external_id' [BUG][MISP] KeyError: 'external_id' Mar 8, 2022
@nor3th
Copy link
Contributor

nor3th commented Mar 11, 2022

Fixed

@nor3th nor3th closed this as completed Mar 11, 2022
@nor3th nor3th added bug use for describing something not working as expected solved use to identify issue that has been solved (must be linked to the solving PR) labels Mar 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug use for describing something not working as expected solved use to identify issue that has been solved (must be linked to the solving PR)
Projects
None yet
Development

No branches or pull requests

2 participants