CVE-2025-57809Mlc-ai Xgrammar
High 7.7 No auth needed
Follow: this CVE · Mlc-ai · Mlc-ai Xgrammar We alert you by email or Slack (account required).
- Priority
- 61
- CVSS 4.0
- 7.7
- EPSS
- —
- Auth required
- No
- Published
- Aug 25, 2025
- Updated
- Jun 17, 2026
- Category
- Application · Cross-platform
- Weakness (CWE)
- CWE-674
- SSVC (CISA)
- Exploitation: none · Automatable: no · Technical impact: partial
- Vector
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N/E:P/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
What happens
XGrammar is an open-source library for efficient, flexible, and portable structured generation. Prior to version 0.1.21, XGrammar has an infinite recursion issue in the grammar. This issue has been resolved in version 0.1.21.
What to do
- Apply the vendor's security update for Xgrammar.
- It can be exploited without authentication: if you cannot patch now, restrict Internet access to the affected service.
Affected packages
| Ecosystem | Package | Affected versions | Fixed in | How to upgrade |
|---|---|---|---|---|
| PyPI | xgrammar |
< 0.1.21 |
0.1.21 |
pip install "xgrammar>=0.1.21" |
| PyPI | xgrammar |
< 0.1.21 |
0.1.21 |
pip install "xgrammar>=0.1.21" |
Per OSV / GitHub Advisories (GHSA-5cmr-4px5-23pc, PYSEC-2026-2054). Check the version in your lockfile before upgrading.
Affected products (CPE)
| Vendor | Product | Versions |
|---|---|---|
| mlc-ai | xgrammar | < 0.1.21 |
Official sources
References
Links published by the sources. Open them with care.
- github.com Patch
- github.com Exploit Issue Tracking
- github.com Vendor Advisory