Duo User Auth Denied For Anomalous Push


Description

A Duo authentication was denied due to an anomalous 2FA push.

Query · python

def rule(event):
    return event.get("reason") == "anomalous_push" and event.get("result") == "denied"


def title(event):
    user = event.deep_get("user", "name", default="Unknown")
    return f"Duo Auth denied due to an anomalous 2FA push for [{user}]"


def alert_context(event):
    return {
        "factor": event.get("factor"),
        "reason": event.get("reason"),
        "user": event.deep_get("user", "name", default=""),
        "os": event.deep_get("access_device", "os", default=""),
        "ip_access": event.deep_get("access_device", "ip", default=""),
        "ip_auth": event.deep_get("auth_device", "ip", default=""),
        "application": event.deep_get("application", "name", default=""),
    }

Analyst notes

Follow up with the user to confirm they intended several pushes in quick succession.

Raw source Duo User Auth Denied For Anomalous Push · Panther Python
Esc
Published by panther-labs/panther-analysis ↗, licensed under Apache 2.0 ↗. Reproduced here unmodified.
AnalysisType: rule
Filename: duo_user_anomalous_push.py
RuleID: "DUO.User.Denied.AnomalousPush"
DisplayName: "Duo User Auth Denied For Anomalous Push"
Enabled: true
DedupPeriodMinutes: 15
LogTypes:
  - Duo.Authentication
Tags:
  - Duo
Severity: Medium
Description: >
  A Duo authentication was denied due to an anomalous 2FA push.
Reference: https://duo.com/docs/adminapi#authentication-logs
Runbook: Follow up with the user to confirm they intended several pushes in quick succession.
Tests:
  - Name: anomalous_push_occurred
    ExpectedResult: true
    Log:
      {
        "access_device": { "ip": "12.12.112.25", "os": "Mac OS X" },
        "auth_device": { "ip": "12.12.12.12" },
        "application": { "key": "D12345", "name": "Slack" },
        "event_type": "authentication",
        "factor": "duo_push",
        "reason": "anomalous_push",
        "result": "denied",
        "user": { "name": "example@example.io" },
      }
  - Name: good_auth
    ExpectedResult: false
    Log:
      {
        "access_device": { "ip": "12.12.112.25", "os": "Mac OS X" },
        "auth_device": { "ip": "12.12.12.12" },
        "application": { "key": "D12345", "name": "Slack" },
        "event_type": "authentication",
        "factor": "duo_push",
        "reason": "user_approved",
        "result": "success",
        "user": { "name": "example@example.io" },
      }
  - Name: denied_old_creds
    ExpectedResult: false
    Log:
      {
        "access_device": { "ip": "12.12.112.25", "os": "Mac OS X" },
        "auth_device": { "ip": "12.12.12.12" },
        "application": { "key": "D12345", "name": "Slack" },
        "event_type": "authentication",
        "factor": "duo_push",
        "reason": "out_of_date",
        "result": "denied",
        "user": { "name": "example@example.io" },
      }


# ------ paired body: duo_user_anomalous_push.py ------

def rule(event):
    return event.get("reason") == "anomalous_push" and event.get("result") == "denied"


def title(event):
    user = event.deep_get("user", "name", default="Unknown")
    return f"Duo Auth denied due to an anomalous 2FA push for [{user}]"


def alert_context(event):
    return {
        "factor": event.get("factor"),
        "reason": event.get("reason"),
        "user": event.deep_get("user", "name", default=""),
        "os": event.deep_get("access_device", "os", default=""),
        "ip_access": event.deep_get("access_device", "ip", default=""),
        "ip_auth": event.deep_get("auth_device", "ip", default=""),
        "application": event.deep_get("application", "name", default=""),
    }

Detection rules belong to the projects that publish them and remain under their own licenses. This site indexes and links to them; it claims no rights in them.