public class OAuth20AuthorizeEndpointController extends BaseOAuth20Controller
| Modifier and Type | Field and Description |
|---|---|
protected OAuth20CasAuthenticationBuilder |
authenticationBuilder
The Authentication builder.
|
protected ConsentApprovalViewResolver |
consentApprovalViewResolver
The Consent approval view resolver.
|
protected OAuthCodeFactory |
oAuthCodeFactory
The code factory instance.
|
accessTokenFactory, casProperties, principalFactory, scopeToAttributesFilter, servicesManager, ticketGrantingTicketCookieGenerator, ticketRegistry, validator, webApplicationServiceServiceFactory| Constructor and Description |
|---|
OAuth20AuthorizeEndpointController(org.apereo.cas.services.ServicesManager servicesManager,
org.apereo.cas.ticket.registry.TicketRegistry ticketRegistry,
OAuth20Validator validator,
AccessTokenFactory accessTokenFactory,
org.apereo.cas.authentication.principal.PrincipalFactory principalFactory,
org.apereo.cas.authentication.principal.ServiceFactory<org.apereo.cas.authentication.principal.WebApplicationService> webApplicationServiceServiceFactory,
OAuthCodeFactory oAuthCodeFactory,
ConsentApprovalViewResolver consentApprovalViewResolver,
OAuth20ProfileScopeToAttributesFilter scopeToAttributesFilter,
org.apereo.cas.configuration.CasConfigurationProperties casProperties,
org.apereo.cas.web.support.CookieRetrievingCookieGenerator ticketGrantingTicketCookieGenerator,
OAuth20CasAuthenticationBuilder authenticationBuilder) |
| Modifier and Type | Method and Description |
|---|---|
protected java.lang.String |
buildCallbackUrlForTokenResponseType(org.pac4j.core.context.J2EContext context,
org.apereo.cas.authentication.Authentication authentication,
org.apereo.cas.authentication.principal.Service service,
java.lang.String redirectUri,
java.lang.String responseType,
java.lang.String clientId)
Build callback url for token response type string.
|
protected java.lang.String |
buildCallbackUrlResponseType(org.apereo.cas.authentication.Authentication authentication,
org.apereo.cas.authentication.principal.Service service,
java.lang.String redirectUri,
org.apereo.cas.ticket.accesstoken.AccessToken accessToken,
java.util.List<org.apache.http.NameValuePair> params)
Build callback url response type string.
|
protected org.apereo.cas.support.oauth.services.OAuthRegisteredService |
getRegisteredServiceByClientId(java.lang.String clientId)
Gets registered service by client id.
|
org.springframework.web.servlet.ModelAndView |
handleRequest(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Handle request internal model and view.
|
protected org.springframework.web.servlet.ModelAndView |
redirectToCallbackRedirectUrl(org.pac4j.core.profile.ProfileManager manager,
org.apereo.cas.support.oauth.services.OAuthRegisteredService registeredService,
org.pac4j.core.context.J2EContext context,
java.lang.String clientId)
Redirect to callback redirect url model and view.
|
addTicketToRegistry, generateAccessTokenprotected OAuthCodeFactory oAuthCodeFactory
protected final ConsentApprovalViewResolver consentApprovalViewResolver
protected final OAuth20CasAuthenticationBuilder authenticationBuilder
public OAuth20AuthorizeEndpointController(org.apereo.cas.services.ServicesManager servicesManager,
org.apereo.cas.ticket.registry.TicketRegistry ticketRegistry,
OAuth20Validator validator,
AccessTokenFactory accessTokenFactory,
org.apereo.cas.authentication.principal.PrincipalFactory principalFactory,
org.apereo.cas.authentication.principal.ServiceFactory<org.apereo.cas.authentication.principal.WebApplicationService> webApplicationServiceServiceFactory,
OAuthCodeFactory oAuthCodeFactory,
ConsentApprovalViewResolver consentApprovalViewResolver,
OAuth20ProfileScopeToAttributesFilter scopeToAttributesFilter,
org.apereo.cas.configuration.CasConfigurationProperties casProperties,
org.apereo.cas.web.support.CookieRetrievingCookieGenerator ticketGrantingTicketCookieGenerator,
OAuth20CasAuthenticationBuilder authenticationBuilder)
@GetMapping(path="/oauth2.0/authorize")
public org.springframework.web.servlet.ModelAndView handleRequest(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws java.lang.Exception
request - the requestresponse - the responsejava.lang.Exception - the exceptionprotected org.apereo.cas.support.oauth.services.OAuthRegisteredService getRegisteredServiceByClientId(java.lang.String clientId)
clientId - the client idprotected org.springframework.web.servlet.ModelAndView redirectToCallbackRedirectUrl(org.pac4j.core.profile.ProfileManager manager,
org.apereo.cas.support.oauth.services.OAuthRegisteredService registeredService,
org.pac4j.core.context.J2EContext context,
java.lang.String clientId)
throws java.lang.Exception
manager - the managerregisteredService - the registered servicecontext - the contextclientId - the client idjava.lang.Exception - the exceptionprotected java.lang.String buildCallbackUrlForTokenResponseType(org.pac4j.core.context.J2EContext context,
org.apereo.cas.authentication.Authentication authentication,
org.apereo.cas.authentication.principal.Service service,
java.lang.String redirectUri,
java.lang.String responseType,
java.lang.String clientId)
context - the contextauthentication - the authenticationservice - the serviceredirectUri - the redirect uriresponseType - the response typeclientId - the client idprotected java.lang.String buildCallbackUrlResponseType(org.apereo.cas.authentication.Authentication authentication,
org.apereo.cas.authentication.principal.Service service,
java.lang.String redirectUri,
org.apereo.cas.ticket.accesstoken.AccessToken accessToken,
java.util.List<org.apache.http.NameValuePair> params)
throws java.lang.Exception
authentication - the authenticationservice - the serviceredirectUri - the redirect uriaccessToken - the access tokenparams - the paramsjava.lang.Exception - the exception