{"id":"86b896ba-ffa1-4fea-83e3-ee28a4c915c7","title":"Invoke-Obfuscation Via Stdin - Powershell","description":"Detects Obfuscated Powershell via Stdin in Scripts","author":"Nikita Nazarov, oscd.community","status":"test","level":"high","date":"2020-10-12","modified":"2024-04-05","tags":["attack.stealth","attack.t1027","attack.execution","attack.t1059.001"],"technique_ids":["T1027","T1059.001"],"logsource":{"product":"windows","category":"ps_script","definition":"Requirements: Script Block Logging must be enabled"},"falsepositives":["Unknown"],"references":["https://github.com/SigmaHQ/sigma/issues/1009"],"source_path":"rules/windows/powershell/powershell_script/posh_ps_invoke_obfuscation_via_stdin.yml","source_sha256":"817f5d5d145b111354ef31b9274e1cca0a7393cb0af968c96f5d5d77eb0f855a","source_url":"https://github.com/anpa1200/sigma/blob/b249e9683190cffdcaf188ccbfb90bf4759844e1/rules/windows/powershell/powershell_script/posh_ps_invoke_obfuscation_via_stdin.yml","license":"Detection Rule License 1.1","license_url":"https://github.com/SigmaHQ/Detection-Rule-License/blob/main/LICENSE.Detection.Rules.md","yaml":"title: Invoke-Obfuscation Via Stdin - Powershell\nid: 86b896ba-ffa1-4fea-83e3-ee28a4c915c7\nstatus: test\ndescription: Detects Obfuscated Powershell via Stdin in Scripts\nreferences:\n    - https://github.com/SigmaHQ/sigma/issues/1009  # (Task28)\nauthor: Nikita Nazarov, oscd.community\ndate: 2020-10-12\nmodified: 2024-04-05\ntags:\n    - attack.stealth\n    - attack.t1027\n    - attack.execution\n    - attack.t1059.001\nlogsource:\n    product: windows\n    category: ps_script\n    definition: 'Requirements: Script Block Logging must be enabled'\ndetection:\n    selection_4104:\n        ScriptBlockText|re: '(?i)(set).*&&\\s?set.*(environment|invoke|\\$\\{?input).*&&.*\"'\n    condition: selection_4104\nfalsepositives:\n    - Unknown\nlevel: high\n","validation":"yaml_parsed_not_backend_compiled_or_live_validated","techniques":[{"key":"enterprise/T1027","id":"T1027","name":"Obfuscated Files or Information","page":"techniques/enterprise/T1027/"},{"key":"enterprise/T1059.001","id":"T1059.001","name":"PowerShell","page":"techniques/enterprise/T1059.001/"}],"data_path":"data/detection-rules/86b896ba-ffa1-4fea-83e3-ee28a4c915c7.json","kind":"sigma"}
