Open Raven

The Open Raven Documentation Site

Welcome to the Open Raven Documentation Site. You'll find comprehensive guides and documentation to help you start working with Open Raven as quickly as possible, as well as support if you get stuck. Let's jump right in.

Guides    

AWS EventBridge

Open Raven's EventBridge integration allows you to send all of the asset and violation events that happen in Open Raven to AWS. Once these events are sent to Eventbridge, you can then process them in any supported AWS service, such as Lambda, SNS, or SQS.

Getting Started

To set up the EventBridge integration, you will need:

  • Permission to create and modify Eventbridge event buses and event rules in AWS.
  • Permission to create IAM policies and roles in AWS.
  • An AWS resource that is configured to receive events from Eventbridge.
  • Familiarity with how AWS IAM Roles work and are created.

Setting Up Event Bus

First, you need to set up an event bus to publish to. This event bus will be used to route all of the events from Open Raven to other places in AWS.

Step 1: Log in to the AWS Console

Log in to the AWS Console. Make sure you are in the region you intend to process the events from Open Raven.

Step 2: Go to Eventbridge

Go to the Eventbridge service in your AWS Console.

Step 3: Choose Event Buses

Navigate to the "Event buses" section via left-hand navigation.

Step 4: Create Event Bus

Click the Create event bus button.

Step 5: Enter Event Bus Name

Create an event bus name. We will use openraven-event-bus as the event bus name for these instructions.

Leave the Resource-based policy section blank and click Create.

Setting Up Rules

Rules allow particular events to be sent from the event bus to an AWS service/resource.

Step 1: Click on Rules

From the Eventbridge service in the AWS Console, click on "Rules" in the left-hand navigation.

Step 2: Create Rule

Click the Create Rule button.

Step 3: Add Rule Name and Description

Give the Rule a meaningful name and description.

Step 4: Define Event Pattern

Choose the Event Pattern option, then choose the custom pattern option. The pattern to get all events is:

{"source": [{"prefix": ""}]}

Step 5: Save Event Pattern

Click Save. You will notice that doing so will result in the reformatting of the JSON string.

Step 6: Select Event Bus

Choose the Custom or partner event bus option. Then, select the event bus you created earlier from the dropdown menu.

Step 7: Select Targets

Select the target service and associated resource you intend to send the events to. In the example below, we are using an SQS Queue named openraven-sqs-queue.

Step 8: Add Tags

Add any tags as appropriate for your environment.

Step 9: Create Rule

Click Create to create Rule.

Setting Up The IAM Role

Open Raven assumes an IAM Role in your AWS account to publish events to EventBridge. Before you set up an IAM role for Open Raven, you will need to decide on an external ID that will be shared between Open Raven and AWS. We suggest a 64 character random string.

Please create an IAM Role with the following details:

Name

The name must start with ‘openraven-cross-account-’. We suggest ‘openraven-cross-account-eventbridge’.

Policy Document

Please replace:

  • AWS_REGION with the region you created for the event bus.
  • AWS_ACCOUNT with the account ID you created the bus in.
  • EVENT_BUS_NAME with the name of the event bus you created.
{
    "Version": "2012-10-17",
    "Statement": [
        {
            "Effect": "Allow",
            "Action": "events:PutEvents",
            "Resource": "arn:aws:events:AWS_REGION:AWS_ACCOUNT:event-bus/EVENT_BUS_NAME"
        }
    ]
}

Trust Policy

Next, set up the following trust policy, replacing EXTERNAL_ID with the external ID you decided to use.

{
  "Version": "2012-10-17",
  "Statement": [
    {
      "Effect": "Allow",
      "Principal": {
        "AWS": "arn:aws:iam::230888199284:root"
      },
      "Action": "sts:AssumeRole",
      "Condition": {
        "StringEquals": {
          "sts:ExternalId": "EXTERNAL_ID"
        }
      }
    }
  ]
}

Configuring Open Raven

Step 1: Log in to Open Raven

Log in to your Open Raven workspace.

Step 2: Click on the EventBridge Icon in "Integrations"

Go to "Configuration" and then "Integrations" in the left-hand navigation. Select the EventBridge icon.

Step 3: Fill in Eventbridge Configuration Details

Fill in the details about your configuration.

  • Target Event Bus Name is the name of the event bus you created earlier.
  • Target Event Bus Region is the region you created the event bus in.
  • Role ARN is the ARN for the role you created.
  • External ID is the ID you used when you created the role.

Step 4: Save the Configuration

Click Save.

Step 5: Go to Notifications and Enable Integration

Click Notifications.

Enable the notifications for EventBridge and then click Save Notification Settings. That's it. You have successfully set up the EventBridge integration.

Updated 6 months ago


What's Next

Slack

AWS EventBridge


Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.