CVE-2021-26828 Splunk · SPL

Detect CVE-2021-26828: OpenPLC ScadaBR Unrestricted File Upload RCE in Splunk

Detects exploitation of CVE-2021-26828, an unrestricted file upload vulnerability in OpenPLC ScadaBR that allows authenticated attackers to upload files with dangerous types (e.g., JSP, PHP, WAR) to the server, leading to remote code execution. ScadaBR is a SCADA/HMI web application widely used in industrial control systems. This vulnerability is actively exploited in the wild and listed in CISA KEV.

MITRE ATT&CK

Tactic
Initial Access Execution Persistence

SPL Detection Query

Splunk (SPL)
spl
index=* sourcetype IN ("WinEventLog:Security", "WinEventLog:Microsoft-Windows-Sysmon/Operational", "linux_secure", "access_combined", "tomcat_access")
| eval suspicious_upload=if(
    (sourcetype="access_combined" OR sourcetype="tomcat_access") AND
    (method="POST") AND
    (uri_path LIKE "%/upload%" OR uri_path LIKE "%/images%" OR uri_path LIKE "%/graphicViews%") AND
    match(uri_path, "\.(jsp|jspx|php|war|sh|py|pl|aspx)$"),
    "WebShell Upload Attempt", null()
)
| eval suspicious_exec=if(
    (sourcetype="WinEventLog:Microsoft-Windows-Sysmon/Operational" AND EventCode=1) AND
    (ParentImage LIKE "%java%" OR ParentImage LIKE "%tomcat%") AND
    (CommandLine LIKE "%cmd%" OR CommandLine LIKE "%powershell%" OR CommandLine LIKE "%bash%" OR CommandLine LIKE "%whoami%"),
    "Shell Spawned from Java Process", null()
)
| where isnotnull(suspicious_upload) OR isnotnull(suspicious_exec)
| eval detection_type=coalesce(suspicious_upload, suspicious_exec)
| table _time, host, src_ip, dest_ip, uri_path, method, CommandLine, ParentImage, detection_type
| sort -_time
critical severity high confidence

Detects POST requests uploading dangerous file types to ScadaBR web paths and Java/Tomcat spawning command shells indicative of web shell execution following CVE-2021-26828 exploitation.

Data Sources

Splunk Web LogsSysmon for WindowsLinux SyslogTomcat Access Logs

Required Sourcetypes

access_combinedtomcat_accessWinEventLog:Microsoft-Windows-Sysmon/Operationallinux_secure

False Positives & Tuning

  • Authorized Tomcat application deployments by system administrators uploading WAR files
  • Legitimate ScadaBR plugin or module installations via the web interface
  • Development environments where engineers upload custom JSP views for HMI customization
  • Penetration testers conducting authorized assessments of ICS/SCADA infrastructure

Other platforms for CVE-2021-26828


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 1Upload JSP Web Shell to ScadaBR Upload Endpoint

    Expected signal: HTTP POST to /ScadaBR/upload.shtm with multipart form data containing .jsp file; Tomcat access log shows 200 response; file creation event for .jsp file in webapps directory

  2. Test 2Execute OS Command via Uploaded JSP Web Shell

    Expected signal: Java process (Tomcat JVM) spawning child process for id, whoami, cat commands; Sysmon Event ID 1 with ParentImage containing java; process command line containing /etc/passwd

  3. Test 3Establish Reverse Shell from ScadaBR Server via Web Shell

    Expected signal: Java process spawning bash with /dev/tcp redirect; outbound TCP connection from ScadaBR host to ATTACKER_IP:4444; network flow event with non-standard destination port from Java process

  4. Test 4Upload PHP Web Shell as Image File Bypass

    Expected signal: POST request to upload endpoint with PHP file disguised as image; file creation event showing PHP content in webapps directory; Content-Type mismatch between declared image/jpeg and actual PHP content

Unlock Pro Content

Get the full detection package for CVE-2021-26828 including response playbook, investigation guide, and atomic red team tests.

Response PlaybookInvestigation GuideHunting QueriesAtomic Red Team TestsTuning Guidance

Related Detections