Change User Agents with WebRequest

 Original Source: [Sigma source]
Title: Change User Agents with WebRequest
Status: test
Description:Adversaries may communicate using application layer protocols associated with web traffic to avoid detection/network filtering by blending in with existing traffic. Commands to the remote system, and often the results of those commands, will be embedded within the protocol traffic between the client and server.
References:
  -https://github.com/redcanaryco/atomic-red-team/blob/f339e7da7d05f6057fdfcdd3742bfcf365fee2a9/atomics/T1071.001/T1071.001.md#t1071001---web-protocols
Author: frack113
Date: 2022-01-23
modified:2025-07-18
Tags:
  • -'attack.command-and-control'
  • -'attack.t1071.001'
Logsource:
  • product: windows
  • category: ps_script
  • definition: Requirements: Script Block Logging must be enabled
Detection:
  selection_webrequest:
    ScriptBlockText|contains:
      -'Invoke-WebRequest'
      -'Invoke-RestMethod'
      -' irm '
      -'iwr '

  selection_useragent:
    ScriptBlockText|contains: '-UserAgent '
  condition:all of selection_*
Falsepositives:
  -Unknown
Level: medium