OPTokenAudience
This profile configuration was introduced in V3.1 of this plugin in support of use cases involving access tokens issued to resource servers.
File(s): conf/relying-party.xml, conf/oidc.properties
Format: Native Spring, Spring Properties
Overview
The OAUTH2.TokenAudience profile configuration bean enables support for uses of the OAUTH 2 Token endpoint in which access tokens are being issued to resource servers rather than the client, as in OIDC. It supports generic use of the IdP as an OAuth Authorization Server.
At present, the only supported use case is the client_credentials grant type, in which the client directly requests a token for a resource server. This profile configuration represents the resource server role in this interaction and controls various settings of relevance to the resource server rather than to the client (which is represented by the OIDC.Token profile configuration).
Note that while OAuth in theory allows for tokens to be issued to multiple resource servers, this is not in practice well handled (e.g., encrypting a JWT can only be done to a single key given the JWT serialization format permitted by the RFC governing JWT access tokens). This implementation treats the “primary” resource server/audience as the entity to which the profile configuration is meant to apply.
Configuration
The most typical options used are described in more detail below, but not every obscure option is discussed. See the javadoc for all of the possible configuration options for this profile (note that some of them are inherited from parent classes).
Virtually all the configuration options below can be set via two different properties: a static property that explicitly sets the value to use and a lookup strategy or predicate property that takes a Function or Predicate and returns the value to use. The dynamic property is generally named "propertyNamePredicate" or "propertyNameLookupStrategy" for Boolean- and non-Boolean-valued properties respectively.