You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 26, 2026. It is now read-only.
Repository navigation
This repository was archived by the owner on Aug 26, 2026. It is now read-only.
Generating ID token when sid null during refresh_token grant throws IllegalArgumentException #1283
Describe the bug
Generating a refresh_token with null sid from the OidcIdToken claims throw IllegalArgumentException
To Reproduce
Don't set the SessionRegistry on the OAuth2AuthorizationCodeAuthenticationProvider or use a SessionRegistry that don't return SessionInformation
Expected behavior
Generating a refresh_token with null sid from the OidcIdToken claims should not throw an exception.
sid
OPTIONAL. Session ID - String identifier for a Session. This represents a Session of a User Agent or device for a logged-in End-User at an RP. Different sid values are used to identify distinct sessions at an OP. The sid value need only be unique in the context of a particular issuer. Its contents are opaque to the RP. Its syntax is the same as an OAuth 2.0 Client Identifier.
At the moment, the sid can be null in the OidcIdToken if the SessionInformation was not found but it's throw a IllegalArgumentException when generating a refresh_token.
changed the title [-]Generating a refresh_token with null 'sid' from the OidcIdToken claims throw IllegalArgumentException[/-][+]Generating ID token when sid null during refresh_token grant throws IllegalArgumentException[/+]on Jun 30, 2023
Activity
jgrandja commentedon Jun 23, 2023
@cbilodeauupgrade Thanks for reporting this. Would you be interested in submitting a PR with the fix?
[-]Generating a refresh_token with null 'sid' from the OidcIdToken claims throw IllegalArgumentException[/-][+]Generating ID token when sid null during refresh_token grant throws IllegalArgumentException[/+]Fix generating ID token with null sid when refresh_token grant
Get latest from source (#2)