From 76548f8cf091e9d50f74ae73c1bbeeb82adc2ac5 Mon Sep 17 00:00:00 2001 From: Dominique Fournier Date: Fri, 24 May 2019 09:14:57 +0000 Subject: [PATCH] jwt : update docs and folding git-svn-id: https://svn.fournier38.fr/svn/ProgSVN/trunk@5285 bf3deb0d-5f1a-0410-827f-c0cc1f45334c --- jwt.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/jwt.php b/jwt.php index eaa3136..3c4a429 100644 --- a/jwt.php +++ b/jwt.php @@ -25,6 +25,7 @@ class jwt * @param string $key The key to be used to sign the token * @param string|null $alg The algorithm to use to sign the token (default * is HS256) + * Allowed algorithms : HS256, HS512, HS384 * @return string The Token */ public function encode ($payload, $key, $alg = "HS256") @@ -54,6 +55,7 @@ class jwt * provided password */ public function decode ($jwt, $key, $allowedAlg = null) + // {{{ { if ($allowedAlg === null) $allowedAlg = array_keys ($this->supportedAlgs); @@ -95,6 +97,7 @@ class jwt "JWT Signature verification failed"), 403); return $payload; } + // }}} /** Verify the provided token with the key and generate an return true if it * can be verify