Configure Webhooks

Configure Webhooks

Configure a global firewall quarantine webhook so Nexus Repository Firewall sends an HTTP notification to your endpoint when a component download is blocked or quarantined.

Prerequisites

The following prerequisites are necessary for enabling webhooks:

Create Webhook Capability

Take the following steps to configure webhooks:

  1. Log in to Nexus Repository Manager as an Administrator.
  2. Go to SettingsSystemCapabilities.
  3. Select Create capability button.
  4. In Select Type, choose Webhook: Global.
  5. In Event Types, select firewall_quarantine.
  6. In URL, enter the HTTP endpoint that receives webhook requests.

The endpoint can be any HTTP service that receives and processes the webhook payload. See the Webhook Payload to understand the JSON payload sent by Firewall and ensure that your receiving endpoint can process it. If the receiving endpoint expects a different request format, use an intermediary service to transform the payload before forwarding it.

  1. Optional: In Secret Key, enter the token for HMAC payload digest.
  2. Select Save.

Note

If you configure a secret, verify webhook signatures using the raw request body before you process the payload. Sonatype recommends using the secret key.