Global SOC / Blog
DNS Audit

THREAT RESEARCH & LABS · Yogesh · 15 November 2026

The Honeypot Detection Playbook: What Attacked My Server, and the Splunk and Sentinel Rules to Catch It

I ran a deliberately vulnerable PHP server on the internet and turned everything that hit it into detections. This is the hub: the kill-chain and ATT&CK coverage map, the data sources you need, and links to twelve posts with tested queries for Splunk + CrowdStrike Falcon and Microsoft Sentinel + Defender for Endpoint.

1. Why I Built This

I put a vulnerable PHP container on a public IP the day after a new PHP bug was disclosed, logged everything into Microsoft Sentinel, and watched. The first request arrived after 33 minutes. Over the next three and a half weeks it took 133,331 SSH password guesses, about 10,500 web requests from more than 1,100 addresses, and every flavour of exploit, credential hunt and scanner you'd expect, plus a few I didn't.

The traffic itself isn't the interesting part. What matters is what a defender should do about it. So each post in this series takes one kind of attack and walks through it the same way:

2. How to Read the Series

Every detection is written twice:

Every web-layer KQL query was run against the honeypot's real logs, and the counts in each post are what came back. The honeypot had no EDR on it, so the endpoint queries are written from the payloads the attackers sent, which tell you exactly what would have run. Treat their field names as a starting point for your environment.

3. Coverage Map

Each row is an ATT&CK technique I saw used against the honeypot. The cells show which post covers it and which layer detects it.

Kill chainATT&CK techniqueSeen inWeb / log layerEndpoint / network layer
ReconT1595.001 Scanning IP BlocksSSH, Non-HTTPProtocol classification on web portsNew listening port on internet-facing host
ReconT1595.002 Vulnerability ScanningSpray, RedTailMulti-family exploit burst; kit fingerprintCorrelated with web-server child process
ReconT1595.003 Wordlist Scanning.env/.git, AI/MCPSecret-path wordlist; canary calibrationn/a
ReconT1592.002 Gather Host SoftwareSpraySlow edge-device fingerprintingn/a
Credential AccessT1110.001 Password Guessing (incl. distributed)SSHPer-source volume; many-sources-one-usernameSuccess after failures (UserLogon, DeviceLogonEvents)
Credential AccessT1552.001 Credentials in Files.env/.git, AI/MCP, React2ShellSecret file actually served (size check)Agent token files read by other processes; env; cat .env from an app runtime
Initial AccessT1190 Exploit Public-Facing AppAll web postsCode in request; per-CVE rules; execution canariesn/a
Initial AccessT1078 Valid Accounts (incl. .004 Cloud)SSH, .env/.gitCloudTrail: GetSendQuota, CreateUser; key from new IPAI API calls from unapproved processes
ExecutionT1059.004 Unix ShellRedTail, PHP2Shell, React2Shell, Legacy PHPn/aWeb server / app runtime spawns a shell
PersistenceT1505.003 Web ShellLegacy PHP, PHP2Shellpearcmd writes; session-file includePHP file written to /tmp or web root
PersistenceT1098.004 SSH Authorized KeysSSHn/aauthorized_keys written; chattr +i
Defence EvasionT1564.001 Hidden FilesRedTail, Legacy PHPn/aDot-file or temp-path executable run by the web user
DiscoveryT1083 File and Directory DiscoveryRedTailn/a"Where can I execute?" (findmnt noexec, find -perm, dd test)
DiscoveryT1082 System Information DiscoverySSH, IoTn/aPost-login fingerprinting burst
DeliveryT1105 Ingress Tool TransferAll dropper postsDownload-and-run command to a raw IPWeb tier SSH egress; hostname-beacon pipelines; IoT raw-IP downloads; Mirai-style loader routine
C2T1071 / T1095 / T1571 App Protocol, Non-App, Non-Standard PortNon-HTTP, React2Shell, IoTRAT check-in classificationRAT protocol on the wire; raw-IP beaconing; Node reverse shell; Mozi DHT
ImpactT1496 Resource HijackingRedTailn/aMining-pool connections (hunt)
ImpactT1565.003 / T1491.002 Runtime Manipulation, DefacementReact2ShellRedirect-rate anomaly per site(Invisible to EDR: in-memory patch)

4. The Five Rules to Build First

If you only build five rules from the whole series, build these. Each one sits near the top of the Pyramid of Pain, so it outlives any particular CVE:

  1. Web server or app runtime spawns a shell or downloader (RedTail E1). It catches almost every successful web RCE in the series, whatever the bug.
  2. SSH success after failures (SSH L3). It tested at zero results on the honeypot, and that's what you want: when it fires, it matters.
  3. A secret file was actually served (.env W2). It compares response size with the home page, which removed all 16 false positives a status-only rule would have raised.
  4. Exploit burst against a host, correlated with an endpoint hit (Spray C1). This turns daily noise into one incident with the story attached.
  5. Web tier egress on SSH, or to a raw IP on a high port (RedTail E2, React2Shell E2). Droppers and reverse shells both have to leave the box.

5. Data You Need

DataOrg A SplunkOrg B SentinelWhy
Web access logs, with POST bodies or a WAFCIM Web; raw nginx/ApacheW3CIISLog, AzureDiagnostics (WAF), SyslogEvery web-layer rule. Check that large records aren't truncated (see PHP2Shell W4).
PHP / app error logsapache:error, php:errorSyslog / custom tablePHP2Shell's startup memory errors only show here.
sshd logslinux_secureSyslog (auth)Brute force and success-after-failure.
EDR process, network and file eventsFalcon FDRDefender XDR connectorEvery endpoint rule.
Network metadataZeek, Palo AltoCommonSecurityLog, ASim DNSIoT devices and RATs, where there's no EDR.
Cloud auditAWS CloudTrail add-onAWSCloudTrailLeaked keys being used.

Falcon field names for Org A

The Org A queries use the field names Falcon's Event Search shows: FileName, ParentBaseFileName, GrandParentBaseFileName, ComputerName, UserName and the *_decimal process IDs. If you ingest raw Falcon Data Replicator events into Splunk, some of those don't exist yet. Add this macro, put it straight after index=crowdstrike event_simpleName=…, and move the remaining filters into a | search after it:

# macros.conf
[falcon_norm]
definition = eval FileName=coalesce(FileName, replace(ImageFileName, "^.*[\\\\/]", "")), \
  TargetProcessId_decimal=coalesce(TargetProcessId_decimal, TargetProcessId), \
  ContextProcessId_decimal=coalesce(ContextProcessId_decimal, ContextProcessId), \
  ParentProcessId_decimal=coalesce(ParentProcessId_decimal, ParentProcessId) \
| lookup aid_master aid OUTPUTNEW ComputerName \
| lookup falcon_user_map UserSid_readable OUTPUTNEW UserName

The macro needs two lookups, built by two scheduled searches (run them hourly):

# aid_master: host name for each sensor ID, from FDR's aidmaster records
index=crowdstrike sourcetype=crowdstrike:events:aidmaster
| stats latest(ComputerName) as ComputerName by aid
| outputlookup aid_master

# falcon_user_map: user name for each SID, from FDR's user identity events
index=crowdstrike event_simpleName=UserIdentity
| stats latest(UserName) as UserName by UserSid_readable
| outputlookup falcon_user_map

Check the sourcetype names against your Falcon add-on. They differ between the FDR add-on and older Event Stream setups.

Raw FDR doesn't always carry the grandparent's name. Where a query filters on GrandParentBaseFileName, either use the Event Search field or join ProcessRollup2 to itself on aid and ParentProcessId to walk one level up.

The Org B web parser used throughout the series. Swap the source for your own and keep the column names:

let WebAccess = Syslog
| where SyslogMessage startswith "php_http: "
| extend j = parse_json(substring(SyslogMessage, 10))
| project TimeGenerated, DestHost = Computer, SrcIp = tostring(j.client), Method = tostring(j.method), Request = tostring(j.request),
          Url = tostring(j.uri), Status = toint(j.status), BytesOut = toint(j.bytes_out),
          UserAgent = tostring(j.user_agent), ContentType = tostring(j.content_type), Body = tostring(j.body);

6. The Posts

PostWhat you'll build
SSH brute forceDistributed-guessing detection that sees the 784 quiet sources; success-after-failure; post-login fingerprinting; authorized_keys writes
Non-HTTP on port 80Protocol-mismatch classification; RAT check-in signatures turned outward; open-proxy and odd-method posture
.env and .git huntingWordlist detection; "secret actually served"; AndroxGh0st sequence; CloudTrail rules for leaked keys
Legacy PHP RCECode-in-request; execution canaries; hostname-beacon droppers; hidden scripts in /tmp
RedTail cryptominerExploit-burst behaviour; web-server-spawns-shell; SSH egress; exec-directory discovery; hidden miner
IoT botnets and MoziNetwork detections for devices with no EDR; Mozi DHT; Mirai loader on servers; n8n abuse
React2ShellWrapper detection; PoC boundary; Node reverse shell; fileless redirect-hijack via traffic anomaly
PHP2ShellUpload-progress abuse; session-file include; startup OOM bursts; SIEM truncation check
AI keys and MCPAI-path wordlists; distributed MCP discovery; agent-token theft on endpoints; unapproved AI API use
Spray scannersCanary calibration; slow fingerprinting; kit fingerprints; risk-based correlation
Scanner vs attackersSafe scanner allowlisting; coverage-gap query; using your scan to test your SOC
Internet scanner triageBehaviour-based trust; benign-list abuse detection; new exposure before Censys finds it