Skip to content

Commit aebb3b5

Browse files
nickvergessenbackportbot[bot]
authored andcommitted
fix: Correctly check result of function
Signed-off-by: Joas Schilling <coding@schilljs.com> [skip ci]
1 parent f816957 commit aebb3b5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/private/Security/IdentityProof/Signer.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,12 +93,12 @@ public function verify(array $data): bool {
9393
$user = $this->userManager->get($userId);
9494
if ($user !== null) {
9595
$key = $this->keyManager->getKey($user);
96-
return (bool)openssl_verify(
96+
return openssl_verify(
9797
json_encode($data['message']),
9898
base64_decode($data['signature']),
9999
$key->getPublic(),
100100
OPENSSL_ALGO_SHA512
101-
);
101+
) === 1;
102102
}
103103
}
104104

0 commit comments

Comments
 (0)