Class FilesystemClientInformationResolver
- java.lang.Object
-
- net.shibboleth.utilities.java.support.component.AbstractInitializableComponent
-
- net.shibboleth.utilities.java.support.component.AbstractIdentifiedInitializableComponent
-
- net.shibboleth.utilities.java.support.component.AbstractIdentifiableInitializableComponent
-
- net.shibboleth.oidc.metadata.impl.AbstractOIDCEntityResolver<Key,Value>
-
- net.shibboleth.oidc.metadata.impl.AbstractReloadingOIDCEntityResolver<Key,Value>
-
- net.shibboleth.oidc.metadata.impl.AbstractFileOIDCEntityResolver<com.nimbusds.oauth2.sdk.id.ClientID,com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation>
-
- net.shibboleth.oidc.metadata.impl.FilesystemClientInformationResolver
-
- All Implemented Interfaces:
ClientInformationResolver,RefreshableClientInformationResolver,Component,DestructableComponent,IdentifiableComponent,IdentifiedComponent,InitializableComponent,Resolver<com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation,CriteriaSet>
public class FilesystemClientInformationResolver extends AbstractFileOIDCEntityResolver<com.nimbusds.oauth2.sdk.id.ClientID,com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation> implements RefreshableClientInformationResolver
Based onFilesystemMetadataResolver.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class net.shibboleth.oidc.metadata.impl.AbstractOIDCEntityResolver
AbstractOIDCEntityResolver.JsonBackingStore
-
-
Field Summary
Fields Modifier and Type Field Description private org.slf4j.LoggerlogClass logger.
-
Constructor Summary
Constructors Constructor Description FilesystemClientInformationResolver(Timer backgroundTaskTimer, Resource metadata)Constructor.FilesystemClientInformationResolver(Resource metadata)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voiddoInitialize()protected com.nimbusds.oauth2.sdk.id.ClientIDgetKey(com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation value)Gets the identifier for the given entity.protected List<com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation>parse(byte[] bytes)Parses an entity from the byte array.Iterable<com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation>resolve(CriteriaSet criteria)com.nimbusds.openid.connect.sdk.rp.OIDCClientInformationresolveSingle(CriteriaSet criteria)protected List<com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation>updateKeys(List<com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation> clientInformations)Updates the key set in the given list of OIDC client informations.-
Methods inherited from class net.shibboleth.oidc.metadata.impl.AbstractFileOIDCEntityResolver
doDestroy, fetchMetadata, getMetadataIdentifier, getMetadataUpdateTime, setMetadataFile
-
Methods inherited from class net.shibboleth.oidc.metadata.impl.AbstractReloadingOIDCEntityResolver
getLastRefresh, getLastUpdate, initOIDCResolver, refresh, scheduleNextRefresh, setMaxRefreshDelay, setMinRefreshDelay
-
Methods inherited from class net.shibboleth.oidc.metadata.impl.AbstractOIDCEntityResolver
createNewBackingStore, getBackingStore, getLogPrefix, indexEntityDescriptor, isFailFastInitialization, lookupIdentifier, lookupIndexedIdentifier, preProcessEntityDescriptor, removeByIdentifier, setBackingStore, setFailFastInitialization
-
Methods inherited from class net.shibboleth.utilities.java.support.component.AbstractIdentifiableInitializableComponent
setId
-
Methods inherited from class net.shibboleth.utilities.java.support.component.AbstractIdentifiedInitializableComponent
getId
-
Methods inherited from class net.shibboleth.utilities.java.support.component.AbstractInitializableComponent
destroy, initialize, isDestroyed, isInitialized
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.shibboleth.utilities.java.support.component.IdentifiedComponent
getId
-
Methods inherited from interface net.shibboleth.oidc.metadata.RefreshableClientInformationResolver
getLastRefresh, getLastUpdate, refresh
-
-
-
-
Constructor Detail
-
FilesystemClientInformationResolver
public FilesystemClientInformationResolver(@Nonnull Resource metadata) throws IOExceptionConstructor.- Parameters:
metadata- the metadata file- Throws:
IOException- If the metedata cannot be loaded.
-
FilesystemClientInformationResolver
public FilesystemClientInformationResolver(@Nullable Timer backgroundTaskTimer, @Nonnull Resource metadata) throws IOExceptionConstructor.- Parameters:
metadata- the metadata filebackgroundTaskTimer- timer used to refresh metadata in the background- Throws:
IOException- If the metedata cannot be loaded.
-
-
Method Detail
-
doInitialize
protected void doInitialize() throws ComponentInitializationException- Overrides:
doInitializein classAbstractOIDCEntityResolver<com.nimbusds.oauth2.sdk.id.ClientID,com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation>- Throws:
ComponentInitializationException
-
resolve
public Iterable<com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation> resolve(CriteriaSet criteria) throws ResolverException
- Specified by:
resolvein interfaceResolver<com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation,CriteriaSet>- Throws:
ResolverException
-
updateKeys
protected List<com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation> updateKeys(List<com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation> clientInformations)
Updates the key set in the given list of OIDC client informations. The configured remote JWK set cache is exploited.- Parameters:
clientInformations- The OIDC client informations whose keys are going to be updated.- Returns:
- The OIDC client informations, containing contents of getJWKSetURI() in getJWKSet().
-
resolveSingle
public com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation resolveSingle(@Nullable CriteriaSet criteria) throws ResolverException- Specified by:
resolveSinglein interfaceResolver<com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation,CriteriaSet>- Throws:
ResolverException
-
parse
protected List<com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation> parse(@Nonnull byte[] bytes) throws com.nimbusds.oauth2.sdk.ParseException
Parses an entity from the byte array.- Specified by:
parsein classAbstractReloadingOIDCEntityResolver<com.nimbusds.oauth2.sdk.id.ClientID,com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation>- Parameters:
bytes- The encoded entity- Returns:
- The parsed entity
- Throws:
com.nimbusds.oauth2.sdk.ParseException- if parse fails
-
getKey
protected com.nimbusds.oauth2.sdk.id.ClientID getKey(@Nonnull com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation value)Gets the identifier for the given entity.- Specified by:
getKeyin classAbstractReloadingOIDCEntityResolver<com.nimbusds.oauth2.sdk.id.ClientID,com.nimbusds.openid.connect.sdk.rp.OIDCClientInformation>- Parameters:
value- The entity whose identifier will be returned.- Returns:
- The identifier for the given entity.
-
-