Mime detection fails when Suhosin is enabled
Mime detection fails when Suhosin is enabled new!
# Reply
by Lefteris Kavadas, 12 years, 6 months ago
When the class tries to detect the mime type using exec function there is an issue. When the server is using the Suhosin extension (http://www.hardened-php.net/suhosin/) then the function_exists('exec') returns true but the function (maybe, depending on Suhosin configuration) is actually disabled. This causes the class to break when calling the exec function. A simple solution is to add a check for Suhosin. In order to detect if Suhosin is installed you can call extension_loaded('suhosin'). If you want to take the disabled Suhosin functions you can use ini_get("suhosin.executor.func.blacklist"). It would be great to see a fix for this in a next release.
Re: Mime detection fails when Suhosin is enabled new!
# Reply
by colin, 12 years, 6 months ago
Thank you, I will implement this in the next release.
Re: Mime detection fails when Suhosin is enabled new!
# Reply
by Taner, 12 years, 1 month ago
Yes same issuue for me so if we dont want to use mime-check in verot upload class what can we do?
Re: Mime detection fails when Suhosin is enabled new!
# Reply
by colin, 12 years, 1 month ago
For the time being, you can set $this->mime_file to false in the init() function.