Windows PowerShell Export PfxCertificate
The following analytic detects the use of the PowerShell cmdlet `export-pfxcertificate` by leveraging Script Block Logging. This activity is significant as it may indicate an adversary attempting to exfiltrate…
Description
The following analytic detects the use of the PowerShell cmdlet `export-pfxcertificate` by leveraging Script Block Logging. This activity is significant as it may indicate an adversary attempting to exfiltrate certificates from the Windows Certificate Store. Monitoring this behavior is crucial for identifying potential certificate theft, which can lead to unauthorized access and impersonation attacks. If confirmed malicious, this activity could allow attackers to compromise secure communications, authenticate as legitimate users, and escalate their privileges within the network.
Detection logic
Detection requirements
- Platform
- Identity ProviderLinuxmacOSNetwork DevicesWindows
The rule states no platform. This is derived from the 2 ATT&CK techniques it maps to.
- Log source category
- powershell_script_block_logging_4104
Known benign triggers
- It is possible administrators or scripts may run these commands, filtering may be required.
MITRE ATT&CK mappings
0 exclusive techniques.This is coverage no other published rule has; it is not this rule's total technique count.
References
| Reference | Cited by |
|---|---|
| dev.to/iamthecarisma/managing-windows-pfx-certificates-through-powershell-3pj | 4 |
| github.com/redcanaryco/atomic-red-team/blob/388942adbd9641f4dfdcf079d7efe9a75ec0ac43/atomics/T1552.004/T1552.004.yaml#L325 | 4 |
| learn.microsoft.com/en-us/powershell/module/pki/export-pfxcertificate?view=windowsserver2022-ps | 4from 2 sources |
From the source
- At source
- Open at source
- Upstream identifier
- ed06725f-6da6-439f-9dcc-ab30e891297c
- Tagged by the source as
- Scattered Lapsus$ HuntersWater GamayunWindows Certificate ServicesEndpointendpointSplunk CloudSplunk EnterpriseSplunk Enterprise Securityendpoint
Licence
- Published under
- Apache License 2.0Read the licence
- Attribution
- Required
- Obtained under
- Apache-2.0Read the origin licence
Authorship
- Written by
- Published
- Oct 13, 2026
- Version
- 2