Skip to content
Snippets Groups Projects
Commit be538832 authored by Dominik Hebeler's avatar Dominik Hebeler
Browse files

Fixed a bug in humanprotection

parent aea7af72
No related branches found
No related tags found
Loading
...@@ -168,7 +168,7 @@ class HumanVerification extends Controller ...@@ -168,7 +168,7 @@ class HumanVerification extends Controller
private static function checkId($request, $id) private static function checkId($request, $id)
{ {
if (hash("sha512", $request->ip() . $_SERVER["AGENT"]) === $id) { if (hash("sha512", $request->ip() . $_SERVER["AGENT"] . "uid") === $id) {
return true; return true;
} else { } else {
return false; return false;
......
...@@ -27,7 +27,7 @@ class HumanVerification ...@@ -27,7 +27,7 @@ class HumanVerification
$redis = Redis::connection('redisCache'); $redis = Redis::connection('redisCache');
try { try {
$id = hash("sha512", $request->ip()); $id = hash("sha512", $request->ip());
$uid = hash("sha512", $request->ip() . $_SERVER["AGENT"]); $uid = hash("sha512", $request->ip() . $_SERVER["AGENT"] . "uid");
unset($_SERVER["AGENT"]); unset($_SERVER["AGENT"]);
/** /**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment