PH_Rule_SIGMA_314
Enabled
Detects the usage of the 'SeLoadDriverPrivilege' privilege. This privilege is required to load or unload a device driver. With this privilege, the user can dynamically load and unload device drivers or other code in to kernel mode. This user right does not apply to Plug and Play device drivers. If you exclude privileged users/admins and processes, which are allowed to do so, you are maybe left with bad programs trying to load malicious kernel drivers. This will detect Ghost-In-The-Logs (https://github.com/bats3c/Ghost-In-The-Logs) and the usage of Sysinternals and various other tools. So you have to work with a whitelist to find the bad stuff. . This rule is adapted from https://github.com/SigmaHQ/sigma/blob/master/rules/windows/builtin/security/win_security_user_driver_loaded.yml
5
Security
Defense Evasion
Defense Evasion consists of techniques that adversaries use to avoid detection throughout their compromise. Techniques used for defense evasion include uninstalling/disabling security software or obfuscating/encrypting data and scripts. Adversaries also leverage and abuse trusted processes to hide and masquerade their malware. Other tactics’ techniques are cross-listed here when those techniques include the added benefit of subverting defenses.
https://attack.mitre.org/tactics/TA0005T1562.001
Impair Defenses: Disable or Modify Tools
Adversaries may disable security tools to avoid possible detection of their tools and activities. This can take the form of killing security software or event logging processes, deleting Registry keys so that tools do not start at run time, or other methods to interfere with security tools scanning or reporting information.
https://attack.mitre.org/techniques/T1562/001Server
Windows Security Log via OMI or FortiSIEM Agent
Correlation
No remediation guidance specified
If the following pattern or patterns match an ingested event within the given time window in seconds, trigger an incident.
300 seconds
If the following defined pattern/s occur within a 300 second time window.
Filter
This is the named definition of the event query, this is important if multiple subpatterns are defined to distinguish them.
This is the query logic that matches incoming events
(eventType="Win-Security-4673" AND privName="SeLoadDriverPrivilege" AND serviceName IS NULL) AND ((procName NOT IN ("C:\\Windows\\HelpPane.exe","C:\\Windows\\System32\\Dism.exe","C:\\Windows\\System32\\RuntimeBroker.exe","C:\\Windows\\System32\\SystemSettingsBroker.exe","C:\\Windows\\System32\\fltMC.exe","C:\\Windows\\System32\\mmc.exe","C:\\Windows\\System32\\rundll32.exe","C:\\Windows\\System32\\svchost.exe","C:\\Windows\\System32\\wimserv.exe","C:\\Windows\\explorer.exe")) AND (procName NOT REGEXP "\\AppData\\Local\\Microsoft\\Teams\\current\\Teams\.exe$|\\Google\\Chrome\\Application\\chrome\.exe$|\\procexp64\.exe$|\\procexp\.exe$|\\procmon64\.exe$|\\procmon\.exe$") AND (procName NOT REGEXP "^C:\\Program Files\\WindowsApps\\Microsoft"))
This defines how matching events are aggregated, only events with the same matching attribute values are grouped into one unique incident ID
hostName,privName,procName,serviceName
This is most typically a numerical constraint that defines when the rule should trigger an incident
COUNT(*) >= 1
This section defines which fields in matching raw events should be mapped to the incident attributes in the resulting incident.
The available raw event attributes to map are limited to the group by attributes and the aggregate event constraint fields for each subpattern
hostName = Filter.hostName,
privName = Filter.privName,
procName = Filter.procName,
serviceName = Filter.serviceName