InQuest / ThreatIngestor

Extract and aggregate threat intelligence.
https://inquest.readthedocs.io/projects/threatingestor/
GNU General Public License v2.0
821 stars 135 forks source link

misp operator: "missing 2 required positional arguments: 'url' and 'key'" #106

Closed ohmbra91 closed 1 year ago

ohmbra91 commented 3 years ago

When executing threatingestor I am encountering the below error:

2021-02-09 10:56:53.674 | ERROR    | threatingestor:__init__:89 - Error initializing plugins
Traceback (most recent call last):

  File "/home/misp/misp_space/bin/threatingestor", line 8, in <module>
    sys.exit(main())
    │   │    └ <function main at 0x7f398d61c4d0>
    │   └ <built-in function exit>
    └ <module 'sys' (built-in)>
  File "/home/misp/misp_space/lib/python3.7/site-packages/threatingestor/__init__.py", line 190, in main
    app = Ingestor(sys.argv[1])
          │        │   └ ['/home/misp/misp_space/bin/threatingestor', 'config.yml']
          │        └ <module 'sys' (built-in)>
          └ <class 'threatingestor.Ingestor'>
> File "/home/misp/misp_space/lib/python3.7/site-packages/threatingestor/__init__.py", line 82, in __init__
    for name, operator, kwargs in self.config.operators()}
                                  │    │      └ <function Config.operators at 0x7f398d6170e0>
                                  │    └ <threatingestor.config.Config object at 0x7f3991609110>
                                  └ <threatingestor.Ingestor object at 0x7f39915b0e10>
  File "/home/misp/misp_space/lib/python3.7/site-packages/threatingestor/__init__.py", line 82, in <dictcomp>
    for name, operator, kwargs in self.config.operators()}
        │     │         └ {}
        │     └ <class 'threatingestor.operators.misp.Plugin'>
        └ 'misp-instance'

TypeError: __init__() missing 2 required positional arguments: 'url' and 'key'
battleoverflow commented 1 year ago

Hi, @ohmbra91!

I wanted to check-in before closing this issue, just in case you would like to try again in the future.

Based on the error message being returned, you most likely need to include the following (specifically the key and url sections) in your config.yml file:

credentials:
  - name: misp-auth
    url: http://mymisp
    key: MYKEY
    ssl: false

If this is not the issue, please share your config.yml file in a new issue.

Do note this will require an already existing MISP instance for the generated artifacts. If you need any help, we do have documentation specific to the MISP operator here as well as other sources and operators.