Mime detection fails when Suhosin is enabled

See all posts Reply

Mime detection fails when Suhosin is enabled new!
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.Reply
Re: Mime detection fails when Suhosin is enabled new!
by colin, 12 years, 6 months ago
Thank you, I will implement this in the next release.Reply
Re: Mime detection fails when Suhosin is enabled new!
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?Reply
Re: Mime detection fails when Suhosin is enabled new!
by colin, 12 years, 1 month ago
For the time being, you can set $this->mime_file to false in the init() function.Reply