More Info:
Ensure Event Rules capture IAM Group creation, updates, and deletions. Real-time event triggers for group mutation enable automated remediation pipelines to revert unauthorized privilege grants.Risk Level
MediumAddress
Compliance, SecurityCompliance Standards
- APRA CPS 234 (Australia)
- AWS Well Architected Framework
- BSI C5 (Germany)
- Brazil LGPD
- CCPA / CPRA (California)
- CIS AWS
- CIS Critical Security Controls v8
- CMMC 2.0
- CSA Cloud Controls Matrix v4
- Cloudanix Best Practice
- DPDPA
- Digital Operational Resilience Act (EU)
- Essential 8
- HIPAA
- HITRUST CSF
- ISO 27001
- ISO/IEC 27017
- ISO/IEC 27018
- ISO/IEC 27701
- KSA PDPL
- MAS Technology Risk Management (Singapore)
- MITRE ATT&CK (Cloud)
- NIS2 Directive
- NIST CSF
- NIST SP 800-171
- NYDFS 23 NYCRR 500
- PCI
- SOC2
- SWIFT Customer Security Controls Framework
- Sarbanes-Oxley IT General Controls
- UK NCSC Cyber Assessment Framework
Triage and Remediation
- Remediation
Remediation
Using Console
Using Console
Below are the exact steps in the OCI Console to set up an Event Rule that alerts on IAM group changes (via Notifications / “alerting monitoring”).
This setup provides “alerting monitoring” for OCI IAM Group changes entirely via the OCI Console, using Events + Notifications.
1. Prepare a Notifications Topic (for alerts)
- In the OCI Console, open the Navigation Menu.
- Go to Developer Services → Notifications → Topics.
- Click Create Topic.
- Name:
iam-group-changes-topic(or similar) - Description:
Alerts on IAM group changes - Click Create.
- Name:
- Open the topic you just created.
- Under Subscriptions, click Create Subscription.
- Protocol: typically Email (or HTTPS/Slack/PagerDuty as needed)
- Email: your alert email
- Click Create.
- Confirm the subscription from the email you received.
2. Create an Event Rule for IAM Group Changes
- Open Navigation Menu → Observability & Management → Events Service → Rules.
- Make sure you are in the correct compartment where you want the rule to live.
- Click Create Rule.
-
Fill in:
- Display name:
iam-group-change-rule - Description:
Triggers on IAM group create/update/delete and membership changes - Rule Conditions:
- Condition Type: Event Type
- Rule is matching: Any of the following.
- Display name:
-
Under Condition, configure events for IAM groups. Depending on your tenancy (IDCS vs IAM/Identity Domains) you will see variants, but generally:
- Service Name / Event Source:
Identity - Then add event types such as (names may vary slightly by console version):
Group - CreateGroup - UpdateGroup - DeleteGroup Membership - Add UserGroup Membership - Remove User
Use the console’s event type picker where possible; only use JSON if you can’t find the specific types in the UI. - Service Name / Event Source:
-
Under Actions, click Add Action:
- Action Type: Notifications
- Topic: select the topic you created earlier (e.g.,
iam-group-changes-topic). - Optionally set:
- Action Name:
SendNotificationOnIAMGroupChange.
- Action Name:
- Click Create Rule (and ensure the rule is in Enabled state).
3. (Optional) Test the Configuration
- Make a safe IAM group change (e.g., create a test group or add/remove a test user to a test group).
- Confirm you receive an email (or chosen channel) alert from the Notifications topic.
This setup provides “alerting monitoring” for OCI IAM Group changes entirely via the OCI Console, using Events + Notifications.
Using CLI
Using CLI
Below is a simple end‑to‑end remediation using OCI CLI so that any IAM Group change triggers an event rule and sends an alert (e.g., email).
Capture the
Then go to your email inbox and confirm the subscription.
This matches all major IAM group change events.
Replace
This creates an Events rule in the specified compartment. Any matching IAM group event will be sent to the Notification topic, which then sends email to your subscription.
Trigger a test by creating/updating a group in the Console or via CLI (e.g., change a group description), then confirm you receive an email.
These steps implement “OCI Monitoring/Alerting for IAM Group Changes” fully via OCI CLI using Events + Notifications.
1. Prerequisites
Make sure:- OCI CLI is installed and configured (
oci setup config). - You have:
COMPARTMENT_OCIDwhere you’ll create the rule and topic (often root compartment / tenancy).- An email address (for the notification subscription).
2. Create a Notifications Topic
topic-id from the output, or:3. Create an Email Subscription to the Topic
4. Define the Event Rule Condition (IAM Group Changes)
Create a JSON fileiam-group-events-condition.json:5. Define the Event Rule Actions (Send to Notifications)
Create a JSON fileiam-group-events-actions.json:<TOPIC_OCID_PLACEHOLDER> with your real $TOPIC_OCID, or generate the file with sed:6. Create the Event Rule via OCI CLI
7. (Optional) Verify the Rule
List rules:These steps implement “OCI Monitoring/Alerting for IAM Group Changes” fully via OCI CLI using Events + Notifications.
Using Python
Using Python
Below is a minimal, step‑by‑step way to:
If you create the topic in another compartment, adjust policy scope accordingly.
Add a subscription (e.g., email):Confirm the subscription from your email.
This rule will:
If you share your tenancy region and whether you use IAM domains, I can adjust the exact
- Detect IAM Group changes using OCI Events
- Send alerts via OCI Notifications (which is what Monitoring “Alerting” uses for delivery)
- Do it programmatically with Python (OCI SDK)
1. Prerequisites
- OCI Python SDK installed
-
Config file (
~/.oci/config) with a profile, e.g.DEFAULT - IAM policies (in the tenancy root or relevant compartment):
2. Create a Notifications Topic (for alerts)
3. Create an Events Rule for IAM Group Changes
OCI IAM group events (non‑exhaustive) typically look like:com.oraclecloud.identitycontrolplane.creategroupcom.oraclecloud.identitycontrolplane.updategroupcom.oraclecloud.identitycontrolplane.deletegroupcom.oraclecloud.identitycontrolplane.adduserstogroupcom.oraclecloud.identitycontrolplane.removeusersfromgroup
- Listen for any of the IAM group change events in the tenancy/compartment scope
- Push a message to the Notifications topic you created
- Notifications will then send email (or other channels you configure)
4. (Optional) Tie in Monitoring Alarms
If you specifically want Monitoring Alarm objects to send alerts (rather than directly from Events):- You still use the Notifications topic for alarm delivery.
- You create a custom metric and a Monitoring Alarm on that metric.
- Your Events Rule target would be a Function or Streaming that increments a custom metric, and then the alarm fires.
If you share your tenancy region and whether you use IAM domains, I can adjust the exact
eventType values and pattern for your environment.Using Terraform
Using Terraform
oci_events_rule by renaming/importing. After updating Terraform, terraform plan should show one new oci_events_rule (and oci_ons_notification_topic if added) being created with the condition listing the three IAM group event types.
