Class EmbeddedLoginTokenGranter
- java.lang.Object
-
- org.springframework.security.oauth2.provider.token.AbstractTokenGranter
-
- com.broadleafcommerce.auth.user.session.embedded.EmbeddedLoginTokenGranter
-
- All Implemented Interfaces:
org.springframework.security.oauth2.provider.TokenGranter
public class EmbeddedLoginTokenGranter extends org.springframework.security.oauth2.provider.token.AbstractTokenGranterUsed for token requests where there is anEmbeddedLoginTokenEndpointAuthenticationTokenin the security context.- Author:
- Cade Rea (cade-rea)
-
-
Constructor Summary
Constructors Constructor Description EmbeddedLoginTokenGranter(org.springframework.security.oauth2.provider.token.AuthorizationServerTokenServices tokenServices, org.springframework.security.oauth2.provider.ClientDetailsService clientDetailsService, org.springframework.security.oauth2.provider.OAuth2RequestFactory requestFactory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected org.springframework.security.oauth2.provider.OAuth2AuthenticationgetOAuth2Authentication(org.springframework.security.oauth2.provider.ClientDetails client, org.springframework.security.oauth2.provider.TokenRequest tokenRequest)Use theEmbeddedLoginTokenEndpointAuthenticationTokento create aOAuth2Authenticationto be used inAuthorizationServerTokenServices.createAccessToken(org.springframework.security.oauth2.provider.OAuth2Authentication)org.springframework.security.oauth2.common.OAuth2AccessTokengrant(String grantType, org.springframework.security.oauth2.provider.TokenRequest tokenRequest)
-
-
-
Constructor Detail
-
EmbeddedLoginTokenGranter
public EmbeddedLoginTokenGranter(org.springframework.security.oauth2.provider.token.AuthorizationServerTokenServices tokenServices, org.springframework.security.oauth2.provider.ClientDetailsService clientDetailsService, org.springframework.security.oauth2.provider.OAuth2RequestFactory requestFactory)
-
-
Method Detail
-
grant
public org.springframework.security.oauth2.common.OAuth2AccessToken grant(String grantType, org.springframework.security.oauth2.provider.TokenRequest tokenRequest)
- Specified by:
grantin interfaceorg.springframework.security.oauth2.provider.TokenGranter- Overrides:
grantin classorg.springframework.security.oauth2.provider.token.AbstractTokenGranter
-
getOAuth2Authentication
protected org.springframework.security.oauth2.provider.OAuth2Authentication getOAuth2Authentication(org.springframework.security.oauth2.provider.ClientDetails client, org.springframework.security.oauth2.provider.TokenRequest tokenRequest)Use theEmbeddedLoginTokenEndpointAuthenticationTokento create aOAuth2Authenticationto be used inAuthorizationServerTokenServices.createAccessToken(org.springframework.security.oauth2.provider.OAuth2Authentication)- Overrides:
getOAuth2Authenticationin classorg.springframework.security.oauth2.provider.token.AbstractTokenGranter- Parameters:
client-tokenRequest-- Returns:
-
-