User Added to Privileged Group

Identifies a user being added to a privileged group in Active Directory. Privileged accounts and groups in Active Directory are those to which powerful rights, privileges, and permissions are granted that allow them to perform nearly any action in Active Directory and on domain-joined systems.

Elastic rule (View on GitHub)

 1[metadata]
 2creation_date = "2021/01/09"
 3integration = ["system", "windows"]
 4maturity = "production"
 5min_stack_comments = "New fields added: required_fields, related_integrations, setup"
 6min_stack_version = "8.3.0"
 7updated_date = "2023/10/23"
 8
 9[rule]
10author = ["Elastic", "Skoetting"]
11description = """
12Identifies a user being added to a privileged group in Active Directory. Privileged accounts and groups in Active
13Directory are those to which powerful rights, privileges, and permissions are granted that allow them to perform nearly
14any action in Active Directory and on domain-joined systems.
15"""
16from = "now-9m"
17index = ["winlogbeat-*", "logs-system.*", "logs-windows.*"]
18language = "eql"
19license = "Elastic License v2"
20name = "User Added to Privileged Group"
21note = """## Triage and analysis
22
23### Investigating User Added to Privileged Group in Active Directory
24
25Privileged accounts and groups in Active Directory are those to which powerful rights, privileges, and permissions are granted that allow them to perform nearly any action in Active Directory and on domain-joined systems.
26
27Attackers can add users to privileged groups to maintain a level of access if their other privileged accounts are uncovered by the security team. This allows them to keep operating after the security team discovers abused accounts.
28
29This rule monitors events related to a user being added to a privileged group.
30
31#### Possible investigation steps
32
33- Identify the user account that performed the action and whether it should manage members of this group.
34- Contact the account owner and confirm whether they are aware of this activity.
35- Investigate other alerts associated with the user/host during the past 48 hours.
36
37### False positive analysis
38
39- This attack abuses a legitimate Active Directory mechanism, so it is important to determine whether the activity is legitimate, if the administrator is authorized to perform this operation, and if there is a need to grant the account this level of privilege.
40
41### Response and remediation
42
43- Initiate the incident response process based on the outcome of the triage.
44- If the admin is not aware of the operation, activate your Active Directory incident response plan.
45- If the user does not need the administrator privileges, remove the account from the privileged group.
46- Review the privileges of the administrator account that performed the action.
47- Determine the initial vector abused by the attacker and take action to prevent reinfection through the same vector.
48- 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).
49"""
50references = [
51    "https://docs.microsoft.com/en-us/windows-server/identity/ad-ds/plan/security-best-practices/appendix-b--privileged-accounts-and-groups-in-active-directory",
52]
53risk_score = 47
54rule_id = "5cd8e1f7-0050-4afc-b2df-904e40b2f5ae"
55setup = """## Setup
56
57If enabling an EQL rule on a non-elastic-agent index (such as beats) for versions <8.2,
58events will not define `event.ingested` and default fallback for EQL rules was not added until version 8.2.
59Hence for this rule to work effectively, users will need to add a custom ingest pipeline to populate
60`event.ingested` to @timestamp.
61For more details on adding a custom ingest pipeline refer - https://www.elastic.co/guide/en/fleet/current/data-streams-pipeline-tutorial.html
62"""
63severity = "medium"
64tags = ["Domain: Endpoint", "OS: Windows", "Use Case: Threat Detection", "Tactic: Persistence", "Resources: Investigation Guide", "Use Case: Active Directory Monitoring", "Data Source: Active Directory"]
65timestamp_override = "event.ingested"
66type = "eql"
67
68query = '''
69iam where winlog.api:"wineventlog" and event.action == "added-member-to-group" and
70  group.name : ("Admin*",
71                "Local Administrators",
72                "Domain Admins",
73                "Enterprise Admins",
74                "Backup Admins",
75                "Schema Admins",
76                "DnsAdmins",
77                "Exchange Organization Administrators")
78'''
79
80
81[[rule.threat]]
82framework = "MITRE ATT&CK"
83[[rule.threat.technique]]
84id = "T1098"
85name = "Account Manipulation"
86reference = "https://attack.mitre.org/techniques/T1098/"
87
88
89[rule.threat.tactic]
90id = "TA0003"
91name = "Persistence"
92reference = "https://attack.mitre.org/tactics/TA0003/"

Triage and analysis

Investigating User Added to Privileged Group in Active Directory

Privileged accounts and groups in Active Directory are those to which powerful rights, privileges, and permissions are granted that allow them to perform nearly any action in Active Directory and on domain-joined systems.

Attackers can add users to privileged groups to maintain a level of access if their other privileged accounts are uncovered by the security team. This allows them to keep operating after the security team discovers abused accounts.

This rule monitors events related to a user being added to a privileged group.

Possible investigation steps

  • Identify the user account that performed the action and whether it should manage members of this group.
  • Contact the account owner and confirm whether they are aware of this activity.
  • Investigate other alerts associated with the user/host during the past 48 hours.

False positive analysis

  • This attack abuses a legitimate Active Directory mechanism, so it is important to determine whether the activity is legitimate, if the administrator is authorized to perform this operation, and if there is a need to grant the account this level of privilege.

Response and remediation

  • Initiate the incident response process based on the outcome of the triage.
  • If the admin is not aware of the operation, activate your Active Directory incident response plan.
  • If the user does not need the administrator privileges, remove the account from the privileged group.
  • Review the privileges of the administrator account that performed the action.
  • Determine the initial vector abused by the attacker and take action to prevent reinfection through the same vector.
  • 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