More Info:
Flag password reset requests originating from known threat-actor IP addresses or Tor exit nodes. This usually indicates an active account takeover sequence.Risk Level
CriticalAddress
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
- 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
- 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 practical, console-based steps to create an alarm/alert when a password reset occurs from a malicious IP in OCI. Because this specific condition comes from security/audit events rather than a native metric, you do it via Cloud Guard + Notifications, which is Oracle’s recommended way to alert on “malicious IP” identity activity.
If you need this strictly as a Monitoring Alarms object (under
1. Prerequisites
-
Permissions
- Your user/group must have IAM policies to:
- Use Cloud Guard
- Manage Notifications
- Read tenancy audit logs (usually included in Cloud Guard permissions)
- Your user/group must have IAM policies to:
-
Region
- Do all steps in the same region where you want alerts, especially for Notifications topics.
2. Enable and Configure Cloud Guard
- In the OCI Console, open the menu (☰) → Identity & Security → Cloud Guard.
-
If Cloud Guard is not enabled:
- Click Enable Cloud Guard.
- Choose:
- Reporting region.
- Configuration: usually
Default configurationis fine, or choose your existing one.
- Click Enable.
-
Confirm the Detector Recipe that looks for malicious IP sign-ins is enabled:
- Under Cloud Guard, go to Detector Recipes.
- Locate the recipe you’re using (often
OCI Cloud Guard Managed – Activity Detector Recipeor similar). - Click it → under Detector Rules, search for rules such as:
Signin from Malicious IP Address- Or any rule description mentioning malicious IP or suspicious sign-in.
- For that rule:
- Ensure its Status is
Enabled. - Make sure the Target scope (compartments/tenancy) includes your IAM users.
- Ensure its Status is
3. Create a Notifications Topic and Subscription
You’ll use OCI Notifications for alerts.- Menu → Application Integration → Notifications.
-
Click Create Topic.
- Name:
malicious-ip-password-reset-topic - Description:
Alerts for password reset / sign-in events from malicious IPs - Choose the appropriate compartment.
- Click Create.
- Name:
-
Add a Subscription:
- Inside the topic, click Create Subscription.
- Protocol:
Email(orSlack,PagerDuty,HTTPS, etc., as needed). - Email: enter the address for security/ops.
- Click Create.
- Confirm the subscription via the email you receive.
4. Connect Cloud Guard Problems to Notifications
You now tie Cloud Guard security problems (including malicious IP identity events) to that topic.- Go back to Cloud Guard → Configuration (or Targets, depending on UI version).
- Open your Target (often
Root Compartment Targetor your specific compartment target). - Under Target Details, locate the Notifications or Responder Settings section:
- Look for “Notifications for Problems” or similar wording.
- Configure:
- Severity: choose which severities to send (e.g.,
HighandCriticalorAll). - Notification Topic: select the topic you created:
malicious-ip-password-reset-topic.
- Severity: choose which severities to send (e.g.,
- Save/Update the target configuration.
5. (Optional) Narrow Notifications to Malicious IP Password Resets Only
If you want only malicious IP password reset–type events, you can:- In Cloud Guard → Problems, open a problem that corresponds to a malicious IP sign-in/password reset.
- Review:
- Detector Rule Name
- Problem Type / Labels
- Instead of globally notifying on all Problems, you can:
- Use a SIEM or ticketing integration downstream (e.g., Splunk, QRadar) to filter only those with the specific detector rule name or problem type.
- Or configure separate topics per severity / rule, and subscribe different teams accordingly.
6. Validate the Setup
- In Cloud Guard, use Simulate (if available) or temporarily trigger a test condition (e.g., from a test environment or using known-bad IP lists / IP reputation testing).
- Confirm:
- A Problem appears in Cloud Guard.
- An email/notification is sent to your configured subscription with the malicious IP and event details.
If you need this strictly as a Monitoring Alarms object (under
Observability & Management → Alarms) instead of Cloud Guard-driven Problems, say so and I’ll outline how to pipe Audit events to metrics via Service Connector + Logging, then build a metric-based alarm on those events.Using CLI
Using CLI
Below is how you can configure a “Malicious IP Password Reset” alarm in OCI Monitoring using the OCI CLI. Since the exact metric name/dimensions can differ between tenants and setups, I’ll show you:
If you know you are using a specific namespace (e.g., Look in the output for a metric whose name/dimensions clearly indicate password resets from malicious IPs. It might look something like:
Adjust as needed for your real metric name/dimensions and threshold:
Key flags:
Get full details:If needed, update:
If you can share the exact metric name/namespace you see for malicious password resets in your tenancy, I can give you the exact
- How to discover the metric
- How to build the alarm query
- How to create the alarm via CLI
1. Prerequisites
- OCI CLI installed and configured:
- Identify:
- Compartment OCID:
ocid1.compartment.oc1..xxxx - Notification Topic OCID (for email/SMS/etc.):
ocid1.onstopic.oc1..xxxx
- Compartment OCID:
2. Discover the Metric for “Malicious IP Password Reset”
First, list metrics for the relevant namespace. Security- or IAM-related metrics are often in namespaces likeoci_audit, oci_identity, or a custom namespace if you created custom metrics from logs.Example: list metrics in oci_audit for your compartment:security_events or a custom namespace), list there:- Namespace:
security_events - Metric name:
malicious_ip_password_reset - Dimensions (examples):
eventType="PASSWORD_RESET",threatType="MaliciousIP"
namespacename(metric name)- relevant
dimensions(e.g.threatType,eventType, etc.)
3. Build the Alarm Query
Assume you found:- Namespace:
security_events - Metric name:
malicious_ip_password_reset - Dimension:
threatType="MaliciousIP"
- Time window:
[5m],[15m], etc. - Aggregation:
.count(),.sum() - Condition:
>= 1,>= 5, etc.
4. Create the Alarm via OCI CLI
Useoci monitoring alarm create. Example (replace placeholders):--namespacemust match the metric namespace.--querymust use your exact metric name and dimensions.--destinations: list of Notification topic OCIDs.--pending-duration: how long the condition must hold before firing.--repeat-notification-interval: how often to re-notify while in alarm.
5. Verify the Alarm
List alarms:If you can share the exact metric name/namespace you see for malicious password resets in your tenancy, I can give you the exact
--query line to use.Using Python
Using Python
Below is one way to implement this using OCI Monitoring + Python:Goal:
Raise an OCI Monitoring Alarm when a password reset occurs from a known malicious IP, using Python.
Run this script every few minutes; it emits the metric
If you share how password-reset events and IPs appear in your Audit logs (a single example JSON), I can refine the filters and IP extraction to exactly match your tenancy.
Raise an OCI Monitoring Alarm when a password reset occurs from a known malicious IP, using Python.
1. Prerequisites
-
OCI SDK for Python installed:
-
Configured OCI credentials, e.g.
~/.oci/config: -
An OCI Notification topic (for the alarm to publish to):
- In Console: Developer Services → Notifications → Topics → Create Topic
- Note its OCID (e.g.
ocid1.onstopic.oc1....)
- Your Malicious IP list, e.g. a Python list or external file.
2. Overview of the Architecture
- Poll Audit Logs for password-reset events.
- Filter by client IP against your malicious IP list.
- For each malicious event, push a custom metric to OCI Monitoring.
- Create an Alarm on that custom metric that triggers a Notification.
3. Step 1 – Emit a Custom Metric When Malicious IP Detected
Assume:- Namespace:
security_metrics - Metric name:
malicious_password_reset - Compartment OCID:
COMPARTMENT_OCID - Region from config (
~/.oci/config)
3.1. Sample script to scan Audit logs and push metrics
This is a minimal example; in production you’d run this periodically (cron, OCI Functions, etc.).malicious_password_reset whenever it detects password resets from IPs in MALICIOUS_IPS.4. Step 2 – Create the Monitoring Alarm via Python
This alarm fires when any malicious event metric is emitted in the last 5 minutes.5. Validate
-
Generate a test event:
Temporarily add your own IP toMALICIOUS_IPS, perform a password reset, run the script, and confirm:- Metric appears in Monitoring → Metrics → security_metrics.
- Alarm transitions to FIRING.
- Notification is received (email, Slack, etc., depending on your subscription).
-
Adjust thresholds if you want alarms only on multiple events, e.g.:
If you share how password-reset events and IPs appear in your Audit logs (a single example JSON), I can refine the filters and IP extraction to exactly match your tenancy.
Using Terraform
Using Terraform
PasswordResetFromMaliciousIpCount with a dimension indicating malicious/Tor IPs, then attach an oci_monitoring_alarm like the one above to that metric.This change does not force replacement of other resources; terraform plan should show either creation of a new oci_monitoring_alarm.malicious_ip_password_reset or an in‑place update of its query (and any other changed arguments) only.
