Skip to content
Threat Feed
medium advisory

Detection of Encoded HTTP POST Payloads

This detection identifies anomalous HTTP POST requests containing heavily encoded bodies, specifically using hex escape sequences or base64 character blocks often used by adversaries to obfuscate C2 traffic or exfiltrated data.

This threat brief focuses on the detection of encoded HTTP POST request bodies, a technique frequently leveraged by adversaries for Command and Control (C2) communication and data exfiltration. By encoding payloads using hexadecimal escape sequences or Base64 character sets, attackers attempt to bypass basic security controls that monitor for plain-text indicators. The detection mechanism relies on Zeek HTTP logs, specifically requiring the extraction of HTTP POST bodies. An alert is triggered when the body contains eight or more consecutive hex escape sequences or sixteen or more consecutive Base64 character groups. While effective for surfacing obfuscated traffic, analysts should note that certain legitimate API integrations or binary data transfers may trigger false positives.

Impact

Successful exploitation of obfuscated C2 or exfiltration channels allows attackers to maintain persistent control over compromised hosts and move sensitive data out of the network environment while remaining undetected by traditional signature-based network intrusion detection systems. The breadth of potential impact depends on the specific malware or actor utilizing these channels, ranging from information theft to secondary payload delivery.

Recommendation

  • Configure your Zeek deployment with the HTTP post body extraction policy to ensure the required data is available in logs.
  • Deploy the provided Sigma rule (or equivalent SIEM query) to your network monitoring stack to flag anomalous POST requests.
  • Establish a baseline of known-good API endpoints and applications that transmit binary or base64 data to reduce the false positive rate during initial tuning.
  • Investigate alerts by reviewing the destination, URI, and the decoded content of the flagged POST body to distinguish between malicious obfuscation and legitimate traffic.

Immediate actions

Enable HTTP post body extraction in Zeek

IT Operations 72h

Deploy the Sigma detection rule to SIEM

Detection Engineering 72h

Threat Hunt

Identify all HTTP POST traffic over the last 30 days and calculate the frequency of high-entropy strings.

T1071.001 medium medium confidence hunt now

Data: Zeek HTTP logs

Mitigations

Implement baseline and tuning for APIs known to use base64 encoding

medium Detection Engineering

False positive reduction

Detection coverage 1

Detect Encoded HTTP POST Body

medium

Detects HTTP POST requests with excessive hex or base64 encoding in the body, suggesting obfuscated C2 or exfiltration activity.

sigma tactics: command_and_control techniques: T1071.001, T1132.001 sources: webserver

Detection queries are available on the platform. Get full rules →