Summary
vLLM can fail to validate prompt token IDs when it runs with --skip-tokenizer-init, allowing unauthenticated requests with out-of-range IDs to trigger a fatal embedding index error. Because the affected EngineCore is shared, this can deny service to other tenants using the same engine.
Affected context
The issue affects vLLM deployments in the described version range that serve requests with --skip-tokenizer-init. In this configuration, requests to /v1/completions, /v1/embeddings, or /pooling can bypass the tokenizer-gated vocabulary check, leaving token IDs insufficiently constrained before they reach the embedding lookup.
Exploit preconditions
- Attack surface: The vLLM completion, embedding, or pooling API is reachable.
- Required access: No authentication is required according to the vulnerability description.
- Trigger point: A request supplies an out-of-range prompt token ID while the server is running with
--skip-tokenizer-init. - Why exploitation is possible: The tokenizer-gated vocabulary check is bypassed, so an invalid ID can reach the embedding lookup and cause a fatal error in the shared EngineCore.
Why this happens
The application does not adequately validate that supplied token IDs fall within the valid vocabulary range when tokenizer initialization is skipped. Passing an unchecked ID to an embedding lookup can cause an index error that terminates the shared EngineCore. This is an improper input validation weakness, mapped to CWE-20.
Potential impact
- The shared EngineCore may crash, interrupting inference requests.
- Service availability may be affected for multiple tenants using the same engine.
- Repeated requests could cause prolonged or recurring disruption.
General mitigation guidance
Defensive patterns include validating token IDs against the active model vocabulary at the API boundary, including when tokenizer initialization is skipped, and rejecting invalid inputs before they reach model execution. Deployments can reduce exposure by limiting access to inference endpoints, isolating workloads or tenants, and applying least-privilege runtime permissions. Robust error handling and health checks can also help contain failures and support recovery.
How teams detect issues like this
- Use static analysis and code review to identify request paths where token IDs reach embedding operations without range validation.
- Test API behavior with boundary and out-of-range token IDs across supported endpoints and configuration modes.
- Monitor EngineCore crashes, fatal embedding index errors, and unusual invalid-input request patterns.
- Apply API policies that validate request structure and constrain token IDs before forwarding requests to model workers.

