CVE-2026-18632 langgenius dify Jinja2 jinja2_transformer.py jinja2.Template special elements used in a template engine

Medium 5.3 Published Updated

Remote attackers can execute arbitrary code via template injection in Dify's Jinja2 handler, requiring immediate mitigation due to public exploit availability.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Over the internet
Victim action needed
Not needed
Fix
None listed

What is CVE-2026-18632?

CVE-2026-18632 is a medium-severity code injection vulnerability in langgenius dify, published on 3 Aug 2026. Any signed-in user can exploit it over the network, with no action from the victim.

Official description

A security flaw has been discovered in langgenius dify up to 1.14.2. This issue affects the function jinja2.Template of the file api/core/helper/code_executor/jinja2/jinja2_transformer.py of the component Jinja2 Handler. The manipulation results in improper neutralization of special elements used in a template engine. The attack may be launched remotely. The exploit has been released to the public and may be used for attacks. The vendor was contacted early about this disclosure but did not respond in any way.

Weakness: CWE-791, CWE-1336

Which versions are affected by CVE-2026-18632?

How do I fix CVE-2026-18632?

No fix has been published for CVE-2026-18632 yet. Limit exposure of the affected software until one is available.

Upgrade, and never evaluate templates, expressions or code built from user input. More about Code injection.

Is CVE-2026-18632 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-18632 exists.

Sources

Also known as GHSA-9qv6-q72p-wgw8.

Is CVE-2026-18632 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free