This class allow to generate JSON Web Tokens and check if the user provided token is valid
Namespace Domframework
/** Allow to manage the JSON Web Tokens Based on https://tools.ietf.org/html/rfc7519 Do not put confidential data in payload without encrypt it, as the result is only a Base64 format of JSON...
No property available
/**
 Create a signing key
 @return string the signing key proposed
/** Decode the provide JWT and return an array of the payload@param string $jwtThe token to examine@param string $keyThe key used to sign the message@param array|null $allowedAlgList of allowed algorithms. If null, all the algorithms defined in $this->supportedAlgs are allowed@param string|null $ckeyThe cipher key to decrypt the payload@param string|null $cipherMethodThe method to cipher the payload des-ede3-cbc by default@returnarray the decoded payload @throw Exception if the key is not able to verify the token with the provided password
/** Create the token based on payload, sign it with key, and optionally encrypt it with ckey Do not put confidential data in payload without encrypt it, as the result is only a Base64 format of JSON...@param array $payloadThe payload to store@param string $keyThe key to be used to sign the token@param string|null $algThe algorithm to use to sign the token (default is HS256) Allowed algorithms : HS256, HS512, HS384@param string|null $ckeyThe cipher key to encrypt the payload@param string|null $cipherMethodThe method to cipher the payload des-ede3-cbc by default@returnstring The Token