Summary
Insufficient HTML Sanitization
Patches
- The issue is addressed in the upcoming
0.8.0release - This fix will also be back-ported to the
0.7.xbranch, applied to the0.7.2release
Workarounds
There are no workarounds for this issue, users should upgrade to a patched version.
References
- https://huntr.dev/bounties/4cae8442-c042-43c2-ad89-6f666eaf3d57/
- https://huntr.dev/bounties/9d640ef2-c52c-4106-b043-f7497d577078/
- https://huntr.dev/bounties/b114e82f-6c02-485b-82ea-e242f89169c2/
- https://huntr.dev/bounties/22783cd3-1b2c-48fc-b31f-03b53c86da0b/
Thank you @saharshtapi for bringing this issue to our attention and giving pointers for fixing them.
For more information
If you have any questions or comments about this advisory:
- Open an issue in github
- Email us at [email protected]
Impact
Affected versions can have malicious javascript code injected into the users browser by other authenticated users, as data fields retrieved from the database are not properly sanitized before displaying in various front-end views.
The problem here stems from multiple issues:
- Insufficient database sanitation on multiple fields allows injection of un-sanitized HTML
- Lack of HTML escaping when rendering data on the front end
The attack vector here is limited, as only authenticated users are able to write data to the database, for it to be subsequently rendered on the front-end. However, it is a vulnerability that the InvenTree development team takes seriously.
Affected versions
Security releases
Kodem intelligence
Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.
Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.
Already deployed Kodem?
See it in your environmentNew to Kodem? Get a demo →Remediation advice
The proposed patch for this vulnerability is prevents injection of un-escaped fields into front-end UI elements.
A future patch will also address sanitization of database fields on the "back end", however this will require a much larger effort to refactor multiple database tables.
Frequently Asked Questions
- What is GHSA-RM89-9G65-4FFR? GHSA-RM89-9G65-4FFR is a high-severity security vulnerability in inventree (pip), affecting versions < 0.7.2. It is fixed in 0.7.2.
- Which versions of inventree are affected by GHSA-RM89-9G65-4FFR? inventree (pip) versions < 0.7.2 is affected.
- Is there a fix for GHSA-RM89-9G65-4FFR? Yes. GHSA-RM89-9G65-4FFR is fixed in 0.7.2. Upgrade to this version or later.
- Is GHSA-RM89-9G65-4FFR exploitable, and should I be worried? Whether GHSA-RM89-9G65-4FFR is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
- What actually determines whether GHSA-RM89-9G65-4FFR is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
- How do I fix GHSA-RM89-9G65-4FFR? Upgrade
inventreeto 0.7.2 or later.