Subversion Repositories eFlore/Applications.coel

Rev

Rev 1952 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1952 Rev 1956
Line 431... Line 431...
431
	 * @param String $jeton un jeton JWT précédemment validé
431
	 * @param String $jeton un jeton JWT précédemment validé
432
	 */
432
	 */
433
	protected function decoderJeton($jeton) {
433
	protected function decoderJeton($jeton) {
434
		$parts = explode('.', $jeton);
434
		$parts = explode('.', $jeton);
435
		$payload = $parts[1];
435
		$payload = $parts[1];
436
		$payload = base64_decode($payload);
436
		$payload = base64_decode(str_pad(strtr($payload, '-_', '+/'), strlen($payload) % 4, '=', STR_PAD_RIGHT));
437
		$payload = json_decode($payload, true);
437
		$payload = json_decode($payload, true);
Line 438... Line 438...
438
	
438
	
439
		return $payload;
439
		return $payload;