Suspicious LSASS Access via MalSecLogon

Identifies suspicious access to LSASS handle from a call trace pointing to seclogon.dll and with a suspicious access rights value. This may indicate an attempt to leak an LSASS handle via abusing the Secondary Logon service in preparation for credential access.

Elastic rule (View on GitHub)

 1[metadata]
 2creation_date = "2022/06/29"
 3integration = ["windows"]
 4maturity = "production"
 5updated_date = "2024/05/21"
 6
 7[rule]
 8author = ["Elastic"]
 9description = """
10Identifies suspicious access to LSASS handle from a call trace pointing to seclogon.dll and with a suspicious access
11rights value. This may indicate an attempt to leak an LSASS handle via abusing the Secondary Logon service in
12preparation for credential access.
13"""
14from = "now-9m"
15index = ["winlogbeat-*", "logs-windows.sysmon_operational-*"]
16language = "eql"
17license = "Elastic License v2"
18name = "Suspicious LSASS Access via MalSecLogon"
19references = ["https://splintercod3.blogspot.com/p/the-hidden-side-of-seclogon-part-3.html"]
20risk_score = 73
21rule_id = "7ba58110-ae13-439b-8192-357b0fcfa9d7"
22setup = """## Setup
23
24If enabling an EQL rule on a non-elastic-agent index (such as beats) for versions <8.2,
25events will not define `event.ingested` and default fallback for EQL rules was not added until version 8.2.
26Hence for this rule to work effectively, users will need to add a custom ingest pipeline to populate
27`event.ingested` to @timestamp.
28For more details on adding a custom ingest pipeline refer - https://www.elastic.co/guide/en/fleet/current/data-streams-pipeline-tutorial.html
29"""
30severity = "high"
31tags = [
32    "Domain: Endpoint",
33    "OS: Windows",
34    "Use Case: Threat Detection",
35    "Tactic: Credential Access",
36    "Data Source: Sysmon",
37]
38timestamp_override = "event.ingested"
39type = "eql"
40
41query = '''
42process where host.os.type == "windows" and event.code == "10" and
43  winlog.event_data.TargetImage : "?:\\WINDOWS\\system32\\lsass.exe" and
44
45   /* seclogon service accessing lsass */
46  winlog.event_data.CallTrace : "*seclogon.dll*" and process.name : "svchost.exe" and
47
48   /* PROCESS_CREATE_PROCESS & PROCESS_DUP_HANDLE & PROCESS_QUERY_INFORMATION */
49  winlog.event_data.GrantedAccess == "0x14c0"
50'''
51
52
53[[rule.threat]]
54framework = "MITRE ATT&CK"
55[[rule.threat.technique]]
56id = "T1003"
57name = "OS Credential Dumping"
58reference = "https://attack.mitre.org/techniques/T1003/"
59[[rule.threat.technique.subtechnique]]
60id = "T1003.001"
61name = "LSASS Memory"
62reference = "https://attack.mitre.org/techniques/T1003/001/"
63
64
65
66[rule.threat.tactic]
67id = "TA0006"
68name = "Credential Access"
69reference = "https://attack.mitre.org/tactics/TA0006/"

References

Related rules

to-top