|
MediaWiki master
|
JwtCodec using lcobucci/jwt with an RSA key ($wgJwtPublicKey / $wgJwtPrivateKey). More...
Inherits MediaWiki\Json\JwtCodec.

Public Member Functions | |||
| __construct (private ServiceOptions $serviceOptions) | |||
| create (array $claims) | |||
| Creates a JWT string with the given claims. | |||
| isEnabled () | |||
| Whether the codec can be used (disabled means it hasn't been properly configured).All other methods will throw on a disabled JwtCodec. | |||
| parse (string $jwt) | |||
Parses and partially validates a JWT string, and returns the set of claim inside it.The validation covers the signature and time fields; other checks are left to the caller.
| |||
Public Attributes | |
| const | CONSTRUCTOR_OPTIONS |
JwtCodec using lcobucci/jwt with an RSA key ($wgJwtPublicKey / $wgJwtPrivateKey).
Definition at line 27 of file RsaJwtCodec.php.
| MediaWiki\Json\RsaJwtCodec::__construct | ( | private ServiceOptions | $serviceOptions | ) |
Definition at line 35 of file RsaJwtCodec.php.
| MediaWiki\Json\RsaJwtCodec::create | ( | array | $claims | ) |
Creates a JWT string with the given claims.
Implements MediaWiki\Json\JwtCodec.
Definition at line 48 of file RsaJwtCodec.php.
| MediaWiki\Json\RsaJwtCodec::isEnabled | ( | ) |
Whether the codec can be used (disabled means it hasn't been properly configured).All other methods will throw on a disabled JwtCodec.
Implements MediaWiki\Json\JwtCodec.
Definition at line 42 of file RsaJwtCodec.php.
| MediaWiki\Json\RsaJwtCodec::parse | ( | string | $jwt | ) |
Parses and partially validates a JWT string, and returns the set of claim inside it.The validation covers the signature and time fields; other checks are left to the caller.
| JwtException | If the JWT is invalid (expired, has invalid signature or can't even be parsed). |
Implements MediaWiki\Json\JwtCodec.
Definition at line 62 of file RsaJwtCodec.php.
| const MediaWiki\Json\RsaJwtCodec::CONSTRUCTOR_OPTIONS |
Definition at line 30 of file RsaJwtCodec.php.