Attempt to Unload Elastic Endpoint Security Kernel Extension

Identifies attempts to unload the Elastic Endpoint Security kernel extension via the kextunload command.

Elastic rule (View on GitHub)

 1[metadata]
 2creation_date = "2020/01/05"
 3integration = ["endpoint"]
 4maturity = "production"
 5min_stack_comments = "New fields added: required_fields, related_integrations, setup"
 6min_stack_version = "8.3.0"
 7updated_date = "2023/11/15"
 8
 9[rule]
10author = ["Elastic"]
11description = "Identifies attempts to unload the Elastic Endpoint Security kernel extension via the kextunload command."
12from = "now-9m"
13index = ["logs-endpoint.events.*"]
14language = "kuery"
15license = "Elastic License v2"
16name = "Attempt to Unload Elastic Endpoint Security Kernel Extension"
17risk_score = 73
18rule_id = "70fa1af4-27fd-4f26-bd03-50b6af6b9e24"
19setup = """## Setup
20
21This rule requires data coming in from Elastic Defend.
22
23### Elastic Defend Integration Setup
24Elastic Defend is integrated into the Elastic Agent using Fleet. Upon configuration, the integration allows the Elastic Agent to monitor events on your host and send data to the Elastic Security app.
25
26#### Prerequisite Requirements:
27- Fleet is required for Elastic Defend.
28- To configure Fleet Server refer to the [documentation](https://www.elastic.co/guide/en/fleet/current/fleet-server.html).
29
30#### The following steps should be executed in order to add the Elastic Defend integration on a macOS System:
31- Go to the Kibana home page and click "Add integrations".
32- In the query bar, search for "Elastic Defend" and select the integration to see more details about it.
33- Click "Add Elastic Defend".
34- Configure the integration name and optionally add a description.
35- Select the type of environment you want to protect, for MacOS it is recommended to select "Traditional Endpoints".
36- Select a configuration preset. Each preset comes with different default settings for Elastic Agent, you can further customize these later by configuring the Elastic Defend integration policy. [Helper guide](https://www.elastic.co/guide/en/security/current/configure-endpoint-integration-policy.html).
37- We suggest selecting "Complete EDR (Endpoint Detection and Response)" as a configuration setting, that provides "All events; all preventions"
38- Enter a name for the agent policy in "New agent policy name". If other agent policies already exist, you can click the "Existing hosts" tab and select an existing policy instead.
39For more details on Elastic Agent configuration settings, refer to the [helper guide](https://www.elastic.co/guide/en/fleet/current/agent-policy.html).
40- Click "Save and Continue".
41- To complete the integration, select "Add Elastic Agent to your hosts" and continue to the next section to install the Elastic Agent on your hosts.
42For more details on Elastic Defend refer to the [helper guide](https://www.elastic.co/guide/en/security/current/install-endpoint.html).
43"""
44severity = "high"
45tags = ["Domain: Endpoint", "OS: macOS", "Use Case: Threat Detection", "Tactic: Defense Evasion", "Data Source: Elastic Defend"]
46timestamp_override = "event.ingested"
47type = "query"
48
49query = '''
50event.category:process and host.os.type:macos and event.type:(start or process_started) and
51 process.name:kextunload and process.args:("/System/Library/Extensions/EndpointSecurity.kext" or "EndpointSecurity.kext")
52'''
53
54
55[[rule.threat]]
56framework = "MITRE ATT&CK"
57[[rule.threat.technique]]
58id = "T1562"
59name = "Impair Defenses"
60reference = "https://attack.mitre.org/techniques/T1562/"
61[[rule.threat.technique.subtechnique]]
62id = "T1562.001"
63name = "Disable or Modify Tools"
64reference = "https://attack.mitre.org/techniques/T1562/001/"
65
66
67
68[rule.threat.tactic]
69id = "TA0005"
70name = "Defense Evasion"
71reference = "https://attack.mitre.org/tactics/TA0005/"
72[[rule.threat]]
73framework = "MITRE ATT&CK"
74[[rule.threat.technique]]
75id = "T1547"
76name = "Boot or Logon Autostart Execution"
77reference = "https://attack.mitre.org/techniques/T1547/"
78[[rule.threat.technique.subtechnique]]
79id = "T1547.006"
80name = "Kernel Modules and Extensions"
81reference = "https://attack.mitre.org/techniques/T1547/006/"
82
83
84
85[rule.threat.tactic]
86id = "TA0003"
87name = "Persistence"
88reference = "https://attack.mitre.org/tactics/TA0003/"

Related rules

to-top