# HG changeset patch # User Matthew Wild # Date 1530532543 -3600 # Node ID 3797be8f491fcde44da502989c5deebec61c6d08 # Parent 887a8100343a0a73571686c064cafe8313137419 share_v2.php: Fix syntax errors diff -r 887a8100343a -r 3797be8f491f mod_http_upload_external/share_v2.php --- a/mod_http_upload_external/share_v2.php Mon Jul 02 12:52:59 2018 +0100 +++ b/mod_http_upload_external/share_v2.php Mon Jul 02 12:55:43 2018 +0100 @@ -87,7 +87,7 @@ } $calculated_token = hash_hmac('sha256', "$upload_file_name\0$upload_file_size\0$upload_file_type", $CONFIG_SECRET); - if(function_exists('hash_equals') { + if(function_exists('hash_equals')) { if(hash_equals($calculated_token, $upload_token) !== TRUE) { header('HTTP/1.0 403 Forbidden'); exit; @@ -129,9 +129,9 @@ header('Content-Disposition: attachment'); header('Content-Type: '.$mime_type); header('Content-Length: '.filesize($store_file_name)); - header('Content-Security-Policy: "default-src \'none\'"'); - header('X-Content-Security-Policy: "default-src \'none\'"'); - header('X-WebKit-CSP: "default-src 'none'"'); + header("Content-Security-Policy: \"default-src 'none'\""); + header("X-Content-Security-Policy: \"default-src 'none'\""); + header("X-WebKit-CSP: \"default-src 'none'\""); if($request_method !== 'HEAD') { readfile($store_file_name); }