
Cloud Vulnerability DB
A community-led vulnerabilities database
CVE-2026-16336 is an open redirect vulnerability in trinodb Trino 481, affecting the OAuth2/OIDC authentication component. The flaw resides in core/trino-main/src/main/java/io/trino/server/ExternalUriInfo.java, where the redirect_uri parameter is derived from untrusted request context without server-side validation or allowlisting. The vulnerability was reported via a GitHub issue on June 4, 2026, and published to NVD and the GitHub Advisory Database on July 21, 2026; the Trino project had not responded at time of disclosure. It carries a CVSS v3.1 score of 4.3 (Medium) and a CVSS v4.0 score of 5.3 (Medium) (Github Advisory, Trino Issue).
The root cause is CWE-601 (URL Redirection to Untrusted Site / Open Redirect): Trino dynamically constructs the OAuth2/OIDC callback URI from the incoming HTTP request context — including headers such as X-Forwarded-Host, X-Forwarded-Proto, and X-Forwarded-Prefix — and passes it directly as the redirect_uri to the Identity Provider (IdP) without validating it against a configured canonical allowlist (Trino Issue). The affected code paths include OAuth2WebUiAuthenticationFilter.java (Web UI OAuth challenge) and OAuth2TokenExchangeResource.java (CLI/external token exchange), both of which call ExternalUriInfo.java to resolve the base URI. An attacker who can influence the externally observed request URI — for example by manipulating forwarded headers through a misconfigured reverse proxy — can cause Trino to send an OAuth authorization request with an attacker-controlled redirect_uri. Exploitation is conditional on the IdP accepting the manipulated redirect_uri for Trino's client_id (e.g., due to wildcard or loose redirect URI matching in the IdP configuration) (Trino Issue, Github Advisory).
Successful exploitation allows an unauthenticated remote attacker to redirect a victim user to an attacker-controlled website during the OAuth2/OIDC authentication flow, enabling credential theft, phishing, or OAuth authorization code interception (Github Advisory). If the attacker captures the authorization code, they may be able to forward it back to Trino's legitimate callback endpoint and have Trino exchange it using its configured client credentials, potentially gaining unauthorized access to the Trino instance and the data it queries (Trino Issue). The impact is primarily an integrity concern (low) with no direct confidentiality or availability impact on the Trino system itself, though downstream credential compromise could lead to broader data access.
X-Forwarded-Host, X-Forwarded-Proto, or X-Forwarded-Prefix headers to Trino.redirect_uri values associated with Trino's OAuth client_id, which would permit attacker-controlled URIs.X-Forwarded-Host: attacker.example.com) to influence the dynamically constructed redirect_uri.redirect_uri pointing to the attacker-controlled domain and sends it to the IdP.redirect_uri, it redirects the victim's browser — along with the OAuth authorization code and state — to the attacker's server after successful authentication.redirect_uri pointing to an unexpected or external domain; outbound redirects from the IdP to domains not matching the configured Trino callback URL.X-Forwarded-Host / X-Forwarded-Proto / X-Forwarded-Prefix header values; IdP audit logs recording authorization code issuance to unrecognized redirect_uri values registered under Trino's client_id./oauth2/callback or equivalent).A patch is referenced in GitHub Advisory GHSA-rf2w-6p6m-3cqv; users should apply the available fix and monitor the Trino GitHub repository for an official patched release (Github Advisory). As a configuration-based workaround, administrators should configure the Identity Provider to enforce exact (not wildcard or prefix) redirect_uri matching for Trino's OAuth client_id, restricting accepted URIs to the canonical Trino callback URL including scheme, host, port, and path (Trino Issue). Additionally, reverse proxy configurations should be hardened to strip or validate X-Forwarded-Host, X-Forwarded-Proto, and X-Forwarded-Prefix headers before they reach Trino, preventing attacker influence over the dynamically constructed callback URI. Ideally, Trino should be configured with a canonical external OAuth callback URI that is validated server-side rather than derived from request context.
The vulnerability was initially reported by researcher 0Xrry via a GitHub issue on June 4, 2026, with a detailed technical description of the affected code paths and security impact (Trino Issue). As of the disclosure date (July 21, 2026), the Trino project had not publicly responded to the issue report. No significant broader media coverage or notable community commentary beyond the initial issue and advisory publication has been observed.
Source: This report was generated using AI
Free Vulnerability Assessment
Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.
Get a personalized demo
"Best User Experience I have ever seen, provides full visibility to cloud workloads."
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
"We know that if Wiz identifies something as critical, it actually is."