Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 6 of 6
  1. #1
    Registered User
    Join Date
    Jul 2005
    Posts
    3

    Default PHP Uploading Script blocking files with certain file extensions

    Hello,

    A client is attempting to create a PHP file upload script, but is only partly successful because PHP refuses to upload files with particular extensions. Examples include .jpg, .mp3, .png, etc. The client can, however, upload files with .txt, .html, .css, etc. I've already searched through Php.ini and increased the file upload limit, but the problem still exsists. I am assuming there is some configuration file that specifically limits the upload of files with certain extensions, but I am unsure of its location, if it exsists at all. Any assistance would be greatly welcome. Thank you so much.

    Regards,
    Chad

  2. #2
    Member
    Join Date
    Jul 2002
    Location
    Canada
    Posts
    675

    Default

    Do you have mod_security enabled? It can cause problems with uploads and can be configured to check uploads as well.
    Upload Guardian 2.0 - Sign up for our early beta
    ServerProgress - Server security, consulting and assistance

  3. #3
    Registered User
    Join Date
    Jul 2005
    Posts
    3

    Default

    I don't think so. I've seached httpd.conf, and mod_security isn't enabled.
    Last edited by cummings; 06-07-2006 at 05:08 PM.

  4. #4
    Member
    Join Date
    Feb 2004
    Posts
    203

    Default

    Yep, same problem on my server

  5. #5
    Member
    Join Date
    Feb 2004
    Posts
    95

    Default

    Careful...You don't always need to see it in the httpd.conf for it to be enabled. Make sure you also look for modsec.conf "grep modsec.conf httpd.conf".

  6. #6
    Registered User
    Join Date
    Jul 2005
    Posts
    3

    Default

    Nope, modsec.conf isn't present in my httpd.conf file.

Similar Threads & Tags
Similar threads

  1. antivirus.exim blocking file extensions
    By sparek-3 in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 06-22-2006, 10:45 AM
  2. Help, hacker uploading files /tmp with external PHP code
    By jeroman8 in forum cPanel and WHM Discussions
    Replies: 12
    Last Post: 05-29-2006, 11:50 AM
  3. Backup Script -- Ignoring certain file extensions?
    By justchil in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 10-12-2005, 02:07 PM
  4. Uploading files using PHP and ownership
    By Jeff75 in forum cPanel and WHM Discussions
    Replies: 3
    Last Post: 01-08-2005, 07:29 PM
  5. Uploading a PHP file, cPanel adds line of gobbly guk to top of file
    By railx in forum cPanel and WHM Discussions
    Replies: 5
    Last Post: 09-12-2004, 11:09 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube