GHSA-vx3h-qwqw-r2wq: Inventree Inventree Server-Side Request Forgery Vulnerability Vulnerability
MODERATEGHSA-vx3h-qwqw-r2wq is a MODERATE (CVSS 4.3) inventree server-side request forgery vulnerability vulnerability (CWE-918: Server-Side Request Forgery (SSRF)) affecting Inventree libraries in the PyPI ecosystem. The issue involves inventree server-side request forgery vulnerability exposes server port/internal ip. Remediation is available by upgrading affected packages to version 0.16.5.
GHSA-vx3h-qwqw-r2wq at a Glance
Security Impact
CVSS: 4.3
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N).
How to Fix GHSA-vx3h-qwqw-r2wq
To remediate this vulnerability, upgrade all affected Inventree dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
pip install inventree>=0.16.5
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
pip show inventree
How to Check if You Are Affected
To determine whether your Python environment is affected by GHSA-vx3h-qwqw-r2wq, inspect your installed packages using pip:
pip show inventree
Analyze the terminal output to locate any version of Inventree in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.16.5), your application is affected.
Note: The pip show inventree command checks currently installed packages in your active Python environment.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-918: Server-Side Request Forgery (SSRF), where the web server receives a url or similar request from an upstream component and retrieves the contents of this url, but it does not sufficiently ensure that the request is being sent to the expected destination. In Inventree, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
GHSA-vx3h-qwqw-r2wq Affected Inventree Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
inventree
|
PyPI |
< 0.16.5
|
0.16.5
|
References
Frequently Asked Questions
What is GHSA-vx3h-qwqw-r2wq?
Which Inventree versions are affected?
What version fixes GHSA-vx3h-qwqw-r2wq?
Is inventree affected?
What is the CVSS score of GHSA-vx3h-qwqw-r2wq?
What CWE is associated with GHSA-vx3h-qwqw-r2wq?
How can I check PyPI dependencies for GHSA-vx3h-qwqw-r2wq?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-vx3h-qwqw-r2wq",
"modified" : "2024-10-02T17:58:44Z",
"published" : "2024-10-02T17:58:44Z",
"aliases" : [ ],
"summary" : "Inventree Server-Side Request Forgery vulnerability exposes server port/internal IP",
"details" : "### Impact\n\nThe \"download image from remote URL\" feature can be abused by a malicious actor to potentially extract information about server side resources. Submitting a crafted URL (in place of a valid image) can raise a server side error, which is reported back to the user. \n\nThis error message may contain sensitive information about the server side request, including information about the availability of the remote resource.\n\n### Patches\n\nThe solution to this vulnerability is to prevent the server from returning any specific information about the observed exception. Instead, a generic error message is returned to the client.\n\nThis patch has been applied to the upcoming 0.17.0 release, and also back-ported to the 0.16.5 stable release.\n\n### Workarounds\n\nTo avoid this issue with unpatched versions, the \"download image from remote URL\" feature can be disabled in InvenTree, preventing users from accessing this information. \n\n### References\n\nThanks to @febin0x10 for identifying this vulnerability and reporting it to us as per our security policy.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N"
}, {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "PyPI",
"name" : "inventree"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "0.16.5"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/inventree/InvenTree/security/advisories/GHSA-vx3h-qwqw-r2wq"
}, {
"type" : "WEB",
"url" : "https://github.com/inventree/InvenTree/commit/5759b60a48e7e178fb417a900ed543f29dc5dc86"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/inventree/InvenTree"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-918" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2024-10-02T17:58:44Z",
"nvd_published_at" : null
}
}