Skip to content

Siemphony is in beta and still being built. How a rule earns its badge.

Siemphony’s repertoire

Network share unmapped via net use or Remove-SmbMapping

Matches AN0286's command-line half: a new process whose command line tears down an SMB share mapping, either the built-in `net use \\host\share /delete` (and its `net1.exe` twin, which `net.exe` re-execs on 64-bit Windows for the same verb) or the PowerShell `Remove-SmbMapping` cmdlet. This is deliberately not written against the brief's Security 4624/4648 logsource: those are Logon Session Creation events, and neither carries a disconnect or session-teardown record at all, despite AN0286's own description naming "SMB session teardown activity" as part of what it correlates — there is no field on either EventID that reflects a share being removed, so a rule keyed on them would validate and never fire. The PowerShell 4103/4106 logsource is also not used: Remove-SmbMapping typed into an already-open interactive console produces no new process_creation event at all, only a module/script-block log entry, so this selection only catches the cmdlet when it arrives as an argument to a freshly spawned powershell.exe (e.g. `powershell -Command "Remove-SmbMapping -ShareName *"`) — a real but partial view of MITRE's own NetworkShareNamePattern and ProcessCommandLineRegex knobs, not the interactive case. MITRE's TimeWindow knob (correlating the CLI command with the actual SMB session teardown) is a cross-event join lib/sigma cannot express, so this fires on the command line alone, with no confirmation the disconnect actually succeeded. UNVERIFIED AS AUTHORED — derived from MITRE ATT&CK DET0103, not hand-written and not tested by its author. Any lab result is on this rule's own page.Full description

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

title: Network share unmapped via net use or Remove-SmbMappingid: 91342374-abdb-4dca-bce7-ee8ff9ade64astatus: experimentaldescription: |  Matches AN0286's command-line half: a new process whose command line tears  down an SMB share mapping, either the built-in `net use \\host\share  /delete` (and its `net1.exe` twin, which `net.exe` re-execs on 64-bit  Windows for the same verb) or the PowerShell `Remove-SmbMapping` cmdlet.  This is deliberately not written against the brief's Security 4624/4648  logsource: those are Logon Session Creation events, and neither carries a  disconnect or session-teardown record at all, despite AN0286's own  description naming "SMB session teardown activity" as part of what it  correlates — there is no field on either EventID that reflects a share  being removed, so a rule keyed on them would validate and never fire. The  PowerShell 4103/4106 logsource is also not used: Remove-SmbMapping typed  into an already-open interactive console produces no new process_creation  event at all, only a module/script-block log entry, so this selection only  catches the cmdlet when it arrives as an argument to a freshly spawned  powershell.exe (e.g. `powershell -Command "Remove-SmbMapping -ShareName  *"`) — a real but partial view of MITRE's own NetworkShareNamePattern and  ProcessCommandLineRegex knobs, not the interactive case. MITRE's TimeWindow  knob (correlating the CLI command with the actual SMB session teardown) is  a cross-event join lib/sigma cannot express, so this fires on the command  line alone, with no confirmation the disconnect actually succeeded.  UNVERIFIED AS AUTHORED — derived from MITRE ATT&CK DET0103, not hand-written and not tested by its author. Any lab result is on this rule's own page.references:  - https://attack.mitre.org/techniques/T1070/005  - https://attack.mitre.org/detectionstrategies/DET0103author: Siemphony pipeline (machine-derived from MITRE ATT&CK v19.2)date: 2026-08-18tags:  - attack.defense-evasion  - attack.t1070.005logsource:  category: process_creation  product: windowsdetection:  selection_net_delete:    Image|endswith:      - '\net.exe'      - '\net1.exe'    CommandLine|contains|all:      - 'use '      - '/delete'  selection_psh_removesmb:    CommandLine|contains: 'Remove-SmbMapping'  condition: 1 of selection*falsepositives:  - "Logon and logoff scripts, whether local GPO scripts or login scripts on a file server, that run `net use * /delete` or target a specific drive letter at every session end to tear down mapped drives before the next user logs on — the single highest-volume source of this command line on any domain-joined fleet."  - "SCCM, Intune and imaging/provisioning tooling that removes stale share mappings left from a previous user profile as a routine step of machine setup or re-provisioning."  - "VDI and RDS session-teardown scripts, and roaming-profile management tooling, that call Remove-SmbMapping or net use /delete against persistent share mappings when a non-persistent session ends, so this fires on every logoff in that environment."level: low

Sentinel · KQL

Run this as a search.

DeviceProcessEvents| where (((FolderPath endswith "\\net.exe" or FolderPath endswith "\\net1.exe") and (ProcessCommandLine contains "use " and ProcessCommandLine contains "/delete")) or ProcessCommandLine contains "Remove-SmbMapping")

Splunk · SPL

Run this as a search.

index=* (((Image="*\\net.exe" OR Image="*\\net1.exe") AND (CommandLine="*use *" AND CommandLine="*/delete*")) OR CommandLine="*Remove-SmbMapping*")

Elastic · ES|QL

Run this as a search.

FROM logs-*| WHERE (((TO_LOWER(process.executable) LIKE "*\\\\net.exe" OR TO_LOWER(process.executable) LIKE "*\\\\net1.exe") AND (TO_LOWER(process.command_line) LIKE "*use *" AND TO_LOWER(process.command_line) LIKE "*/delete*")) OR TO_LOWER(process.command_line) LIKE "*remove-smbmapping*")

Wazuh · XML rule

Deploy to your manager — this is a rule, not a search.

<group name="sigma,windows,process_creation,">  <!-- Rule ids must be unique on your manager; 100000+ is the user range. -->  <!-- 2 rules: the Sigma condition ORs across different fields,       which one rule cannot express. Any one matching is a hit. -->  <rule id="100000" level="5">    <!-- Set <if_sid> to the decoder/base rule for windows so this only evaluates relevant events. -->    <field name="Image" type="pcre2">(?i)(\\net\.exe$|\\net1\.exe$)</field>    <field name="CommandLine" type="pcre2">(?i)(?=.*(?:use ))(?=.*(?:/delete)).*</field>    <description>Network share unmapped via net use or Remove-SmbMapping (1/2)</description>    <mitre>      <id>T1070.005</id>    </mitre>  </rule>   <rule id="100001" level="5">    <!-- Set <if_sid> to the decoder/base rule for windows so this only evaluates relevant events. -->    <field name="CommandLine" type="pcre2">(?i)Remove-SmbMapping</field>    <description>Network share unmapped via net use or Remove-SmbMapping (2/2)</description>    <mitre>      <id>T1070.005</id>    </mitre>  </rule></group>

Verdicts · reactions · comments

Community

Verdicts from engineers who actually deployed it, and the conversation around it.

Log in to react
Not yet reported on

Nobody has run this in a real environment and said what happened.

Verdicts from engineers who deployed it

0 cast

No 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.