Class SoftwareStatement

java.lang.Object
org.forgerock.openig.fapi.dcr.SoftwareStatement

public final class SoftwareStatement extends Object
This class represents an OAuth2.0 Software Statement.

A Software Statement is a signed JWT containing metadata about the software being registered. See RFC 7591 Section 2.3 for more information.

  • Method Details

    • builder

      public static SoftwareStatement.Builder builder()
      Create a new SoftwareStatement.Builder to build SoftwareStatement objects.
      Returns:
      the Builder
    • getIssuer

      public String getIssuer()
      Get the issuer name of the Trusted Directory that issued the software statement.
      Returns:
      the issuer name
    • getOrganisationId

      public String getOrganisationId()
      Get the organisation ID.
      Returns:
      the organisation ID
    • getOrganisationName

      public String getOrganisationName()
      Get the organisation name.
      Returns:
      the organisation name
    • getSoftwareId

      public String getSoftwareId()
      Get the software ID.
      Returns:
      the software ID
    • getClientName

      public String getClientName()
      Get the client name.
      Returns:
      the client name
    • getSoftwareStatementAssertion

      public SignedJwt getSoftwareStatementAssertion()
      Get the software statement assertion. The SignedJwt used to create this object.
      Returns:
      the software statement assertion
    • getRoles

      public List<String> getRoles()
      Get the roles that this software is allowed to perform. Optional, returns an empty list of no roles associated.
      Returns:
      the roles
    • getJwkSetLocator

      public Choice<URI,JWKSet> getJwkSetLocator()
      Get the JWKSet locator. This represents where the JWKSet for this software can be found. This is either via URI or as a JWKSet embedded in the software statement.
      Returns:
      the JWKSet locator, a Choice representing either a URI where the JWKSet is hosted or a JWKSet value.
    • getRedirectUris

      public List<URI> getRedirectUris()
      Get the redirect URIs. These are a collection of URIs that an OAuth2.0 client registering with this software statement is allowed to request to be redirected to.
      Returns:
      the redirect URIs as a list of URIs
    • getClaim

      public <T> T getClaim(String claimName, Class<T> clazz)
      Retrieve a value for a claim from the software statement, this allows custom claims to be retrieved i.e. one that does not have a dedicated getter.
      Type Parameters:
      T - the type of the claim's value
      Parameters:
      claimName - the name of the claim to retrieve
      clazz - the expected class of the claim's value
      Returns:
      the value stored for the claimName cast as type T