Cyber Posture

CVE-2026-35477

Medium

Published: 08 April 2026

Published
08 April 2026
Modified
20 April 2026
KEV Added
Patch
CVSS Score 5.5 CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:C/C:L/I:L/A:N
EPSS Score 0.0003 8.9th percentile
Risk Priority 11 60% EPSS · 20% KEV · 20% CVSS

Summary

CVE-2026-35477 is a medium-severity Improper Neutralization of Special Elements Used in a Template Engine (CWE-1336) vulnerability in Inventree Project Inventree. Its CVSS base score is 5.5 (Medium).

Operationally, exploitation aligns with the MITRE ATT&CK technique Exploit Public-Facing Application (T1190); ranked at the 8.9th percentile by exploit likelihood (below the median); it is not currently listed in the CISA KEV catalog.

The strongest mitigations our analysis identified are NIST 800-53 AC-6 (Least Privilege) and SI-2 (Flaw Remediation).

Threat & Defense at a Glance

What attackers do: exploitation maps to Exploit Public-Facing Application (T1190) and 1 other technique. What defenders deploy: see the NIST 800-53 controls recommended below.
Threat & Defense Details

Mitigating Controls (NIST 800-53 r5)AI

prevent

Flaw remediation requires timely patching to versions 1.2.7 or 1.3.0, directly addressing the incomplete sandboxing fix in the template renderer.

prevent

Least privilege restricts settings access to only essential staff users, preventing high-privilege exploitation of the template crafting capability.

prevent

Information input validation ensures malicious Jinja2 templates in PART_NAME_FORMAT are detected and rejected before rendering, though discrepancies between validation and production require comprehensive implementation.

MITRE ATT&CK Enterprise TechniquesAI

T1190 Exploit Public-Facing Application Initial Access
Adversaries may attempt to exploit a weakness in an Internet-facing host or system to initially access a network.
T1059.006 Python Execution
Adversaries may abuse Python commands and scripts for execution.
Why these techniques?

The vulnerability is a server-side template injection (SSTI) in the Jinja2 renderer allowing a high-privilege staff user to bypass sandboxing and execute arbitrary Python code during template rendering, directly enabling T1190 (Exploit Public-Facing Application) for the web app flaw and T1059.006 (Python) for the resulting code execution.

Confidence: HIGH · MITRE ATT&CK Enterprise v18.1

NVD Description

InvenTree is an Open Source Inventory Management System. From 1.2.3 to 1.2.6, the fix for CVE-2026-27629 upgraded the PART_NAME_FORMAT validator to use jinja2.sandbox.SandboxedEnvironment. However, the actual renderer in part/helpers.py was not updated and still uses the non-sandboxed jinja2.Environment. Additionally, the…

more

validator uses a dummy Part instance with pk=None, which allows conditional template expressions to behave differently during validation versus production rendering. A staff user with settings access can craft a template that passes validation but executes arbitrary code during rendering. This issue requires access by a user with granted staff permissions. This vulnerability is fixed in 1.2.7 and 1.3.0.

Deeper analysisAI

CVE-2026-35477 is a vulnerability in InvenTree, an open-source inventory management system, affecting versions 1.2.3 through 1.2.6. It arises from an incomplete remediation of CVE-2026-27629 in the PART_NAME_FORMAT feature, where the validator was updated to use jinja2.sandbox.SandboxedEnvironment, but the renderer in part/helpers.py remained on the non-sandboxed jinja2.Environment. Additionally, the validator relies on a dummy Part instance with pk=None, causing conditional template expressions to evaluate differently during validation compared to production rendering. This flaw is classified under CWE-1336 with a CVSS v3.1 base score of 5.5 (AV:N/AC:L/PR:H/UI:N/S:C/C:L/I:L/A:N).

A staff user with settings access and granted staff permissions can exploit the vulnerability by crafting a malicious template that passes validation but executes arbitrary code during rendering. Attackers require high-privilege access, with no user interaction needed, enabling network-based exploitation of moderate complexity that results in low confidentiality and integrity impacts due to the changed scope.

The GitHub security advisory (GHSA-84jh-x777-8pqq) states that the issue is addressed in InvenTree versions 1.2.7 and 1.3.0, recommending upgrades to these releases for mitigation.

Details

CWE(s)

Affected Products

inventree project
inventree
1.2.3 — 1.2.6

CVEs Like This One

CVE-2026-27629Same product: Inventree Project Inventree
CVE-2026-39362Same product: Inventree Project Inventree
CVE-2026-33530Same product: Inventree Project Inventree
CVE-2026-35478Same product: Inventree Project Inventree
CVE-2026-35476Same product: Inventree Project Inventree
CVE-2026-27961Shared CWE-1336
CVE-2025-49828Shared CWE-1336
CVE-2026-34587Shared CWE-1336
CVE-2025-53909Shared CWE-1336
CVE-2025-27516Shared CWE-1336

References