Skip to content

GHSA-p6qx-ghxm-389h CVE-2026-35163 PYSEC-2026-2688

OctoPrint has XSS in its Suppressed Command Notifications

Medium PyPI
Severity
0.0 / 10
Medium · CVSS 4.0
Exploit chance (EPSS)
0.20%
Chance of exploitation in the next 30 days. Higher than 9.81% of scored vulnerabilities.
Known exploited
No
Not in CISA's catalog
Weakness
CWE-80 Improper Neutralization of Script-Related HTML Tags in a Web Page (Basic XSS)
Fix
1.11.8
Upgrade octoprint to this version or later

Description

Impact

OctoPrint versions up to and including 1.11.7 as well as 2.0.0rc1 and 2.0.0rc2 are affected by a vulnerability that allows injection of arbitrary HTML and JavaScript into Suppressed Command notifications popups generated by the printer.

An attacker who successfully convinces a victim to print a specially crafted file could exploit this issue to disrupt ongoing prints, extract information (including sensitive configuration settings, if the targeted user has the necessary permissions for that), or perform other actions on behalf of the targeted user within the OctoPrint instance.

Patches

The vulnerability has been patched in version 1.11.8 and 2.0.0rc3.

Workaround

OctoPrint administrators can mitigate the risk by disabling popups:

  • for Action Command notifications, set OctoPrint Settings -> Serial Connection -> Behaviour -> Sanity Checking -> Display notifications for suppressed commands to Never show notifications

It is also strongly recommended to ensure that files being printed originate from trusted sources, and, whenever possible, are sliced with an application's own slicer.

Credits

This vulnerability was discovered and responsibly disclosed to OctoPrint by Jacopo Tediosi.

Timeline

2026-03-18: Report received 2026-04-01: Report verified 2026-04-01: Fix ready for 2.0.0 2026-06-22: Fix backported to 1.11.x 2026-06-23: Fix released with 1.11.8 and 2.0.0rc3

Affected versions

PyPI

PackageVulnerableFixed in
octoprint
< 1.11.8
1.11.8
octoprint
>= 2.0.0rc1, < 2.0.0rc3
2.0.0rc3
octoprint
< 1.11.8
>= 2.0.0rc1, < 2.0.0rc3
1.11.8
2.0.0rc3

How to fix

Move to the fixed version or later with your package manager, update the lockfile, and run your tests. If the package only arrives through another dependency, upgrade that dependency first. If none of its releases pulls a fixed version yet, force the version with your package manager's override.

octoprint PyPI → 1.11.8

pip
pip install --upgrade "octoprint>=1.11.8"
poetry
poetry add "octoprint>=1.11.8"
uv
uv add "octoprint>=1.11.8"

Severity breakdown

CVSS 4.0 0.0

CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:A/VC:L/VI:L/VA:L/SC:L/SI:L/SA:N

Attack vector
Local
Attack complexity
Low
Attack requirements
None
Privileges required
None
User interaction
Active
Confidentiality (vulnerable system)
Low
Integrity (vulnerable system)
Low
Availability (vulnerable system)
Low
Confidentiality (subsequent systems)
Low
Integrity (subsequent systems)
Low
Availability (subsequent systems)
None

Weakness

CWE-80: Improper Neutralization of Script-Related HTML Tags in a Web Page (Basic XSS)

The product receives input from an upstream component, but it does not neutralize or incorrectly neutralizes special characters such as "<", ">", and "&" that could be interpreted as web-scripting elements when they are sent to a downstream component that processes web pages.

How to prevent it
  • Implementation: Carefully check each input parameter against a rigorous positive specification (allowlist) defining the specific characters and format allowed. All input should be neutralized, not just parameters that the user is supposed to specify, but all data in the request, including hidden fields, cookies, headers, the URL itself, and so forth. A common mistake that leads to continuing XSS vulnerabilities is to validate only fields that are expected to be redisplayed by the site. We often encounter data from the request that is reflected by the application server or the application that the development team did not anticipate. Also, a field that is not currently reflected may be used by a future developer. Therefore, validating ALL parts of the HTTP request is recommended.
  • Implementation: Use and specify an output encoding that can be handled by the downstream component that is reading the output. Common encodings include ISO-8859-1, UTF-7, and UTF-8. When an encoding is not specified, a downstream component may choose a different encoding, either by assuming a default encoding or automatically inferring which encoding is being used, which can be erroneous. When the encodings are inconsistent, the downstream component might treat some character or byte sequences as special, even if they are not special in the original encoding. Attackers might then be able to exploit this discrepancy and conduct injection attacks; they even might be able to bypass protection mechanisms that assume the original encoding is also being used by the downstream component. The problem of inconsistent output encodings often arises in web pages. If an encoding is not specified in an HTTP header, web browsers often guess about which encoding is being used. This can open up the browser to subtle XSS attacks.
  • Implementation: With Struts, write all data from form beans with the bean's filter attribute set to true.
  • Implementation: To help mitigate XSS attacks against the user's session cookie, set the session cookie to be HttpOnly. In browsers that support the HttpOnly feature (such as more recent versions of Internet Explorer and Firefox), this attribute can prevent the user's session cookie from being accessible to malicious client-side scripts that use document.cookie. This is not a complete solution, since HttpOnly is not supported by all browsers. More importantly, XmlHttpRequest and other powerful browser technologies provide read access to HTTP headers, including the Set-Cookie header in which the HttpOnly flag is set.

References

Timeline

  1. Published
  2. Last updated by the source
  3. Latest EPSS score
AdvisorySeverityWhy it's related
GHSA-j4h9-pm27-4rfw
OctoPrint has possible file exfiltration via query parameters on upload endpoints
High Also affects octoprint
GHSA-xg4x-w2j3-57h6
OctoPrint has Timing Side-Channel Vulnerability in API Key Authentication
Medium Also affects octoprint
GHSA-crvm-xjhm-9h29
OctoPrint vulnerable to XSS in Action Commands Notification and Prompt
Medium Also affects octoprint
GHSA-49mj-x8jp-qvfc
OctoPrint is Vulnerable to RCE Attacks via Unsanitized Filename in File Upload
High Also affects octoprint
GHSA-9wj4-8h85-pgrw
OctoPrint Vulnerable to Denial of Service through malformed HTTP request in OctoPrint
Medium Also affects octoprint
GHSA-m9jh-jf9h-x3h2
OctoPrint vulnerable to possible file extraction via upload endpoints
Medium Also affects octoprint
GHSA-qw93-h6pf-226x
OctoPrint Authenticated Reverse Proxy Page Authentication Bypass
Medium Also affects octoprint
GHSA-cc6x-8cc7-9953
OctoPrint has API key access in settings without reauthentication
Medium Also affects octoprint
Is this in your code?

MergeHarbor checks every repository's dependencies against this database, ranks what matters by exploitability and reachability, routes it to the owning team and opens the fix pull request.

Check your repos with MergeHarbor