From 86764f52f4877ce7a73876506ea69112ca9c5ea6 Mon Sep 17 00:00:00 2001 From: suneth-perera <101696988+suneth-perera@users.noreply.github.com> Date: Tue, 31 Oct 2023 10:38:37 +1100 Subject: [PATCH 1/2] Update JWT.php --- src/JOSE/JWT.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/JOSE/JWT.php b/src/JOSE/JWT.php index a18c35d..beb7f2b 100644 --- a/src/JOSE/JWT.php +++ b/src/JOSE/JWT.php @@ -1,6 +1,15 @@ 'JWT', 'alg' => 'none' From af54e7e6692125e8eaacf4300ba89afba6487adc Mon Sep 17 00:00:00 2001 From: suneth-perera <101696988+suneth-perera@users.noreply.github.com> Date: Tue, 31 Oct 2023 10:40:00 +1100 Subject: [PATCH 2/2] Update JWE.php --- src/JOSE/JWE.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/JOSE/JWE.php b/src/JOSE/JWE.php index 964d8ce..8c93701 100644 --- a/src/JOSE/JWE.php +++ b/src/JOSE/JWE.php @@ -82,7 +82,7 @@ private function cipher() { throw new JOSE_Exception_UnexpectedAlgorithm('Algorithm not supported'); case 'A128CBC-HS256': case 'A256CBC-HS512': - $cipher = new AES(AES::MODE_CBC); + $cipher = new AES(self::MODE_CBC); break; default: throw new JOSE_Exception_UnexpectedAlgorithm('Unknown algorithm'); @@ -90,7 +90,7 @@ private function cipher() { switch ($this->header['enc']) { case 'A128GCM': case 'A128CBC-HS256': - $cipher->setBlockLength(128); + //$cipher->setBlockLength(128); break; case 'A256GCM': case 'A256CBC-HS512':