trait InteractsWithJwks

Properties

protected null|array{url: string, algorithm: string, keys: array, expiresAt: int} $jwks

The parsed JSON Web Key Set for the current URI.

protected null|array{url: string, algorithm: string, attemptedAt: int} $jwksRefreshAttempt

The last forced refresh attempt.

protected int $jwksRefreshCooldownSeconds

The minimum seconds between forced JWKS refreshes.

protected int $jwksDefaultTtlSeconds

The fallback lifetime for JWKS responses without cache directives.

Methods

string
getJwksUri(bool $refresh = false)

Get the JSON Web Key Set URI for the provider.

array
decodeUsingJwks(string $token)

Decode a token using the provider's JSON Web Key Set.

Details

at line 47
abstract protected string getJwksUri(bool $refresh = false)

Get the JSON Web Key Set URI for the provider.

Parameters

bool $refresh

Return Value

string

at line 52
protected array decodeUsingJwks(string $token)

Decode a token using the provider's JSON Web Key Set.

Parameters

string $token

Return Value

array