<Vulnerability name="CVE-2026-9086">
    <DocumentDistribution xml:lang="en">Copyright © 2012 Red Hat, Inc. All rights reserved.</DocumentDistribution>
    <ThreatSeverity>Important</ThreatSeverity>
    <PublicDate>2026-06-25T15:58:33</PublicDate>
    <Bugzilla id="2480170" url="https://bugzilla.redhat.com/show_bug.cgi?id=2480170" xml:lang="en:us">
keycloak: Keycloak: Cross-site scripting (XSS) via case-insensitive URI validation bypass
    </Bugzilla>
    <CVSS3 status="verified">
        <CVSS3BaseScore>7.3</CVSS3BaseScore>
        <CVSS3ScoringVector>CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:N</CVSS3ScoringVector>
    </CVSS3>
    <CWE>CWE-79</CWE>
    <Details xml:lang="en:us" source="Mitre">
A flaw was found in Keycloak. A remote attacker with administrative privileges, specifically those with `manage-client` permission or access to client registration endpoints, could bypass client Uniform Resource Identifier (URI) validation. This is achieved by registering a malicious client with a specially crafted redirect URI using a case-insensitive `javascript:` or `data:` scheme. This Cross-Site Scripting (XSS) vulnerability allows for arbitrary code execution in the Keycloak origin when a victim clicks the crafted link, such as in the logout flow or the Admin Console.
    </Details>
    <Details xml:lang="en:us" source="Red Hat">
A flaw was found in Keycloak. A remote attacker with administrative privileges, specifically those with `manage-client` permission or access to client registration endpoints, could bypass client Uniform Resource Identifier (URI) validation. This is achieved by registering a malicious client with a specially crafted redirect URI using a case-insensitive `javascript:` or `data:` scheme. This Cross-Site Scripting (XSS) vulnerability allows for arbitrary code execution in the Keycloak origin when a victim clicks the crafted link, such as in the logout flow or the Admin Console.
    </Details>
    <Statement xml:lang="en:us">
This flaw is rated as High. Keycloak's client URI validation is vulnerable to a case-insensitivity issue, allowing attackers to bypass scheme blocklists by using mixed-case `javascript:` or `data:` URIs. This can lead to cross-site scripting (XSS) in the Keycloak origin when a victim interacts with a crafted link, such as during the logout flow. Exploitation requires an authenticated administrator with `manage-client` privileges or access to client registration endpoints, and user interaction.
    </Statement>
    <Acknowledgement xml:lang="en:us">
Red Hat would like to thank saku0512 for reporting this issue.
    </Acknowledgement>
    <Mitigation xml:lang="en:us">
To mitigate this vulnerability, restrict the ability to register new clients and manage existing client configurations. If Dynamic Client Registration is not required, disable it in Keycloak's Realm Settings under Client Registration Policies. If Dynamic Client Registration is necessary, ensure that policies are strictly configured to prevent anonymous client registration and require initial access tokens for all client registrations. Additionally, limit the `manage-client` role to only trusted administrators. Changes to Keycloak configuration may require a service restart or redeployment to take effect.
    </Mitigation>
    <AffectedRelease cpe="cpe:/a:redhat:build_keycloak:26.4::el9">
        <ProductName>Red Hat build of Keycloak 26.4</ProductName>
        <ReleaseDate>2026-06-25T00:00:00Z</ReleaseDate>
        <Advisory type="RHSA" url="https://access.redhat.com/errata/RHSA-2026:30050">RHSA-2026:30050</Advisory>
        <Package name="rhbk/keycloak-operator-bundle">rhbk/keycloak-operator-bundle:26.4.13-1</Package>
    </AffectedRelease>
    <AffectedRelease cpe="cpe:/a:redhat:build_keycloak:26.4::el9">
        <ProductName>Red Hat build of Keycloak 26.4</ProductName>
        <ReleaseDate>2026-06-25T00:00:00Z</ReleaseDate>
        <Advisory type="RHSA" url="https://access.redhat.com/errata/RHSA-2026:30050">RHSA-2026:30050</Advisory>
        <Package name="rhbk/keycloak-rhel9">rhbk/keycloak-rhel9:26.4-19</Package>
    </AffectedRelease>
    <AffectedRelease cpe="cpe:/a:redhat:build_keycloak:26.4::el9">
        <ProductName>Red Hat build of Keycloak 26.4</ProductName>
        <ReleaseDate>2026-06-25T00:00:00Z</ReleaseDate>
        <Advisory type="RHSA" url="https://access.redhat.com/errata/RHSA-2026:30050">RHSA-2026:30050</Advisory>
        <Package name="rhbk/keycloak-rhel9-operator">rhbk/keycloak-rhel9-operator:26.4-19</Package>
    </AffectedRelease>
    <AffectedRelease cpe="cpe:/a:redhat:build_keycloak:26.4::el9">
        <ProductName>Red Hat build of Keycloak 26.4.13</ProductName>
        <ReleaseDate>2026-06-25T00:00:00Z</ReleaseDate>
        <Advisory type="RHSA" url="https://access.redhat.com/errata/RHSA-2026:30049">RHSA-2026:30049</Advisory>
        <Package name="rhbk/keycloak-rhel9">rhbk/keycloak-rhel9</Package>
    </AffectedRelease>
    <AffectedRelease cpe="cpe:/a:redhat:build_keycloak:26.6::el9">
        <ProductName>Red Hat build of Keycloak 26.6</ProductName>
        <ReleaseDate>2026-06-25T00:00:00Z</ReleaseDate>
        <Advisory type="RHSA" url="https://access.redhat.com/errata/RHSA-2026:30084">RHSA-2026:30084</Advisory>
        <Package name="rhbk/keycloak-operator-bundle">rhbk/keycloak-operator-bundle:26.6.4-2</Package>
    </AffectedRelease>
    <AffectedRelease cpe="cpe:/a:redhat:build_keycloak:26.6::el9">
        <ProductName>Red Hat build of Keycloak 26.6</ProductName>
        <ReleaseDate>2026-06-25T00:00:00Z</ReleaseDate>
        <Advisory type="RHSA" url="https://access.redhat.com/errata/RHSA-2026:30084">RHSA-2026:30084</Advisory>
        <Package name="rhbk/keycloak-rhel9">rhbk/keycloak-rhel9:26.6-8</Package>
    </AffectedRelease>
    <AffectedRelease cpe="cpe:/a:redhat:build_keycloak:26.6::el9">
        <ProductName>Red Hat build of Keycloak 26.6</ProductName>
        <ReleaseDate>2026-06-25T00:00:00Z</ReleaseDate>
        <Advisory type="RHSA" url="https://access.redhat.com/errata/RHSA-2026:30084">RHSA-2026:30084</Advisory>
        <Package name="rhbk/keycloak-rhel9-operator">rhbk/keycloak-rhel9-operator:26.6-8</Package>
    </AffectedRelease>
    <AffectedRelease cpe="cpe:/a:redhat:build_keycloak:26.6::el9">
        <ProductName>Red Hat build of Keycloak 26.6.4</ProductName>
        <ReleaseDate>2026-06-25T00:00:00Z</ReleaseDate>
        <Advisory type="RHSA" url="https://access.redhat.com/errata/RHSA-2026:30083">RHSA-2026:30083</Advisory>
        <Package name="rhbk/keycloak-rhel9">rhbk/keycloak-rhel9</Package>
    </AffectedRelease>
    <References xml:lang="en:us">
https://www.cve.org/CVERecord?id=CVE-2026-9086
https://nvd.nist.gov/vuln/detail/CVE-2026-9086
    </References>
</Vulnerability>