[eluser]eroy4u[/eluser]
[quote author="gtech" date="1213770172"]Just because a file is named .ppt does not mean it is a powerpoint presentation. for example if you named a Jpeg image.jpg to image.ppt the file will still be a jpeg. the extension just tells the operation system what application to open when viewing.. if you loaded the image.ppt in a art package the jpeg will still appear.[/quote]
thanks a lot, I understand.
so I guess the solution to restrict file types is to check
1. file extension
2. mime type match that extension
but CodeIgniter is not doing this way, it only checks the mime type, if I add "application/octet-stream" to "ppt" in mimes.php,
many file types of mime type "application/octet-stream" can be uploaded!
I think this is a big bug?