Class BasicJWKCredentialFactoryBean

java.lang.Object
org.springframework.beans.factory.config.AbstractFactoryBean<T>
net.shibboleth.ext.spring.factory.AbstractComponentAwareFactoryBean<T>
net.shibboleth.idp.profile.spring.factory.AbstractCredentialFactoryBean<BasicJWKCredential>
net.shibboleth.oidc.security.credential.BasicJWKCredentialFactoryBean
All Implemented Interfaces:
Aware, BeanClassLoaderAware, BeanFactoryAware, DisposableBean, FactoryBean<BasicJWKCredential>, InitializingBean

public class BasicJWKCredentialFactoryBean extends AbstractCredentialFactoryBean<BasicJWKCredential>
Factory bean for Basic JSON Web Keys (JWK).
Since:
2.2.0
  • Field Details

    • log

      private final org.slf4j.Logger log
      Class logger.
    • jwkResource

      @Nullable private Resource jwkResource
      Where the private key is to be found.
    • failIfResourceIsNull

      private boolean failIfResourceIsNull
      Should the factory throw an exception if the resource is null?.
    • symmetricKeyAlgorithm

      private String symmetricKeyAlgorithm
      The JCA algorithm name to use if the key to be converted is a symmetric key. Default is AES.
  • Constructor Details

    • BasicJWKCredentialFactoryBean

      public BasicJWKCredentialFactoryBean()
      Constructor.
  • Method Details

    • setSymmetricKeyAlgorithm

      public void setSymmetricKeyAlgorithm(@Nonnull @NotEmpty String algorithm)
      Set the JCA algorithm name to use if the key to be converted is a symmetric key.
      Parameters:
      algorithm - the JCA name
    • setFailIfResourceIsNull

      public void setFailIfResourceIsNull(boolean flag)
      Should the factory throw an exeception if the resource is null?
      Parameters:
      flag - the flag
    • setResource

      public void setResource(@Nonnull Resource res)
      Set the resource containing the private key.
      Parameters:
      res - private key resource, never null
    • doCreateInstance

      protected BasicJWKCredential doCreateInstance() throws Exception
      Specified by:
      doCreateInstance in class net.shibboleth.ext.spring.factory.AbstractComponentAwareFactoryBean<BasicJWKCredential>
      Throws:
      Exception
    • getObjectType

      public Class<?> getObjectType()
      Specified by:
      getObjectType in interface FactoryBean<BasicJWKCredential>
      Specified by:
      getObjectType in class AbstractFactoryBean<BasicJWKCredential>