8000 org.keycloak.sdjwt 26.8.2: a JWS crit header naming an unknown extension is accepted · Issue #55380 · keycloak/keycloak · GitHub
[go: up one dir, main page]

Skip to content

org.keycloak.sdjwt 26.8.2: a JWS crit header naming an unknown extension is accepted #55380

Description

@abstractj

Describe the bug

When the experimental OID4VC_VP feature is used, SD-JWT verification in org.keycloak.sdjwt accepts a JWS whose protected header contains a crit parameter naming an extension that Keycloak does not understand. RFC 7515, section 4.1.11 requires that a JWS is treated as invalid if any extension listed in crit is not understood and supported by the recipient. Keycloak has no handling of the crit header in org.keycloak.sdjwt or org.keycloak.jose.

This was observed for two parts of an SD-JWT presentation, both caused by the same missing check:

  1. An issuer-signed JWT with "crit": ["urn:example:never-understood"] is accepted.
  2. A key binding JWT with the same crit header is accepted.

The signature checks themselves work: a presentation with a modified issuer signature is refused. The impact is low. The issue does not allow a holder to change what the issuer signed, but it matters wherever an issuer or holder relies on a critical extension being enforced.

Version

26.8.2

Expected behavior

A JWS whose crit header lists an extension that is not understood and supported is rejected as invalid, for both the issuer-signed JWT and the key binding JWT, as required by RFC 7515, section 4.1.11.

Actual behavior

SdJwtVerificationContext.verifyPresentation accepts presentations whose issuer-signed JWT or key binding JWT carries a crit header naming an unknown extension, as long as the signature is valid.

Acknowledgement

Thank you to Egor Khaklin (Khaklin Technologies) for reporting this issue. As it affects the experimental OID4VC_VP feature, it is not subject to CVEs, so this is handled as a weakness in the public repository.


This issue was originally tracked in the private repository. Migrated by @abstractj.

Activity

  1. added
    priority/important
    area/oid4vc
    on Nov 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/oid4vckind/weaknesspriority/importantteam/core-authnteam/core-protocols

    Fields

    No fields configured for weakness.

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    0