Skip to content
CVE-2026-111058 Splunk · SPL

Detect Mercury Unauthenticated RCE via /api/kernels (CVE-2026-111058) in Splunk

Detects exploitation of CVE-2026-111058, a missing-authorization (CWE-862) vulnerability in mljar Mercury <= 3.2.5 that exposes the Jupyter-style /api/kernels endpoint without authentication. An unauthenticated attacker can create a kernel and submit arbitrary code for execution over the kernel WebSocket/channels interface, resulting in remote code execution on the host running the Mercury app server. Detection focuses on unauthenticated HTTP requests to /api/kernels (POST to create kernels, GET to enumerate), rapid kernel-create activity, and suspicious child processes spawned by the Mercury/python server process consistent with code execution inside a kernel.

MITRE ATT&CK

Tactic
Initial Access Execution

SPL Detection Query

Splunk (SPL)
spl
``` df00tech DF00-630fa45508 · https://df00tech.com/detections/CVE-2026-111058 · licence: https://df00tech.com/detections/licence ```
index=web (sourcetype="ms:iis" OR sourcetype="nginx:plus:kv" OR sourcetype="access_combined")
(uri_path="/api/kernels" OR uri_path="/api/kernels/*")
(method="POST" OR method="GET" OR method="DELETE")
(status=200 OR status=201 OR status=101)
| eval noauth=if(isnull(user) OR user="-" OR user="", 1, 0)
| where noauth=1
| stats count AS requests, values(method) AS methods, values(uri_path) AS paths, min(_time) AS first_seen, max(_time) AS last_seen BY src_ip, dest_ip, http_user_agent
| where requests>=1
| sort - requests
critical severity medium confidence

Identifies unauthenticated requests to the Mercury /api/kernels endpoint across IIS/nginx/Apache access logs, aggregating kernel-create and enumeration behavior per source IP.

Data Sources

Web Server LogsReverse Proxy LogsIIS Logs

Required Sourcetypes

ms:iisnginx:plus:kvaccess_combined

False Positives & Tuning

  • Monitoring/uptime systems polling /api/kernels anonymously.
  • Trusted internal lab deployments that deliberately run Mercury without authentication.
  • Reverse-proxy health probes against the API path.

Other platforms for CVE-2026-111058


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 further down this page.

  1. Test 1 Unauthenticated kernel creation via /api/kernels

    Expected signal: Web/proxy log entry: POST /api/kernels with 201 status and no authenticated username.

  2. Test 2 Enumerate active kernels anonymously

    Expected signal: Web/proxy log entry: GET /api/kernels with 200 status and no authenticated username.

  3. Test 3 Code execution inside kernel spawns shell

    Expected signal: Process creation event: /bin/sh (and id/whoami) with parent process python3.


Response Playbook

Triage

  1. Confirm the Mercury version in use (check pip show mercury / the app server banner); versions <= 3.2.5 are vulnerable to CVE-2026-111058.
  2. Review web/proxy logs for unauthenticated POST/GET requests to /api/kernels from the flagged source IP, and correlate timestamps with any kernel WebSocket (/api/kernels/<id>/channels) upgrades.
  3. Inspect process telemetry on the Mercury host for child processes (shells, curl/wget, whoami/id) spawned by the python/mercury server process around the request time.
  4. Determine whether the source IP is an expected monitoring/internal system or an unknown external attacker.

Containment

  1. Block the attacking source IP at the WAF/firewall and restrict /api/kernels to authenticated internal users only.
  2. Isolate the Mercury host from the network if post-exploitation process activity is confirmed.
  3. Upgrade Mercury to 3.2.6 or later, which adds authorization enforcement on the kernels API.

Evidence Collection

  1. Preserve web/reverse-proxy access logs covering requests to /api/kernels and /api/kernels/*/channels.
  2. Capture process creation events, command lines, and network connections from the Mercury host for the exploitation window.
  3. Snapshot the host memory and the Mercury working directory / notebook files before remediation.

Escalation Criteria

  • !Escalate to incident response if a child process (shell, downloader, or recon command) was spawned by the Mercury server process following an unauthenticated /api/kernels request.
  • !Escalate if outbound C2-like connections or new persistence mechanisms are observed on the Mercury host after the suspicious requests.

Investigation Guide

Forensic Artifacts

  • >Web/reverse-proxy access log entries for /api/kernels and /api/kernels/<id>/channels
  • >Child processes and command lines parented to the python/mercury server process
  • >Mercury server application logs showing kernel create/execute events without an associated authenticated session

Tuning Guidance

If Mercury is intentionally run without authentication inside a trusted network segment, scope the detection to external source IPs or correlate strictly with the post-request suspicious-child-process signal to reduce noise. Baseline known monitoring/uptime source IPs and exclude them. Raise confidence to high when the network request is followed within minutes by a shell or downloader spawned by the Mercury process.


Hunting Queries

Hunt for all unauthenticated access to the Mercury kernels API across web logs, grouped by source IP and method.

Hunting — KQL
kql
// df00tech DF00-630fa45508 · https://df00tech.com/detections/CVE-2026-111058 · licence: https://df00tech.com/detections/licence
W3CIISLog | where csUriStem startswith "/api/kernels" | where isempty(csUsername) or csUsername == "-" | summarize count() by cIP, csMethod, csUriStem
Hunting — SPL
spl
``` df00tech DF00-630fa45508 · https://df00tech.com/detections/CVE-2026-111058 · licence: https://df00tech.com/detections/licence ```
index=web uri_path="/api/kernels*" (user="-" OR user="") | stats count by src_ip, method, uri_path

Atomic Red Team Tests

Test 1 Unauthenticated kernel creation via /api/kernels
linux

Simulates an attacker creating a Jupyter-style kernel on a Mercury instance without authentication.

Command

bash
curl -s -X POST http://localhost:8000/api/kernels -H 'Content-Type: application/json' -d '{"name":"python3"}'

Cleanup

bash
KID=$(curl -s http://localhost:8000/api/kernels | python3 -c 'import sys,json;print(json.load(sys.stdin)[0]["id"])' 2>/dev/null); [ -n "$KID" ] && curl -s -X DELETE http://localhost:8000/api/kernels/$KID

Expected Telemetry

Web/proxy log entry: POST /api/kernels with 201 status and no authenticated username.

Expected Detection

KQL/SPL/AQL rules flag the unauthenticated POST to /api/kernels.

Test 2 Enumerate active kernels anonymously
linux

Simulates attacker reconnaissance of existing kernels via an unauthenticated GET request.

Command

bash
curl -s http://localhost:8000/api/kernels

Cleanup

bash
echo 'no cleanup required'

Expected Telemetry

Web/proxy log entry: GET /api/kernels with 200 status and no authenticated username.

Expected Detection

Web-log rules flag the unauthenticated GET to /api/kernels.

Test 3 Code execution inside kernel spawns shell
linux

Simulates post-exploitation code execution where submitted kernel code shells out to a recon command, producing a suspicious child process of the Mercury/python server.

Command

bash
python3 -c "import subprocess; subprocess.run(['/bin/sh','-c','id; whoami'])"

Cleanup

bash
echo 'no cleanup required'

Expected Telemetry

Process creation event: /bin/sh (and id/whoami) with parent process python3.

Expected Detection

Elastic EQL and CrowdStrike CQL rules flag the suspicious child process parented to python/mercury.

Related Detections