Interface DeviceSSOHandler
- All Superinterfaces:
Lifecycle
Service Provider Interface (SPI) for handling device Single Sign-On (SSO).
Implementations must be thread-safe.
Related specifications:
- OpenID Connect Native SSO for Mobile Apps 1.0
-
Method Summary
Modifier and TypeMethodDescriptionprocessBackChannelRequest
(com.nimbusds.oauth2.sdk.id.Subject subject, com.nimbusds.openid.connect.sdk.claims.IDTokenClaimsSet idTokenClaimsSet, SubjectSession deviceSession, TokenRequestParameters tokenRequestParams, com.nimbusds.oauth2.sdk.id.ClientID clientID, boolean confidentialClient, com.nimbusds.openid.connect.sdk.rp.OIDCClientMetadata clientMetadata, DeviceSSOHandlerContext handlerCtx) Handles a back-channel device SSO request, represented by a token exchange request (RFC 8693), from a client registered with the Connect2id server.
-
Method Details
-
processBackChannelRequest
BackChannelDeviceSSOAuthorization processBackChannelRequest(com.nimbusds.oauth2.sdk.id.Subject subject, com.nimbusds.openid.connect.sdk.claims.IDTokenClaimsSet idTokenClaimsSet, SubjectSession deviceSession, TokenRequestParameters tokenRequestParams, com.nimbusds.oauth2.sdk.id.ClientID clientID, boolean confidentialClient, com.nimbusds.openid.connect.sdk.rp.OIDCClientMetadata clientMetadata, DeviceSSOHandlerContext handlerCtx) throws com.nimbusds.oauth2.sdk.GeneralException Handles a back-channel device SSO request, represented by a token exchange request (RFC 8693), from a client registered with the Connect2id server. Prior to calling this method the Connect2id server has successfully identified / authenticated the client and validated the received ID token (subject_token
), device secret (device_secret
) and their binding.If the requested scope is invalid, unknown, malformed, or exceeds the scope granted by the resource owner the handler must throw a
GeneralException
with aninvalid_scope
error code.If the requested scope requires a higher end-user authentication level (ACR) than recorded in the device session, or explicit consent by the end-user, the handler must throw a
GeneralException
with aninteraction_required
error code.- Parameters:
subject
- The local subject (end-user) of the validated ID token to sign-in. If the ID token was issued with a pairwise subject identifier, this is the resolved (decrypted) identifier value. Notnull
.idTokenClaimsSet
- The claims set of the received and successfully validated ID token. Note that the ID token subject identifier may be pairwise (encrypted). Use the subject argument which provides the local identifier value. Notnull
.deviceSession
- The device session corresponding to the received and successfully validated device secret. Notnull
.tokenRequestParams
- The token request parameters, such as the requested scope. Notnull
.clientID
- The client identifier. Notnull
.confidentialClient
-true
if the client is confidential and has been authenticated, elsefalse
.clientMetadata
- The OAuth 2.0 client / OpenID relying party metadata. Notnull
.handlerCtx
- The handler context. Notnull
.- Returns:
- The authorisation.
- Throws:
com.nimbusds.oauth2.sdk.GeneralException
- If the request was denied, or another exception was encountered.
-