Improper Authentication in Doorkeeper - #VU159527
Published: November 6, 2026
Vulnerability details
The vulnerability allows an unauthenticated remote attacker to cause requests to execute under an unintended identity, including a gateway's identity, bypass token-based scope checks across infrastructure layers, and corrupt attribution, rate limiting, and resource-owner resolution.
The vulnerability exists due to Doorkeeper accepting simultaneous access-token transmission through the Authorization Bearer header, form-encoded body, and URI query instead of rejecting the request, selecting the first token yielded by the order in access_token_methods and silently discarding others, prioritizing access_token over bearer_token when both parameters are present, and reading merged body/query parameters that give the query precedence in Rails but the body precedence in Rack/Grape; this affects resources protected by doorkeeper_authorize!, including Rails, Grape, and controllers using Doorkeeper's base classes, as well as GET /oauth/token/info and the bearer-token authorization path of POST /oauth/introspect. An unauthenticated remote attacker can supply competing tokens without privileges beyond possession of the tokens they present, exploiting a gateway that adds its own Bearer header while forwarding a caller-controlled token parameter to execute under the gateway's identity without an error or log entry, or exploiting a WAF, gateway, or middleware that checks a different transmission method to pass a scope check on one token while Doorkeeper executes under another; configured extraction order determines which token wins, body/query collisions resolve differently across frameworks, and a revoked token selected ahead of a valid token causes authentication to fail rather than using the valid token.