• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
file upload allowing wrong formats?

greetings, i'm having a bit of a problem: i'm developing a file upload mechanism for a customer, and it needs to allow a specific subset of files.

i got up to the point of specifying the mime types for the desired formats, but then i encountered a problem in which the application is accepting files seemingly at random. here are my allowed extensions:

define('ALLOWED_TYPES', 'doc|docx|xlsx|pptm|xlsm|docm|pptx|accdb|xls|pdf|txt|zip|rtf|ppt|jpg|accdb|');

here's the weird thing: no matter what i define as the allowed filetypes, the app will upload them seemingly on its own, and at one point it was even loading exe files. what am i doing wrong, are my configuration settings being ignored? i'm stumped at this point, any help would be much appreciated.

anyone? i really don't mean to be rude, but i'd like to get this working before the weekend, any insight is welcome.

i think you find you're answer here:

[quote author="Razedd" date="1284146132"]i think you find you're answer here:

actually i found out what it was: the previous developer mucked around with the framework's main libs, and with the intention of "fixing" an unspecified bug in the upload library he messed up the format recognition (it was detecting the file extension according to the mime type, which is WRONG). thanks anyway and sorry for wasting your time.

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.