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 integration alert link generated incorrectly #1378

Closed
patriziotufarolo opened this issue May 29, 2020 · 1 comment
Closed

[Bug] MISP integration alert link generated incorrectly #1378

patriziotufarolo opened this issue May 29, 2020 · 1 comment
Assignees
Labels
bug TheHive4 TheHive4 related issues
Milestone

Comments

@patriziotufarolo
Copy link

Request Type

Bug

Work Environment

Question Answer
OS version (server) Red Hat
OS version (client) N/A
TheHive version / git hash 4.0.3 RC-3
Package Type RPM
Browser type & version N/A

Problem Description

When you receive an event from MISP integration and an alert is created on The Hive 4, the link to the MISP instance is generated incorrectly: looking at
frontend/app/views/partials/alert/list.html
it seems that it takes $vm.urls[event.source] that previously (eg. TH-3) was used to identify the MISP instance from which the event was coming from, now represents the source organization. Therefore $vm.urls[event.source] is not resolved and remains empty, so the url becomes relative on Hive instance's URL.

Steps to Reproduce

  1. Install The Hive 4
  2. Install MISP and generate API key
  3. Configure MISP integration
    {
      name = "misp"
      url = "https://misp"
      auth {
        type = key
        key = "[API_KEY_HERE]"
      }
      ws {
        ssl.trustManager.stores = [ {
        path = "ks.jks"
        } ]
      }
      whitelist.tags = ["cti:info_flow_dst=\"thehive\""]
      includedTheHiveOrganisations = ["mytestorg"]
    }
  1. Receive some alerts
  2. Click on the arrow icon that brings to MISP
    It will redirect you to http:///events/
    rather than http:///events/

Possible Solutions

Workaround
I named the MISP integration in application.conf at the same way of my organization. in this way I tricked the array Lookup in the Hive. Of course in a multi-org setup this is not feasible, so we need to fix it :)
Solution
Use the right property as array key when loading MISP instance's address

@patriziotufarolo patriziotufarolo added TheHive4 TheHive4 related issues bug labels May 29, 2020
@To-om To-om added this to the 4.0.0-RC4 milestone May 29, 2020
@nadouani
Copy link
Contributor

In TheHive 4 we added a field called externalLink to the alert object, allowing any alert to have its own external link, not only MISP alerts. We will rely on this field.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug TheHive4 TheHive4 related issues
Projects
None yet
Development

No branches or pull requests

3 participants