Skip to content

Stored XSS Vulnerability in Markdown Editor

High
SchrodingersGat published GHSA-wp3m-jhgv-rhqr Oct 6, 2024

Package

inventree

Affected versions

<0.16.5

Patched versions

0.16.5,0.17.0

Description

Impact

In affected version(s) of InvenTree it is possible for a registered user to store XSS in markdown notes fields, which are then displayed to other logged in users who visit the same page.

Mitigations

The vulnerability has been addressed as follows:

  • HTML sanitization has been enabled in the front-end markdown rendering library - easymde
  • Stored markdown is also validated on the backend, to ensure that malicious markdown is not stored in the database

Patches

The following version of InvenTree have been patched against this vulnerability:

  • 0.17.0
  • 0.16.5

Workarounds

There are no workarounds, an update is required to get the new validation functions.

References

Thanks to @febin0x10 for identifying this vulnerability and reporting it to us as per our security policy.

Severity

High

CVSS overall score

This score calculates overall vulnerability severity from 0 to 10 and is based on the Common Vulnerability Scoring System (CVSS).
/ 10

CVSS v3 base metrics

Attack vector
Network
Attack complexity
Low
Privileges required
Low
User interaction
Required
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
None

CVSS v3 base metrics

Attack vector: More severe the more the remote (logically and physically) an attacker can be in order to exploit the vulnerability.
Attack complexity: More severe for the least complex attacks.
Privileges required: More severe if no privileges are required.
User interaction: More severe when no user interaction is required.
Scope: More severe when a scope change occurs, e.g. one vulnerable component impacts resources in components beyond its security scope.
Confidentiality: More severe when loss of data confidentiality is highest, measuring the level of data access available to an unauthorized user.
Integrity: More severe when loss of data integrity is the highest, measuring the consequence of data modification possible by an unauthorized user.
Availability: More severe when the loss of impacted component availability is highest.
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:N

CVE ID

CVE-2024-47610

Weaknesses

No CWEs

Credits