Configuring Notifications
Use the Events and Notifications services to send notifications, whenever Cloud Guard detects a problem for which you want to be notified.
If you are processing problems entirely within Cloud Guard, you do not need to configure notifications.
Cloud Guard provides a notification responder, Cloud Event, that can emit problem details to the Events service. The Cloud Event responder rule is part of the Responder recipe, which needs to be attached to a corresponding target or targets. The Cloud Event rule is enabled by default. The Cloud Event responder does not require other IAM policies and is configured to execute automatically.
Emitting from Cloud Event to the Events service allows for integration with the Notifications service, which can push notifications to:
- Slack
- Oracle Cloud Infrastructure Functions
To set up notifications through email or Slack, continue with Notifying through Email or Slack.
To use OCI Functions to relay notification information to another service, see Notifying through OCI Functions.
Cloud Guard Events
Notifications can be sent for any of these event types in Cloud Guard.
You must set up Events and Notifications from your Cloud Guard Reporting Region, which aggregates problems from the monitored regions and sends out the Cloud Event from the Reporting Region.
To receive notifications when a responder recipe is triggered, you must perform the following tasks (for details, see Notifying through Email or Slack or Notifying through OCI Functions):
- In Cloud Guard, ensure that the Cloud Event rule is enabled for the responder recipe.
- For email or Slack notifications, in the Notification service, create a Topic and a Subscription to that topic.
- For OCI Functions, create the function code to call and place the function application in the compartment from which it's to be called.
- In the Events service, configure a rule that specifies the Action to take.
Cloud Guard Event Types
These are the event types that Cloud Guard emits:
Friendly Name | Trigger | Event Type |
---|---|---|
Cloud Guard - Announcements | Cloud Guard announces a new feature |
|
Cloud Guard - Status | Cloud Guard's status (enabled/disabled) changes |
|
The following table summarizes the actions, status, and reasons for Cloud Guard event types.
Event Type | Action Leading to Event | Status Field in Event Details | Reason Field in Event Details |
---|---|---|---|
Cloud Guard - Announcements | Cloud Guard announces a new feature | Not applicable | Varies with announcement - example: New Detector Rule added by Cloud Guard |
Cloud Guard - Status | User (actor ) disabled Cloud Guard |
CLOUDGUARD_DISABLED |
Cloud Guard is disabled |
Problem Event Types
These are the event types that problems emit:
Friendly Name | Trigger | Event Type |
---|---|---|
Detected - Problem | Cloud Guard detects a problem |
|
Dismissed - Problem | A user dismisses a problem |
|
Problem Threshold Reached | Certain threshold limits are reached, because of excessive audit signals from services such as VCN or Identity. |
|
Remediated-Problem | A responder configured to automatically remediate a detected problem performs the remediation. |
|
The following table details the different actions, status, and reasons for the Remediated - Problem event type.
Event Type | Action Leading to Event | Status Field in Event Details | Reason Field in Event Details |
---|---|---|---|
Remediated - Problem | User Marked the problem as Resolved | RESOLVED |
Problem marked as RESOLVED by <User OCID> |
Remediated - Problem | Problem Dismissed | RESOLVED |
Problem marked as DISMISSED by <User> |
Remediated - Problem | Problem Auto Resolved | RESOLVED |
Problem is auto resolved by CloudGuard |
Remediated - Problem | User does manual problem remediation / Responder Rules configured for Automatic Remediation | RESOLVED |
Problem remediated by CloudGuard |
Detected - Problem Example
This is a reference event for detected problems:
{
"eventType" : "com.oraclecloud.cloudguard.problemdetected",
"cloudEventsVersion" : "0.1",
"eventTypeVersion" : "2.0",
"source" : "CloudGuardResponderEngine",
"eventTime" : "2020-09-02T18:45:39Z",
"contentType" : "application/json",
"data" : {
"compartmentId" : "ocid1.compartment.oc1..<unique_ID>",
"compartmentName" : "compartment_name",
"resourceName" : "problem_name",
"resourceId" : "ocid1.cloudguardproblem.oc1.iad.<unique_ID>",
"additionalDetails" : {
"tenantId" : "ocid1.tenancy.oc1...<unique_ID>",
"problemDescription" : "problem_description",
"riskLevel" : "LOW",
"problemRecommendation" : "example_recommendation",
"status" : "OPEN",
"problemType" : "problem_type",
"resourceName" : "resource_name",
"resourceId" : "ocid1.vcn.oc1.iad.<unique_ID>",
"resourceType" : "resource_type",
"targetId" : "ocid1.cloudguardtarget.oc1..<unique_ID>",
"labels" : "label1, label2",
"firstDetected" : "2020-09-02T18:44:44.568Z",
"lastDetected" : "2020-09-02T18:44:44.568Z",
"region" : "us-ashburn-1"
}
},
"eventID" : "<unique_ID>",
"extensions" : {
"compartmentId" : "ocid1.compartment.oc1..<unique_ID>"
}
}
Remediated-Problem Example
This is a reference event for remediated problems:
{
"eventType" : "com.oraclecloud.cloudguard.problemremediated",
"cloudEventsVersion" : "0.1",
"eventTypeVersion" : "2.0",
"source" : "CloudGuardResponderEngine",
"eventTime" : "2020-09-02T18:47:00Z",
"contentType" : "application/json",
"data" : {
"compartmentId" : "ocid1.compartment.oc1..<unique_ID>",
"compartmentName" : "compartment_name",
"resourceName" : "problem_name",
"resourceId" : "ocid1.cloudguardproblem.oc1.iad.<unique_ID>",
"additionalDetails" : {
"tenantId" : "ocid1.tenancy.oc1...<unique_ID>",
"problemDescription" : "problem_description",
"riskLevel" : "CRITICAL",
"problemRecommendation" : "example_recommendation",
"status" : "RESOLVED",
"problemType" : "problem_type",
"resourceName" : "resource_name",
"resourceId" : "ocid1.vcn.oc1.iad.<unique_ID>",
"resourceType" : "resource_type",
"targetId" : "ocid1.cloudguardtarget.oc1..<unique_ID>",
"labels" : "label1, label2",
"firstDetected" : "2020-09-02T18:44:44.145Z",
"lastDetected" : "2020-09-02T18:44:44.145Z",
"region" : "us-ashburn-1",
"responderRuleId" : "responder_rule_id"
}
},
"eventID" : "<unique_ID>",
"extensions" : {
"compartmentId" : "ocid1.compartment.oc1..<unique_ID>"
}
}
Notifying through Email or Slack
Use the Events and Notifications services to send notifications through email or Slack, whenever Cloud Guard detects a problem for which you want to be notified.
To add notifications for more than one event type, perform all the following steps for the first notification, then repeat steps 3 and 4 for each additional notification.
Notifying through OCI Functions
Use the Events and Notifications services to send notifications through Oracle Cloud Infrastructure Functions, wheneverCloud Guard detects a problem for which you want to be notified.