diff --git a/src/Illuminate/Routing/UrlGenerator.php b/src/Illuminate/Routing/UrlGenerator.php index 49b8c78a89a0..9f933fc67d51 100755 --- a/src/Illuminate/Routing/UrlGenerator.php +++ b/src/Illuminate/Routing/UrlGenerator.php @@ -349,7 +349,7 @@ public function hasValidSignature(Request $request) $signature = hash_hmac('sha256', $original, call_user_func($this->keyResolver)); - return hash_equals($signature, $request->query('signature', '')) && + return hash_equals($signature, (string) $request->query('signature', '')) && ! ($expires && Carbon::now()->getTimestamp() > $expires); }