Package org.oa4mp.client.loader
Class OA2ClientEnvironment
- java.lang.Object
-
- edu.uiuc.ncsa.security.core.util.AbstractEnvironment
-
- org.oa4mp.delegation.client.AbstractClientEnvironment
-
- org.oa4mp.client.api.ClientEnvironment
-
- org.oa4mp.client.loader.OA2ClientEnvironment
-
- All Implemented Interfaces:
edu.uiuc.ncsa.security.core.Logable
,Serializable
public class OA2ClientEnvironment extends ClientEnvironment
Created by Jeff Gaynor
on 11/25/13 at 4:23 PM- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class org.oa4mp.client.api.ClientEnvironment
accessTokenUri, authorizationUri, callback, CALLBACK_URI_KEY, client, cp, errorPagePath, FORM_ENCODING, initializeUri, privKeyString, redirectPagePath, resourceServerUri, skin, successPagePath, tfp, TOKEN
-
Fields inherited from class org.oa4mp.delegation.client.AbstractClientEnvironment
CERT_LIFETIME_KEY, CERT_REQUEST_KEY
-
-
Constructor Summary
Constructors Constructor Description OA2ClientEnvironment()
OA2ClientEnvironment(edu.uiuc.ncsa.security.core.util.MyLoggingFacade logger, Map<String,String> constants, URI accessTokenUri, URI authorizationUri, URI callback, URI resourceServerUri, long certLifetime, String clientId, String skin, boolean enableAssetCleanup, long maxAssetLifetime, long keypairLifetime, AssetProvider assetProvider, javax.inject.Provider<Client> clientProvider, javax.inject.Provider<TokenForge> tokenForgeProvider, javax.inject.Provider<DelegationService> delegationServiceProvider, javax.inject.Provider<AssetStore> assetStoreProvider, boolean showRedirectPage, String errorPagePath, String redirectPagePath, String successPagePath, String secret, String kid, edu.uiuc.ncsa.security.util.jwk.JSONWebKeys jwks, Collection<String> scopes, String wellKnownURI, boolean oidcEnabled, boolean showIDToken, boolean useBasicAuth, Map<String,List<String>> additionalParameters, URI deviceAuthorizationUri, URI issuer, edu.uiuc.ncsa.security.core.util.MetaDebugUtil metaDebugUtil)
OA2ClientEnvironment(URI accessTokenUri, URI authorizationUri, URI callback, long certLifetime, String clientId, DelegationService delegationService, URI resourceServerUri, TokenForge tokenForge, AssetStore assetStore, boolean showRedirectPage, String errorPagePath, String redirectPagePath, String successPagePath, boolean oidcEnabled, boolean showIDToken, boolean useBasicAuth, URI deviceAuthorizationUri, URI issuer, edu.uiuc.ncsa.security.core.util.MetaDebugUtil metaDebugUtil, String kid, edu.uiuc.ncsa.security.util.jwk.JSONWebKeys jwks)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Map<String,List<String>>
getAdditionalParameters()
Client
getClient()
AClient
object representing the instance of this service.URI
getDeviceAuthorizationUri()
URI
getIssuer()
edu.uiuc.ncsa.security.core.util.MetaDebugUtil
getMetaDebugUtil()
Collection<String>
getScopes()
String
getWellKnownURI()
boolean
hasScopes()
boolean
isOidcEnabled()
boolean
isShowIDToken()
If the user enables showing the ID token, then information to be displayed on the success page will be put in to the response.boolean
isUseBasicAuth()
String
scopesToString()
Convert the client's configured scopes to a string.String
scopesToString(Collection<String> scopes)
Convert any (Java) collection of strings to a scope.void
setAdditionalParameters(Map<String,List<String>> additionalParameters)
void
setDeviceAuthorizationUri(URI deviceAuthorizationUri)
void
setIssuer(URI issuer)
void
setMetaDebugUtil(edu.uiuc.ncsa.security.core.util.MetaDebugUtil metaDebugUtil)
void
setScopes(Collection<String> scopes)
-
Methods inherited from class org.oa4mp.client.api.ClientEnvironment
getAccessTokenUri, getAssetProvider, getAssetStore, getAuthorizationUri, getCallback, getCertLifetime, getClientId, getDelegationService, getErrorPagePath, getInitializeUri, getJWKS, getKeypairLifetime, getKid, getMaxAssetLifetime, getPrivateKey, getPrivKeyString, getPublicKey, getRedirectPagePath, getResourceServerUri, getSkin, getSuccessPagePath, getTokenForge, hasAssetStore, hasJWKS, hasKID, isEnableAssetCleanup, isShowRedirectPage, setAssetProvider, setCallback, setCertLifetime, setErrorPagePath, setJWKS, setKid, setRedirectPagePath, setSuccessPagePath
-
-
-
-
Constructor Detail
-
OA2ClientEnvironment
public OA2ClientEnvironment()
-
OA2ClientEnvironment
public OA2ClientEnvironment(URI accessTokenUri, URI authorizationUri, URI callback, long certLifetime, String clientId, DelegationService delegationService, URI resourceServerUri, TokenForge tokenForge, AssetStore assetStore, boolean showRedirectPage, String errorPagePath, String redirectPagePath, String successPagePath, boolean oidcEnabled, boolean showIDToken, boolean useBasicAuth, URI deviceAuthorizationUri, URI issuer, edu.uiuc.ncsa.security.core.util.MetaDebugUtil metaDebugUtil, String kid, edu.uiuc.ncsa.security.util.jwk.JSONWebKeys jwks)
-
OA2ClientEnvironment
public OA2ClientEnvironment(edu.uiuc.ncsa.security.core.util.MyLoggingFacade logger, Map<String,String> constants, URI accessTokenUri, URI authorizationUri, URI callback, URI resourceServerUri, long certLifetime, String clientId, String skin, boolean enableAssetCleanup, long maxAssetLifetime, long keypairLifetime, AssetProvider assetProvider, javax.inject.Provider<Client> clientProvider, javax.inject.Provider<TokenForge> tokenForgeProvider, javax.inject.Provider<DelegationService> delegationServiceProvider, javax.inject.Provider<AssetStore> assetStoreProvider, boolean showRedirectPage, String errorPagePath, String redirectPagePath, String successPagePath, String secret, String kid, edu.uiuc.ncsa.security.util.jwk.JSONWebKeys jwks, Collection<String> scopes, String wellKnownURI, boolean oidcEnabled, boolean showIDToken, boolean useBasicAuth, Map<String,List<String>> additionalParameters, URI deviceAuthorizationUri, URI issuer, edu.uiuc.ncsa.security.core.util.MetaDebugUtil metaDebugUtil)
-
-
Method Detail
-
getIssuer
public URI getIssuer()
-
setIssuer
public void setIssuer(URI issuer)
-
getDeviceAuthorizationUri
public URI getDeviceAuthorizationUri()
-
setDeviceAuthorizationUri
public void setDeviceAuthorizationUri(URI deviceAuthorizationUri)
-
setAdditionalParameters
public void setAdditionalParameters(Map<String,List<String>> additionalParameters)
-
isUseBasicAuth
public boolean isUseBasicAuth()
-
getScopes
public Collection<String> getScopes()
-
hasScopes
public boolean hasScopes()
-
scopesToString
public String scopesToString(Collection<String> scopes)
Convert any (Java) collection of strings to a scope.- Parameters:
scopes
-- Returns:
-
scopesToString
public String scopesToString()
Convert the client's configured scopes to a string. If there are additional scopes, you will have to add those or just send all your scopes toscopesToString(Collection)
.- Returns:
-
getWellKnownURI
public String getWellKnownURI()
-
getClient
public Client getClient()
Description copied from class:ClientEnvironment
AClient
object representing the instance of this service.- Overrides:
getClient
in classClientEnvironment
- Returns:
-
isOidcEnabled
public boolean isOidcEnabled()
-
setScopes
public void setScopes(Collection<String> scopes)
-
isShowIDToken
public boolean isShowIDToken()
If the user enables showing the ID token, then information to be displayed on the success page will be put in to the response.- Returns:
-
getMetaDebugUtil
public edu.uiuc.ncsa.security.core.util.MetaDebugUtil getMetaDebugUtil()
-
setMetaDebugUtil
public void setMetaDebugUtil(edu.uiuc.ncsa.security.core.util.MetaDebugUtil metaDebugUtil)
-
-