Spike in Failed Logon Events

A machine learning job found an unusually large spike in authentication failure events. This can be due to password spraying, user enumeration or brute force activity and may be a precursor to account takeover or credentialed access.

Elastic rule (View on GitHub)

 1[metadata]
 2creation_date = "2021/06/10"
 3integration = ["auditd_manager", "endpoint", "system"]
 4maturity = "production"
 5updated_date = "2023/07/27"
 6min_stack_comments = "New fields added: required_fields, related_integrations, setup"
 7min_stack_version = "8.3.0"
 8
 9[rule]
10anomaly_threshold = 75
11author = ["Elastic"]
12description = """
13A machine learning job found an unusually large spike in authentication failure events. This can be due to password
14spraying, user enumeration or brute force activity and may be a precursor to account takeover or credentialed access.
15"""
16false_positives = [
17    """
18    A misconfigured service account can trigger this alert. A password change on an account used by an email client can
19    trigger this alert. Security test cycles that include brute force or password spraying activities may trigger this
20    alert.
21    """,
22]
23from = "now-30m"
24interval = "15m"
25license = "Elastic License v2"
26machine_learning_job_id = "auth_high_count_logon_fails"
27name = "Spike in Failed Logon Events"
28note = """## Triage and analysis
29
30### Investigating Spike in Failed Logon Events
31
32This rule uses a machine learning job to detect a substantial spike in failed authentication events. This could indicate attempts to enumerate users, password spraying, brute force, etc.
33
34#### Possible investigation steps
35
36- Identify the users involved and if the activity targets a specific user or a set of users.
37- Check if the authentication comes from different sources.
38- Investigate if the host where the failed authentication events occur is exposed to the internet.
39  - If the host is exposed to the internet, and the source of these attempts is external, the activity can be related to bot activity and possibly not directed at your organization.
40  - If the host is not exposed to the internet, investigate the hosts where the authentication attempts are coming from, as this can indicate that they are compromised and the attacker is trying to move laterally.
41- Investigate other alerts associated with the involved users and hosts during the past 48 hours.
42- Check whether the involved credentials are used in automation or scheduled tasks.
43- If this activity is suspicious, contact the account owner and confirm whether they are aware of it.
44- Investigate whether there are successful authentication events from the involved sources. This could indicate a successful brute force or password spraying attack.
45
46### False positive analysis
47
48- If the account is used in automation tasks, it is possible that they are using expired credentials, causing a spike in authentication failures.
49- Authentication failures can be related to permission issues.
50
51### Response and remediation
52
53- Initiate the incident response process based on the outcome of the triage.
54- Investigate credential exposure on systems compromised or used by the attacker to ensure all compromised accounts are identified. Reset passwords for these accounts and other potentially compromised credentials, such as email, business systems, and web services.
55- Assess whether the asset should be exposed to the internet, and take action to reduce your attack surface.
56  - If the asset needs to be exposed to the internet, restrict access to remote login services to specific IPs.
57- Using the incident response data, update logging and audit policies to improve the mean time to detect (MTTD) and the mean time to respond (MTTR).
58"""
59references = ["https://www.elastic.co/guide/en/security/current/prebuilt-ml-jobs.html"]
60risk_score = 21
61rule_id = "99dcf974-6587-4f65-9252-d866a3fdfd9c"
62severity = "low"
63tags = ["Use Case: Identity and Access Audit", "Use Case: Threat Detection", "Rule Type: ML", "Rule Type: Machine Learning", "Tactic: Credential Access", "Resources: Investigation Guide"]
64type = "machine_learning"
65
66[[rule.threat]]
67framework = "MITRE ATT&CK"
68[[rule.threat.technique]]
69id = "T1110"
70name = "Brute Force"
71reference = "https://attack.mitre.org/techniques/T1110/"
72
73
74[rule.threat.tactic]
75id = "TA0006"
76name = "Credential Access"
77reference = "https://attack.mitre.org/tactics/TA0006/"```

Triage and analysis

Investigating Spike in Failed Logon Events

This rule uses a machine learning job to detect a substantial spike in failed authentication events. This could indicate attempts to enumerate users, password spraying, brute force, etc.

Possible investigation steps

  • Identify the users involved and if the activity targets a specific user or a set of users.
  • Check if the authentication comes from different sources.
  • Investigate if the host where the failed authentication events occur is exposed to the internet.
    • If the host is exposed to the internet, and the source of these attempts is external, the activity can be related to bot activity and possibly not directed at your organization.
    • If the host is not exposed to the internet, investigate the hosts where the authentication attempts are coming from, as this can indicate that they are compromised and the attacker is trying to move laterally.
  • Investigate other alerts associated with the involved users and hosts during the past 48 hours.
  • Check whether the involved credentials are used in automation or scheduled tasks.
  • If this activity is suspicious, contact the account owner and confirm whether they are aware of it.
  • Investigate whether there are successful authentication events from the involved sources. This could indicate a successful brute force or password spraying attack.

False positive analysis

  • If the account is used in automation tasks, it is possible that they are using expired credentials, causing a spike in authentication failures.
  • Authentication failures can be related to permission issues.

Response and remediation

  • Initiate the incident response process based on the outcome of the triage.
  • Investigate credential exposure on systems compromised or used by the attacker to ensure all compromised accounts are identified. Reset passwords for these accounts and other potentially compromised credentials, such as email, business systems, and web services.
  • Assess whether the asset should be exposed to the internet, and take action to reduce your attack surface.
    • If the asset needs to be exposed to the internet, restrict access to remote login services to specific IPs.
  • Using the incident response data, update logging and audit policies to improve the mean time to detect (MTTD) and the mean time to respond (MTTR).

References

Related rules

to-top