Skip to content

Commit d164e93

Browse files
authored
Merge pull request #180 from ErfaNEP1/master
Fixed RefreshToken mutation
2 parents 760be47 + 09735b3 commit d164e93

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

src/GraphQL/Mutations/RefreshToken.php

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,15 @@ public function parseToken($accessToken)
4949
{
5050
// since we are generating the token in an internal request, there
5151
// is no need to verify signature to extract the sub claim
52+
$appKey = explode(':', config('app.key'));
53+
54+
if (! isset($appKey[1])) {
55+
return false;
56+
}
57+
5258
$config = Configuration::forSymmetricSigner(
5359
new Blake2b(),
54-
InMemory::plainText('refresh-token')
60+
InMemory::base64Encoded($appKey[1])
5561
);
5662

5763
$token = $config->parser()->parse((string) $accessToken);

0 commit comments

Comments
 (0)