CVE-2025-32381

CVE-2025-32381 is a medium-severity vulnerability in Mlc-ai Xgrammar with a CVSS 3.x base score of 6.5. It is not currently listed as actively exploited by CISA, and its EPSS exploit-prediction score is low. The underlying weakness is classified as CWE-770.

Key facts

Description

XGrammar is an open-source library for efficient, flexible, and portable structured generation. Prior to 0.1.18, Xgrammar includes a cache for compiled grammars to increase performance with repeated use of the same grammar. This cache is held in memory. Since the cache is unbounded, a system making use of xgrammar can be abused to fill up a host's memory and case a denial of service. For example, sending many small requests to an LLM inference server with unique JSON schemas would eventually cause this denial of service to occur. This vulnerability is fixed in 0.1.18.

Frequently asked questions

What is CVE-2025-32381?
XGrammar is an open-source library for efficient, flexible, and portable structured generation. Prior to 0.1.18, Xgrammar includes a cache for compiled grammars to increase performance with repeated use of the same grammar. This cache is held in memory. Since the cache is unbounded, a system making use of xgrammar can be abused to fill up a host's memory and case a denial of service. For example, sending many small requests to an LLM inference server with unique JSON schemas would eventually cause this denial of service to occur. This vulnerability is fixed in 0.1.18.
How severe is CVE-2025-32381?
CVE-2025-32381 has a CVSS 3.x base score of 6.5, rated medium severity. It is exploitable over network with low attack complexity, requires low privileges and no user interaction. Impact on confidentiality is none, integrity none, and availability high.
Is CVE-2025-32381 being actively exploited?
It is not currently listed in CISA's KEV catalog. Its EPSS exploit-prediction score is 0% (35th percentile), an estimate of the probability of exploitation in the next 30 days.
What products are affected by CVE-2025-32381?
CVE-2025-32381 affects Mlc-ai Xgrammar. See the affected-products list for the exact vulnerable versions.
How do I fix CVE-2025-32381?
Review the linked vendor and NVD advisories for patched versions and mitigations, then upgrade or apply the recommended workaround.
Does CVE-2025-32381 have an EU (EUVD) identifier?
Yes. CVE-2025-32381 is tracked in the ENISA EU Vulnerability Database (EUVD) as EUVD-2025-10549.
When was CVE-2025-32381 published?
CVE-2025-32381 was published on 2025-04-09 and last updated on 2026-06-17.

References

Affected products (1)

More vulnerabilities in Mlc-ai Xgrammar

All CVEs affecting Mlc-ai Xgrammar →

Other CWE-770 (Allocation of Resources Without Limits or Throttling) vulnerabilities

Browse all CWE-770 (Allocation of Resources Without Limits or Throttling) vulnerabilities →