T1583.007 Sumo Logic CSE · Sumo

Detect Serverless in Sumo Logic CSE

Adversaries may purchase and configure serverless cloud infrastructure, such as Cloudflare Workers, AWS Lambda functions, or Google Apps Scripts, to use during operations. By routing command-and-control (C2) traffic through serverless platforms, adversaries blend malicious communications with legitimate cloud provider traffic. Traffic from infected endpoints appears to target known cloud provider domains (workers.dev, cloudfunctions.net, lambda-url.amazonaws.com), making it difficult to distinguish from ordinary SaaS or cloud API usage. The serverless runtime proxies requests to adversary-owned infrastructure while the cloud provider absorbs attribution complexity. Detection requires identifying beaconing behavior, non-browser processes connecting to serverless endpoints, and anomalous DNS query patterns to serverless platform domains.

MITRE ATT&CK

Tactic
Resource Development
Technique
T1583 Acquire Infrastructure
Sub-technique
T1583.007 Serverless
Canonical reference
https://attack.mitre.org/techniques/T1583/007/

Sumo Detection Query

Sumo Logic CSE (Sumo)
sql
(_sourceCategory="WinEvents/Sysmon" OR _sourceCategory="windows/sysmon" OR _sourceCategory="*sysmon*")
| parse "<EventID>*</EventID>" as event_id
| where event_id = "3"
| parse "<Image>*</Image>" as process_image
| parse "<DestinationHostname>*</DestinationHostname>" as dest_hostname
| parse "<DestinationIp>*</DestinationIp>" as dest_ip
| parse "<DestinationPort>*</DestinationPort>" as dest_port
| parse "<User>*</User>" as username
| parse "<CommandLine>*</CommandLine>" as command_line
| parse "<ParentImage>*</ParentImage>" as parent_image
| where dest_hostname matches "*workers.dev"
    OR dest_hostname matches "*pages.dev"
    OR dest_hostname matches "*cloudfunctions.net"
    OR dest_hostname matches "*.execute-api.*.amazonaws.com"
    OR dest_hostname matches "*.lambda-url.*.amazonaws.com"
    OR dest_hostname matches "*azurewebsites.net"
    OR dest_hostname matches "*azurecontainerapps.io"
    OR dest_hostname matches "*netlify.app"
    OR dest_hostname matches "*vercel.app"
    OR dest_hostname = "script.google.com"
| where !(process_image matches /(?i)(chrome|firefox|msedge|iexplore|opera|brave|vivaldi)\.exe/)
| eval is_suspicious = if(process_image matches /(?i)(powershell|pwsh|cmd|wscript|cscript|mshta|rundll32|regsvr32|msbuild|python.*|node|curl|wget|wmic|bitsadmin)\.exe/, 1, 0)
| eval serverless_platform = if(dest_hostname matches "*workers.dev" OR dest_hostname matches "*pages.dev", "Cloudflare Workers",
    if(dest_hostname matches "*cloudfunctions.net", "Google Cloud Functions",
    if(dest_hostname matches "*execute-api*" OR dest_hostname matches "*lambda-url*", "AWS Lambda",
    if(dest_hostname matches "*azurewebsites.net" OR dest_hostname matches "*azurecontainerapps.io", "Azure Functions",
    if(dest_hostname matches "*netlify.app", "Netlify Functions",
    if(dest_hostname matches "*vercel.app", "Vercel Serverless",
    if(dest_hostname = "script.google.com", "Google Apps Script", "Other Serverless")))))))
| fields _messageTime, _sourceHost, username, process_image, command_line, parent_image, dest_hostname, dest_ip, dest_port, serverless_platform, is_suspicious
| sort by _messageTime desc
high severity high confidence

Sumo Logic search query parsing Sysmon EventID 3 (Network Connection Detected) XML log events to identify outbound connections from non-browser processes to serverless cloud platform endpoints. Uses glob-pattern hostname matching and regex-based process exclusion and classification. The is_suspicious field flags process names commonly leveraged by C2 implants and loaders.

Data Sources

Sumo Logic Hosted Collector ingesting Windows Sysmon XML event logsSysmon EventID 3 (Network Connection Detected)

Required Tables

_sourceCategory=WinEvents/Sysmon_sourceCategory=windows/sysmon

False Positives & Tuning

  • Development machines where node.exe or python.exe make frequent outbound DNS and HTTP connections to serverless APIs as part of front-end build tooling, serverless framework deployments (Serverless Framework, AWS SAM), or integration test suites
  • PowerShell-based IT automation or DSC (Desired State Configuration) scripts that trigger Azure Functions for provisioning tasks, alerting pipelines, or configuration drift remediation
  • Endpoint security agents or SOAR connectors implemented as Python or Node services that contact cloud-hosted enrichment functions for threat intelligence or automated response actions
Download portable Sigma rule (.yml)

Other platforms for T1583.007


Testing Methodology

Validate this detection against 4 adversary techniques from Atomic Red Team. Each test below lists the behaviour to exercise and the telemetry you should expect to see. Executable commands and cleanup steps are available with Pro.

  1. Test 1PowerShell Beaconing to Cloudflare Workers Endpoint

    Expected signal: Sysmon Event ID 1: powershell.exe spawned with command line containing Invoke-WebRequest and the workers.dev URL. Sysmon Event ID 22: 5 DNS query events for df00tech-sentinel-test.argustest.workers.dev. Sysmon Event ID 3: 5 Network Connection events from powershell.exe to the Cloudflare IP on port 443. PowerShell ScriptBlock Log Event ID 4104 capturing the full loop script.

  2. Test 2Python Script Polling AWS Lambda Function URL

    Expected signal: Sysmon Event ID 1: python.exe (or python3.exe) process created with command line containing lambda-url and amazonaws.com. Sysmon Event ID 22: DNS query events for the Lambda URL subdomain (abcde12345fghij.lambda-url.us-east-1.amazonaws.com). Sysmon Event ID 3: Network connection events from python.exe to AWS IP ranges on port 443. Connections will fail with connection refused but process and DNS events fire.

  3. Test 3WScript Invoking Google Apps Script Web App (BlackWater Technique)

    Expected signal: Sysmon Event ID 1: cmd.exe spawning echo to create the .js file, then wscript.exe executing df00tech_gapps_test.js. Sysmon Event ID 11: File Create event for df00tech_gapps_test.js in %TEMP%. Sysmon Event ID 22: DNS query for script.google.com. Sysmon Event ID 3: Network connection from wscript.exe to Google IP on port 443 with DestinationHostname=script.google.com.

  4. Test 4cURL Beaconing to Google Cloud Function (Repeated Intervals)

    Expected signal: Sysmon Event ID 1: cmd.exe created with the for loop command, then curl.exe spawned 4 times as child processes with the cloudfunctions.net URL as an argument. Sysmon Event ID 22: DNS query events for us-central1-df00tech-argus-test.cloudfunctions.net. Sysmon Event ID 3: 4 Network Connection events from curl.exe to Google Cloud IP on port 443. Connections will return an error but process and DNS events fire regardless.

Unlock Pro Content

Get the full detection package for T1583.007 including response playbook, investigation guide, and atomic red team tests.

Response PlaybookInvestigation GuideHunting QueriesAtomic Red Team TestsTuning Guidance

Related Detections