-
Notifications
You must be signed in to change notification settings - Fork 191
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adding documents for v8.2.1 pre-built detection rules (#2378)
- Loading branch information
1 parent
693a249
commit 8ae8ad3
Showing
553 changed files
with
50,145 additions
and
3 deletions.
There are no files selected for viewing
94 changes: 94 additions & 0 deletions
94
...ackages/8-2-1/prebuilt-rule-8-2-1-access-of-stored-browser-credentials.asciidoc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
[[prebuilt-rule-8-2-1-access-of-stored-browser-credentials]] | ||
=== Access of Stored Browser Credentials | ||
|
||
Identifies the execution of a process with arguments pointing to known browser files that store passwords and cookies. Adversaries may acquire credentials from web browsers by reading files specific to the target browser. | ||
|
||
*Rule type*: eql | ||
|
||
*Rule indices*: | ||
|
||
* auditbeat-* | ||
* logs-endpoint.events.* | ||
|
||
*Severity*: high | ||
|
||
*Risk score*: 73 | ||
|
||
*Runs every*: 5m | ||
|
||
*Searches indices from*: now-9m ({ref}/common-options.html#date-math[Date Math format], see also <<rule-schedule, `Additional look-back time`>>) | ||
|
||
*Maximum alerts per execution*: 100 | ||
|
||
*References*: | ||
|
||
* https://securelist.com/calisto-trojan-for-macos/86543/ | ||
|
||
*Tags*: | ||
|
||
* Elastic | ||
* Host | ||
* macOS | ||
* Threat Detection | ||
* Credential Access | ||
|
||
*Version*: 4 | ||
|
||
*Rule authors*: | ||
|
||
* Elastic | ||
|
||
*Rule license*: Elastic License v2 | ||
|
||
|
||
==== Investigation guide | ||
|
||
|
||
[source, markdown] | ||
---------------------------------- | ||
---------------------------------- | ||
|
||
==== Rule query | ||
|
||
|
||
[source, js] | ||
---------------------------------- | ||
process where event.type in ("start", "process_started") and | ||
process.args : | ||
( | ||
"/Users/*/Library/Application Support/Google/Chrome/Default/Login Data", | ||
"/Users/*/Library/Application Support/Google/Chrome/Default/Cookies", | ||
"/Users/*/Library/Application Support/Google/Chrome/Profile*/Cookies", | ||
"/Users/*/Library/Cookies*", | ||
"/Users/*/Library/Application Support/Firefox/Profiles/*.default/cookies.sqlite", | ||
"/Users/*/Library/Application Support/Firefox/Profiles/*.default/key*.db", | ||
"/Users/*/Library/Application Support/Firefox/Profiles/*.default/logins.json", | ||
"Login Data", | ||
"Cookies.binarycookies", | ||
"key4.db", | ||
"key3.db", | ||
"logins.json", | ||
"cookies.sqlite" | ||
) | ||
---------------------------------- | ||
|
||
*Framework*: MITRE ATT&CK^TM^ | ||
|
||
* Tactic: | ||
** Name: Credential Access | ||
** ID: TA0006 | ||
** Reference URL: https://attack.mitre.org/tactics/TA0006/ | ||
* Technique: | ||
** Name: Steal Web Session Cookie | ||
** ID: T1539 | ||
** Reference URL: https://attack.mitre.org/techniques/T1539/ | ||
* Technique: | ||
** Name: Credentials from Password Stores | ||
** ID: T1555 | ||
** Reference URL: https://attack.mitre.org/techniques/T1555/ | ||
* Sub-technique: | ||
** Name: Credentials from Web Browsers | ||
** ID: T1555.003 | ||
** Reference URL: https://attack.mitre.org/techniques/T1555/003/ |
101 changes: 101 additions & 0 deletions
101
...s/8-2-1/prebuilt-rule-8-2-1-access-to-keychain-credentials-directories.asciidoc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,101 @@ | ||
[[prebuilt-rule-8-2-1-access-to-keychain-credentials-directories]] | ||
=== Access to Keychain Credentials Directories | ||
|
||
Adversaries may collect the keychain storage data from a system to acquire credentials. Keychains are the built-in way for macOS to keep track of users' passwords and credentials for many services and features such as WiFi passwords, websites, secure notes and certificates. | ||
|
||
*Rule type*: eql | ||
|
||
*Rule indices*: | ||
|
||
* auditbeat-* | ||
* logs-endpoint.events.* | ||
|
||
*Severity*: high | ||
|
||
*Risk score*: 73 | ||
|
||
*Runs every*: 5m | ||
|
||
*Searches indices from*: now-9m ({ref}/common-options.html#date-math[Date Math format], see also <<rule-schedule, `Additional look-back time`>>) | ||
|
||
*Maximum alerts per execution*: 100 | ||
|
||
*References*: | ||
|
||
* https://objective-see.com/blog/blog_0x25.html | ||
* https://securelist.com/calisto-trojan-for-macos/86543/ | ||
|
||
*Tags*: | ||
|
||
* Elastic | ||
* Host | ||
* macOS | ||
* Threat Detection | ||
* Credential Access | ||
|
||
*Version*: 8 | ||
|
||
*Rule authors*: | ||
|
||
* Elastic | ||
|
||
*Rule license*: Elastic License v2 | ||
|
||
|
||
==== Investigation guide | ||
|
||
|
||
[source, markdown] | ||
---------------------------------- | ||
---------------------------------- | ||
|
||
==== Rule query | ||
|
||
|
||
[source, js] | ||
---------------------------------- | ||
process where event.type in ("start", "process_started") and | ||
process.args : | ||
( | ||
"/Users/*/Library/Keychains/*", | ||
"/Library/Keychains/*", | ||
"/Network/Library/Keychains/*", | ||
"System.keychain", | ||
"login.keychain-db", | ||
"login.keychain" | ||
) and | ||
not process.args : ("find-certificate", | ||
"add-trusted-cert", | ||
"set-keychain-settings", | ||
"delete-certificate", | ||
"/Users/*/Library/Keychains/openvpn.keychain-db", | ||
"show-keychain-info", | ||
"lock-keychain", | ||
"set-key-partition-list", | ||
"import", | ||
"find-identity") and | ||
not process.parent.executable : | ||
( | ||
"/Applications/OpenVPN Connect/OpenVPN Connect.app/Contents/MacOS/OpenVPN Connect", | ||
"/Applications/Microsoft Defender.app/Contents/MacOS/wdavdaemon_enterprise.app/Contents/MacOS/wdavdaemon_enterprise", | ||
"/opt/jc/bin/jumpcloud-agent" | ||
) and | ||
not process.executable : "/opt/jc/bin/jumpcloud-agent" | ||
---------------------------------- | ||
|
||
*Framework*: MITRE ATT&CK^TM^ | ||
|
||
* Tactic: | ||
** Name: Credential Access | ||
** ID: TA0006 | ||
** Reference URL: https://attack.mitre.org/tactics/TA0006/ | ||
* Technique: | ||
** Name: Credentials from Password Stores | ||
** ID: T1555 | ||
** Reference URL: https://attack.mitre.org/techniques/T1555/ | ||
* Sub-technique: | ||
** Name: Keychain | ||
** ID: T1555.001 | ||
** Reference URL: https://attack.mitre.org/techniques/T1555/001/ |
112 changes: 112 additions & 0 deletions
112
...8-2-1/prebuilt-rule-8-2-1-account-discovery-command-via-system-account.asciidoc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,112 @@ | ||
[[prebuilt-rule-8-2-1-account-discovery-command-via-system-account]] | ||
=== Account Discovery Command via SYSTEM Account | ||
|
||
Identifies when the SYSTEM account uses an account discovery utility. This could be a sign of discovery activity after an adversary has achieved privilege escalation. | ||
|
||
*Rule type*: eql | ||
|
||
*Rule indices*: | ||
|
||
* winlogbeat-* | ||
* logs-endpoint.events.* | ||
* logs-windows.* | ||
|
||
*Severity*: low | ||
|
||
*Risk score*: 21 | ||
|
||
*Runs every*: 5m | ||
|
||
*Searches indices from*: now-9m ({ref}/common-options.html#date-math[Date Math format], see also <<rule-schedule, `Additional look-back time`>>) | ||
|
||
*Maximum alerts per execution*: 100 | ||
|
||
*References*: None | ||
|
||
*Tags*: | ||
|
||
* Elastic | ||
* Host | ||
* Windows | ||
* Threat Detection | ||
* Discovery | ||
|
||
*Version*: 14 | ||
|
||
*Rule authors*: | ||
|
||
* Elastic | ||
|
||
*Rule license*: Elastic License v2 | ||
|
||
|
||
==== Investigation guide | ||
|
||
|
||
[source, markdown] | ||
---------------------------------- | ||
## Triage and analysis | ||
### Investigating Account Discovery Command via SYSTEM Account | ||
After successfully compromising an environment, attackers may try to gain situational awareness to plan their next steps. | ||
This can happen by running commands to enumerate network resources, users, connections, files, and installed security | ||
software. | ||
This rule looks for the execution of account discovery utilities using the SYSTEM account, which is commonly observed | ||
after attackers successfully perform privilege escalation or exploit web applications. | ||
#### Possible investigation steps | ||
- Investigate the process execution chain (parent process tree) for unknown processes. Examine their executable files | ||
for prevalence, whether they are located in expected locations, and if they are signed with valid digital signatures. | ||
- If the process tree includes a web-application server process such as w3wp, httpd.exe, nginx.exe and alike, | ||
investigate any suspicious file creation or modification in the last 48 hours to assess the presence of any potential | ||
webshell backdoor. | ||
- Investigate other alerts associated with the user/host during the past 48 hours. | ||
- Determine how the SYSTEM account is being used. For example, users with administrator privileges can spawn a system | ||
shell using Windows services, scheduled tasks or other third party utilities. | ||
### False positive analysis | ||
- Discovery activities are not inherently malicious if they occur in isolation. As long as the analyst did not identify | ||
suspicious activity related to the user or host, such alerts can be dismissed. | ||
### Response and remediation | ||
- Initiate the incident response process based on the outcome of the triage. | ||
- Isolate the involved hosts to prevent further post-compromise behavior. | ||
- 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. | ||
- Run a full antimalware scan. This may reveal additional artifacts left in the system, persistence mechanisms, and | ||
malware components. | ||
- Determine the initial vector abused by the attacker and take action to prevent reinfection via 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). | ||
- Use the data collected through the analysis to investigate other machines affected in the environment. | ||
---------------------------------- | ||
|
||
==== Rule query | ||
|
||
|
||
[source, js] | ||
---------------------------------- | ||
process where event.type in ("start", "process_started") and | ||
(?process.Ext.token.integrity_level_name : "System" or | ||
?winlog.event_data.IntegrityLevel : "System") and | ||
(process.name : "whoami.exe" or | ||
(process.name : "net1.exe" and not process.parent.name : "net.exe")) | ||
---------------------------------- | ||
|
||
*Framework*: MITRE ATT&CK^TM^ | ||
|
||
* Tactic: | ||
** Name: Discovery | ||
** ID: TA0007 | ||
** Reference URL: https://attack.mitre.org/tactics/TA0007/ | ||
* Technique: | ||
** Name: System Owner/User Discovery | ||
** ID: T1033 | ||
** Reference URL: https://attack.mitre.org/techniques/T1033/ |
79 changes: 79 additions & 0 deletions
79
...ble-packages/8-2-1/prebuilt-rule-8-2-1-account-password-reset-remotely.asciidoc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
[[prebuilt-rule-8-2-1-account-password-reset-remotely]] | ||
=== Account Password Reset Remotely | ||
|
||
Identifies an attempt to reset a potentially privileged account password remotely. Adversaries may manipulate account passwords to maintain access or evade password duration policies and preserve compromised credentials. | ||
|
||
*Rule type*: eql | ||
|
||
*Rule indices*: | ||
|
||
* winlogbeat-* | ||
* logs-system.* | ||
|
||
*Severity*: medium | ||
|
||
*Risk score*: 47 | ||
|
||
*Runs every*: 5m | ||
|
||
*Searches indices from*: now-9m ({ref}/common-options.html#date-math[Date Math format], see also <<rule-schedule, `Additional look-back time`>>) | ||
|
||
*Maximum alerts per execution*: 100 | ||
|
||
*References*: | ||
|
||
* https://docs.microsoft.com/en-us/windows/security/threat-protection/auditing/event-4724 | ||
* https://stealthbits.com/blog/manipulating-user-passwords-with-mimikatz/ | ||
* https://github.com/sbousseaden/EVTX-ATTACK-SAMPLES/blob/master/Credential%20Access/remote_pwd_reset_rpc_mimikatz_postzerologon_target_DC.evtx | ||
|
||
*Tags*: | ||
|
||
* Elastic | ||
* Host | ||
* Windows | ||
* Threat Detection | ||
* Persistence | ||
|
||
*Version*: 5 | ||
|
||
*Rule authors*: | ||
|
||
* Elastic | ||
|
||
*Rule license*: Elastic License v2 | ||
|
||
|
||
==== Rule query | ||
|
||
|
||
[source, js] | ||
---------------------------------- | ||
sequence by host.id with maxspan=5m | ||
[authentication where event.action == "logged-in" and | ||
/* event 4624 need to be logged */ | ||
winlog.logon.type : "Network" and event.outcome == "success" and source.ip != null and | ||
source.ip != "127.0.0.1" and source.ip != "::1"] by winlog.event_data.TargetLogonId | ||
/* event 4724 need to be logged */ | ||
[iam where event.action == "reset-password" and | ||
( | ||
/* | ||
This rule is very noisy if not scoped to privileged accounts, duplicate the | ||
rule and add your own naming convention and accounts of interest here. | ||
*/ | ||
winlog.event_data.TargetUserName: ("*Admin*", "*super*", "*SVC*", "*DC0*", "*service*", "*DMZ*", "*ADM*") or | ||
winlog.event_data.TargetSid : "S-1-5-21-*-500" | ||
) | ||
] by winlog.event_data.SubjectLogonId | ||
---------------------------------- | ||
|
||
*Framework*: MITRE ATT&CK^TM^ | ||
|
||
* Tactic: | ||
** Name: Persistence | ||
** ID: TA0003 | ||
** Reference URL: https://attack.mitre.org/tactics/TA0003/ | ||
* Technique: | ||
** Name: Account Manipulation | ||
** ID: T1098 | ||
** Reference URL: https://attack.mitre.org/techniques/T1098/ |
Oops, something went wrong.