New subkey created under a trusted root certificate store
AN0153 asks for unauthorised modification of the Windows root certificate stores, and names three feeds for it: Security EventID 4657, Sysmon EventID 12 and Sysmon EventID 1. This rule is written against the Sysmon registry-creation feed, because installing a root certificate creates a new subkey named after the certificate's thumbprint under the store, and a key creation is the single event that says "a certificate the machine did not have before is now trusted". The three paths matched cover the machine-wide store (HKLM\SOFTWARE\Microsoft\SystemCertificates\Root\Certificates), the automatic-root-update store (AuthRoot), the group-policy-pushed store under SOFTWARE\Policies, and the per-user store under HKU\<SID>, since every one of those spellings contains the same middle fragment. The certificate blob itself arrives afterwards as a registry value set, which is a different event class; matching key creation instead keeps this to the moment the trust is granted. Two things to be clear about before deploying it. The vocabulary here is Sysmon's — TargetObject holds the whole key path — so the brief's other feed, Security EventID 4657, cannot be pointed at this rule as an interchangeable source: 4657 is a value-change event and splits the path across ObjectName and ObjectValueName, so it needs a field mapping and a different predicate before it could match anything here. And Sysmon EventID 12 is only emitted for keys a site's Sysmon configuration includes; the widely used community configurations filter registry events aggressively and several do not cover SystemCertificates at all, so confirm the key is in scope for the running config before reading a silent rule as a clean estate. The svchost.exe exclusion drops the two machine-driven writers — the automatic root update service and group-policy certificate deployment, both hosted there — which also means a certificate installed by code injected into a service host will not be seen by this rule. UNVERIFIED AS AUTHORED — derived from MITRE ATT&CK DET0056, not hand-written and not tested by its author. Any lab result is on this rule's own page.Full descriptionShow less
The detection
The 4 SIEM queries below are previews produced by Siemphony’s own translator, not pySigma, and none has been executed against a real backend — review before you deploy.
detection.yml
Sentinel · KQL
Run this as a search.
DeviceRegistryEvents| where ((RegistryKey contains "\\SystemCertificates\\Root\\Certificates\\" or RegistryKey contains "\\SystemCertificates\\AuthRoot\\Certificates\\" or RegistryKey contains "\\EnterpriseCertificates\\Root\\Certificates\\") and not (InitiatingProcessFolderPath =~ "C:\\Windows\\System32\\svchost.exe"))
Splunk · SPL
Run this as a search.
index=* ((TargetObject="*\\SystemCertificates\\Root\\Certificates\\*" OR TargetObject="*\\SystemCertificates\\AuthRoot\\Certificates\\*" OR TargetObject="*\\EnterpriseCertificates\\Root\\Certificates\\*") AND NOT (Image="C:\\Windows\\System32\\svchost.exe"))Elastic · ES|QL
Run this as a search.
FROM logs-*| WHERE ((TO_LOWER(registry.path) LIKE "*\\\\systemcertificates\\\\root\\\\certificates\\\\*" OR TO_LOWER(registry.path) LIKE "*\\\\systemcertificates\\\\authroot\\\\certificates\\\\*" OR TO_LOWER(registry.path) LIKE "*\\\\enterprisecertificates\\\\root\\\\certificates\\\\*") AND NOT (TO_LOWER(process.executable) == "c:\\windows\\system32\\svchost.exe"))
Wazuh · XML rule
Deploy to your manager — this is a rule, not a search.
<group name="sigma,windows,registry_add,"> <!-- Rule ids must be unique on your manager; 100000+ is the user range. --> <rule id="100000" level="7"> <!-- Set <if_sid> to the decoder/base rule for windows so this only evaluates relevant events. --> <field name="TargetObject" type="pcre2">(?i)(\\SystemCertificates\\Root\\Certificates\\|\\SystemCertificates\\AuthRoot\\Certificates\\|\\EnterpriseCertificates\\Root\\Certificates\\)</field> <field name="Image" negate="yes" type="pcre2">(?i)^C:\\Windows\\System32\\svchost\.exe$</field> <description>New subkey created under a trusted root certificate store</description> <mitre> <id>T1553.004</id> </mitre> </rule></group>
Verdicts · reactions · comments
Community
Verdicts from engineers who actually deployed it, and the conversation around it.
Nobody has run this in a real environment and said what happened.
Verdicts from engineers who deployed it
0 castNo verdicts reported yet. The first one is worth more than the tenth — say what you ran it against.
Log in to report a verdict.
Log in to join the discussion.
No comments yet. Someone who deploys this will have something to say about it.