# CVE-2026-139989: Languagemodels 1.0.0 Jinja2 Template Injection RCE via Config.use_hf_model

- Severity: High 8.5 (CVSS:4.0, scored by VulnCheck) `CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.48%, higher than 43% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2026-11-30T18:26:34.358Z
- Modified: 2026-12-01T14:18:18.023Z
- Weaknesses: CWE-1336
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact total
- Assigned by: VulnCheck

## Description

Languagemodels 1.0.0 contains a template injection vulnerability in Config.use_hf_model that allows remote attackers to execute code by supplying a malicious Hugging Face model chat_template. Attackers who control a model repository can craft a chat_template in tokenizer_config.json that reaches the os module through the unsandboxed jinja2 environment, running commands with the victim process privileges.

(As written by CVE List.)

## Affected

- jncraton languagemodels: from 1.0.0 before 1.0.1

## Every score

- VulnCheck: CVSS:4.0 8.5 High `CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N`
- VulnCheck: CVSS:3.1 7.8 High `CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H`

## References

- <https://github.com/jncraton/languagemodels/issues/43> (exploit, issue-tracking)
- <https://github.com/jncraton/languagemodels/pull/44> (issue-tracking, patch)
- <https://github.com/jncraton/languagemodels/commit/48f4257a0d20a82075d2847a51036a3c8a2a0a13> (patch)
- <https://pypi.org/project/languagemodels/1.0.1/> (product)
- <https://github.com/jncraton/languagemodels/blob/a875090e2b74257e44bd0a534f42704a1014d61c/languagemodels/config.py#L366-L380> (technical-description)
- <https://www.vulncheck.com/advisories/languagemodels-1.0.0-jinja2-template-injection-rce-via-config-use-hf-model> (third-party-advisory)

## Sources

- CVE List: [CVE-2026-139989](https://www.cve.org/CVERecord?id=CVE-2026-139989), CVE Terms of Use, modified 2026-12-01
- NVD: [CVE-2026-139989](https://nvd.nist.gov/vuln/detail/CVE-2026-139989), Public domain, modified 2026-12-01

---

Page: https://cve.day/CVE-2026-139989 · Whole record: https://cve.day/CVE-2026-139989.json · Rebuilt by cve.day 2026-12-01T14:32:13.152Z
