CVE-2026-27629

Source
https://cve.org/CVERecord?id=CVE-2026-27629
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-27629.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2026-27629
Aliases
  • GHSA-cx85-vr3q-9x4m
Published
2026-02-25T02:48:41.934Z
Modified
2026-03-01T08:12:58.025952Z
Severity
  • 5.9 (Medium) CVSS_V3 - CVSS:3.1/AV:A/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:L CVSS Calculator
Summary
InvenTree Vulnerable to Server Side Template Injection (SSTI)
Details

InvenTree is an Open Source Inventory Management System. Prior to version 1.2.3, insecure server-side templates can be hijacked to expose secure information to the client. When generating custom batch codes, the InvenTree server makes use of a customizable jinja2 template, which can be modified by a staff user to exfiltrate sensitive information or perform code execution on the server. This issue requires access by a user with granted staff permissions, followed by a request to generate a custom batch code via the API. Once the template has been modified in a malicious manner, the API call to generate a new batch code could be made by other users, and the template code will be executed with their user context. The code has been patched to ensure that all template generation is performed within a secure sandboxed context. This issue has been addressed in version 1.2.3, and any versions from 1.3.0 onwards. Some workarounds are available. The batch code template is a configurable global setting which can be adjusted via any user with staff access. To prevent this setting from being edited, it can be overridden at a system level to a default value, preventing it from being edited. This requires system administrator access, and cannot be changed from the client side once the server is running. It is recommended that for InvenTree installations prior to 1.2.3 the STOCK_BATCH_CODE_TEMPLATE and PART_NAME_FORMAT global settings are overridden at the system level to prevent editing.

Database specific
{
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/27xxx/CVE-2026-27629.json",
    "cna_assigner": "GitHub_M",
    "cwe_ids": [
        "CWE-1336"
    ]
}
References

Affected packages

Git / github.com/inventree/inventree

Affected ranges

Type
GIT
Repo
https://github.com/inventree/inventree
Events
Introduced
0 Unknown introduced commit / All previous commits are affected
Fixed

Affected versions

0.*
0.0.10
0.0.11
0.0.12
0.0.3
0.0.6
0.0.8
0.0.9
0.1.0
0.1.1
0.1.2
0.1.4
0.1.5
0.1.6
0.1.7
0.1.8
0.10.0
0.11.0
0.12.0
0.13.0
0.2.0
0.2.1
0.2.2
0.2.3
0.2.4
0.3.0
0.4.0
0.8.0
0.9.0
1.*
1.2.0
1.2.1
1.2.2
v0.*
v0.0.11
v0.0.5
v0.0.7
v0.1.3
v0.7.0

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-27629.json"