Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Unverified Commit 3909199b authored by Akhil's avatar Akhil 🙂
Browse files

Use hash_equals

parent 08fbdb78
Loading
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -136,6 +136,6 @@ class UserController extends ApiController {

	private function checkAppCredentials(string $token): bool {
		$ecloud_accounts_secret = $this->userService->getConfigValue('secret');
		return strcmp($token, $ecloud_accounts_secret) === 0;
		return hash_equals($ecloud_accounts_secret, $token);
	}
}