From 28284f8725f557faaa551b4858481183975e0271 Mon Sep 17 00:00:00 2001 From: xdrm-brackets Date: Tue, 8 Nov 2016 10:41:27 +0100 Subject: [PATCH] fix cyclic hash algo --- build/api/core/Authentification.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build/api/core/Authentification.php b/build/api/core/Authentification.php index a742376..8c98537 100644 --- a/build/api/core/Authentification.php +++ b/build/api/core/Authentification.php @@ -99,9 +99,9 @@ return false; /* (3) Compares content */ - $hashed = self::secure_hash($fc); + $hashed = self::secure_hash($GLOBALS['TOKEN']); - if( strlen($hashed) !== 64 || $GLOBALS['TOKEN'] !== $hashed ) + if( strlen($hashed) !== 64 || $fc !== $hashed ) return false; /* (4) Stores new content */