Skip to main content
UNIFIED SOC INCIDENT RESPONSE BLUEPRINT

PHP2Shell: How to Detect & Mitigate Critical 9.2 PHP RCE Flaws

Two critical 9.2 RCE flaws named PHP2Shell strike PHP runtimes. Ini workarounds fail to protect unpatched servers. Here is how to defend.

Detection & Hunting Detectors (1)

[T1190] PHP2Shell Hunt QueryStandalone Rule
index=web_logs (http_method="POST" OR http_method="PUT" OR http_method="PATCH") uri_path="*.php" http_content_type="*multipart/form-data*"
| stats count earliest(_time) as first_seen latest(_time) as last_seen values(uri_path) as targeted_uris by src_ip, status
| where count > 5
| convert ctime(first_seen) ctime(last_seen)
| sort - count

Verified Indicators of Compromise (3)

Indicators of Compromise (IOCs)
3 Identified
CONFIGURATION DIRECTIVEsession.upload_progress.enabled
HTTP HEADERContent-Type: multipart/form-data
PHP FUNCTIONrequest_parse_body()