Keycloak OIDC redirect param bypass via extra '?' leads to login code injection
CVE-2026-137431 Published on November 26, 2026

Keycloak-services: keycloak-services: leading ? in a redirect_uri parameter name bypasses the forbidden oidc parameter check
A flaw was found in the keycloak-services component of Keycloak, which is used to handle OpenID Connect authentication flows. The issue occurs because the security check that prevents attackers from pre-seeding security parameters in a redirect URL can be bypassed by adding an extra question mark character to the parameter name. This allows an attacker to trick a user's browser into using an attacker-controlled login code. As a result, a victim may be unknowingly logged into an attacker's account, leading to account confusion or the exposure of sensitive data entered by the victim.

NVD

Vulnerability Analysis

CVE-2026-137431 can be exploited with network access, requires user interaction. This vulnerability is consided to have a high level of attack complexity. The potential impact of an exploit of this vulnerability is considered to have a small impact on confidentiality and integrity, and no impact on availability.

Attack Vector:
NETWORK
Attack Complexity:
HIGH
Privileges Required:
NONE
User Interaction:
REQUIRED
Scope:
UNCHANGED
Confidentiality Impact:
LOW
Integrity Impact:
LOW
Availability Impact:
NONE

Timeline

Reported to Red Hat.

Made public.

Weakness Type

Improper Validation of Consistency within Input

The product receives a complex input with multiple elements or fields that must be consistent with each other, but it does not validate or incorrectly validates that the input is actually consistent.


Products Associated with CVE-2026-137431

stack.watch emails you whenever new vulnerabilities are published in Red Hat Build Keycloak or Red Hat Single Sign On. Just hit a watch button to start following.

Affected Versions

Red Hat Build of Keycloak: Red Hat Build of Keycloak: Red Hat Single Sign-On 7: Red Hat Single Sign-On 7: