Requires a valid access token for the request, accepted either as a Bearer JWT (validated directly against the configured
oauth2 client's JWKS) or, when no bearer token is present, via that client's normal session/login flow. After a successful session flow the request still passes through JWT validation before continuing.
Syntax Copy requireAuth : expectedAud : <string> oauth2 : <string> errorStatus : <int> expectedTid : <string> required : <boolean> scope : <string>
requireAuth:
expectedAud: <string> # required
oauth2: <string> # required
errorStatus: <int>
expectedTid: <string>
required: <boolean>
scope: <string>
Attributes Name Required Default Description Examples errorStatus false - HTTP status code to answer with, instead of redirecting the browser to the login page, when the request carries no usable session. - expectedAud true - Expected aud (audience) claim value that a presented JWT must contain. - expectedTid false - Expected value of the tid (tenant ID) claim of a presented JWT, for identity providers that issue tokens per tenant. - oauth2 true - The oauth2 client interceptor supplying the JWKS and the session/login flow used when no bearer token is present. - required false true Whether authentication is enforced. When false, a request that fails the oauth2 session/redirect flow is allowed to continue anyway. - scope false - OAuth2 scope the access token is requested for. A session that holds no token for this scope triggers a login or a refresh. -
Can be used in