You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jan 29, 2021. It is now read-only.
Sidenote: I'm using transit via deprecaed CakePHP Uploader Plugin on Linux.
Imagine an URL like:
http://server/image.php?id=12312\Transit\File::type()will perform the following steps:$typeis first determined viafile -b --mime ...and gets detected asimage$ext = $file->ext()will returntext/x-php$type !== $extType$typewill be forced to be the file extension type, basically ignoring the actual content typeThis behaviour is problematic as serving an image via such an URLs is perfectly legit.
One approach could be to only use the extension if either the
file -b --mime...and thefinfo_file()logic do not work.