Skip to content

Commit 8d2b0c1

Browse files
AC-12485: Improper JWT validation
1 parent 022e64b commit 8d2b0c1

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

app/code/Magento/JwtUserToken/Model/SecretBasedJwksFactory.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ class SecretBasedJwksFactory
3535
public function __construct(DeploymentConfig $deploymentConfig, JwkFactory $jwkFactory)
3636
{
3737
$this->keys = preg_split('/\s+/s', trim((string)$deploymentConfig->get('crypt/key')));
38+
$this->keys = [end($this->keys)];
3839
//Making sure keys are large enough.
3940
foreach ($this->keys as &$key) {
4041
$key = str_pad($key, 2048, '&', STR_PAD_BOTH);

0 commit comments

Comments
 (0)