Skip to content

CVE-2025-42944: Unauthenticated Java Deserialization RCE in SAP NetWeaver AS Java (RMI-P4)

HERMES

HERMES THREAT SCORE & ERP CORE EXPOSURE

Target: SAP NetWeaver Application Server Java 7.50 (RMI-P4)
Confidence: 98%
96 / 100
CRITICAL

Measures real-world operational relevance, exploit weaponization, and active threat posture.

Dimension Breakdown
Exploitability 20 / 20
Threat Activity 18 / 20
Weaponization 19 / 20
Exposure 18 / 20
Prevalence 19 / 20
Impact 20 / 20
Exploit Maturity 18 / 20
Attack Chain Potential 20 / 20
⚖️ Divergence & Operational Rationale

Hermes assesses CVE-2025-42944 at a critical HTS of 96 (CRITICAL SEVERITY). This unauthenticated deserialization flaw on port P4 (5xx04) enables arbitrary code execution with administrative rights (<sid>adm), allowing immediate lateral movement to core financial databases and complete enterprise ERP compromise.

🕸️ Connected Knowledge Graph & Provenance

CVE-2025-42944: Unauthenticated Java Deserialization RCE in SAP NetWeaver AS Java (RMI-P4)VULNERABILITY

Connected Nodes: 2
Active Relationships (Outgoing)
→ affectsPRODUCTMicrosoft Windows & Windows Server
98% VERY_HIGH

Software platform affected by security vulnerabilities and agentic attack patterns.

🔍 Why is this related? (Evidence & Provenance)

“Confirmed security vulnerability in Microsoft Windows & Windows Server documented in Hermes dossier.”

Supporting Verified Evidence:
→ usesATTACK TECHNIQUET1059: Command and Scripting Interpreter
90% VERY_HIGH

Adversaries abuse command and script interpreters (Bash, Python, PowerShell) to execute arbitrary commands.

🔍 Why is this related? (Evidence & Provenance)

“Attack execution telemetry aligns with MITRE ATT&CK technique T1059.”

Supporting Verified Evidence:
ParameterTechnical SpecificationOperational Impact
CVE IdentifierCVE-2025-42944Official NVD / MITRE record
Associated CWECWE-502: Deserialization of Untrusted DataUnrestricted Java deserialization over P4 protocol
CVSS v3.1 Score10.0 CRITICALCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H
CVSS v4.0 Score9.8 CRITICALCVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H
Applicable CPEscpe:2.3:a:sap:netweaver_application_server_java:7.50:*:*:*:*:*:*:*Enterprise SAP NetWeaver Java application servers
Affected VersionsSAP NetWeaver SERVERCORE 7.50Any SAP NetWeaver Java deployment exposing P4 ports
Fixed VersionsSAP Notes 3634501 and 3660659 (August 2025)SAP Security Patch Day updates

  • CISA KEV: Not currently listed in KEV (actively monitored by threat hunting teams).
  • EPSS Score: 0.02893 (Percentile: 86.1%).
  • Operational Status: Weaponization verified; public exploit scripts target P4 default ports (50004, 50104, 50204).
  • PoC & Weaponization: Java gadget chains tailored to the SAP classpath injected directly into the initial P4 handshake.
  • Access Conditions: Pre-authentication; direct network access to P4 port (default 5<instance>04/tcp); low complexity.

  • Threat Actors: Industrial espionage APTs, ransomware affiliates (LockBit, BlackCat/ALPHV), and initial access brokers.
  • Observed Campaigns: Wide internet and internal network scanning probing for exposed SAP P4 daemons.
  • Associated Malware: SAP webshells, Java memory implants, and HANA database credential dumpers.
  • Exploitation Timeline: Released on August 12, 2025, with prompt technical analysis from ERP cybersecurity firms.

  • Suspicious P4 Traffic: Influx of serialized Java byte sequences starting with 0xACED0005 directed to ports 50004-59904.
  • Anomalous Process Lineage: SAP Java runner processes (jstart, jlaunch) spawning shell interpreters (/bin/sh, /bin/bash, powershell.exe).
title: Command Execution from SAP NetWeaver Process (CVE-2025-42944)
id: c4e78a22-4294-4d91-8822-112233445566
status: test
description: Detects interactive shells or download utilities spawned by SAP Java application server processes
references:
- https://me.sap.com/notes/3634501
author: Hermes Codex Research
date: 2026-09-10
logsource:
category: process_creation
product: linux
detection:
selection:
ParentProcessName|endswith:
- '/jstart'
- '/jlaunch'
Image|endswith:
- '/sh'
- '/bash'
- '/python'
- '/perl'
- '/curl'
- '/wget'
condition: selection
falsepositives:
- Legitimate SAP maintenance scripts invoked during administrative maintenance windows
level: critical
rule Exploit_SAP_P4_Deserialization_CVE_2025_42944 {
meta:
description = "Detects P4 exploit packets containing Java serialization stream headers"
author = "Hermes Codex Research"
date = "2026-09-10"
reference = "CVE-2025-42944"
strings:
$p4_magic = { 50 34 00 00 } // P4 protocol header
$java_ser = { AC ED 00 05 } // Java Serialization Header
$gadget1 = "org.apache.commons.collections" ascii
$gadget2 = "java.lang.reflect.InvocationHandler" ascii
condition:
($p4_magic at 0 or $java_ser) and ($gadget1 or $gadget2)
}
alert tcp $EXTERNAL_NET any -> $SAP_SERVERS [50004:59904] (msg:"HERMES - SAP NetWeaver P4 Java Deserialization Exploit (CVE-2025-42944)"; flow:to_server,established; content:"|AC ED 00 05|"; classtype:attempted-admin; sid:202542944; rev:1;)
  • SAP Security Logs: Review traces in /usr/sap/<SID>/<Instance>/j2ee/cluster/server0/log/defaultTrace*.trc.
  • SAP Audit Log (SM20): Monitor unauthorized P4 access and abnormal dynamic class loading events.
  • MITRE ATT&CK: T1190 (Exploit Public-Facing Application), T1059 (Command and Scripting Interpreter), T1068 (Exploitation for Privilege Escalation), T1083 (File and Directory Discovery).

  1. Apply Official SAP Notes: Deploy SAP Notes 3634501 and 3660659 using Software Update Manager (SUM).
  2. Full SAP Instance Restart: Restart the Java application server (stopsap followed by startsap) to ensure updated classes take effect.
  3. Isolate P4 Protocol Ports: Strictly restrict TCP ports 5xx04 and 5xx08 at boundary firewalls to internal management networks.
  4. Transition to P4S: Enforce TLS encryption and mutual certificate authentication for all internal P4 communications.
  5. System Integrity Audit: Search for unexpected .jsp files or modified binaries in /tmp and /usr/sap/<SID>/tmp.

”What happens if this vulnerability is exploited in an enterprise?”

Section titled “”What happens if this vulnerability is exploited in an enterprise?””
  1. Initial Unauthenticated P4 Probe: The attacker targets TCP port 50004 on an exposed enterprise SAP NetWeaver AS Java server without credentials.
  2. Immediate Java Deserialization: The adversary sends a crafted serialized payload. The unpatched P4 dispatcher deserializes the byte stream, executing shell commands with sapadm or <sid>adm privileges.
  3. Application Layer Persistence: The threat actor writes a stealthy Java webshell into the public web root, establishing persistent C2 communications.
  4. HANA Database Takeover: Utilizing local command line database utilities (hdbsql) and stored connection keys (hdbuserstore), the attacker accesses core ERP data including financial records and payrolls.
  5. Complete Enterprise Interruption: The attacker exfiltrates proprietary enterprise data, destroys live backups, and encrypts storage volumes, demanding tens of millions in ransom to restore operations.