Skip to content

Commit

Permalink
Fix missing key
Browse files Browse the repository at this point in the history
  • Loading branch information
mimrock committed Oct 21, 2021
1 parent 5fd133d commit f320562
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion phpThumb.php
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ function RedirectToCachedFile() {
} elseif (phpthumb_functions::PasswordStrength($phpThumb->config_high_security_password) < 20) {
$phpThumb->config_disable_debug = false; // otherwise error message won't print
$phpThumb->ErrorImage('ERROR: $PHPTHUMB_CONFIG[high_security_password] is not complex enough');
} elseif ($_GET['hash'] != hash_hmac('sha256', str_replace($phpThumb->config_high_security_url_separator.'hash='.$_GET['hash'], '', $_SERVER['QUERY_STRING']).$phpThumb->config_high_security_password)) {
} elseif ($_GET['hash'] != hash_hmac('sha256', str_replace($phpThumb->config_high_security_url_separator.'hash='.$_GET['hash'], '', $_SERVER['QUERY_STRING']), $phpThumb->config_high_security_password)) {
header('HTTP/1.0 403 Forbidden');
$phpThumb->ErrorImage('ERROR: invalid hash');
}
Expand Down

0 comments on commit f320562

Please sign in to comment.