Skip to content
Snippets Groups Projects
Commit 4f408b8f authored by aydreeihn's avatar aydreeihn Committed by GitHub
Browse files

Exclude Vulnerable Image Files

Extend this to exclude image files that are injectable from opening in browser windows.
parent a81664ce
No related branches found
No related tags found
No related merge requests found
......@@ -106,7 +106,7 @@ class Http {
}
function download($filename, $type, $data=null, $disposition='attachment') {
if (strpos($type, 'image/') !== 0)
if (strpos($type, 'image/') !== 0 || preg_match('/image\/.*\+.*/', $type))
$disposition='attachment';
header('Pragma: private');
......
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