Safe PHP uploader

August 10th, 2009

I had already been curios about php uploaders structure and was trying to learn basic concept of it , usually in simple cases uploader consists of two file ( can be included into one file ) - A HTML form and PHP file accepting the request , because of some security reasons the uploader must not permit user to upload ineligible files , it means it must prevent uplaoding files blacklisted but how ?

How does somebody know about probable holes for protecting his uploader against an attacker ? what must be done for providing a safe uploader ? these are why I was falling to write and research about common attacks and opposition ways of that .

Finally I wrote journal after I’d decided … uploader starts containing bugs - unsafe - that may be developed by beginner person including how to bypass them with PERL exploits and continues till becomes the secure one … Here are some methods used :

  1. Indirect access to the uploaded files
  2. bypassing image file content verification
  3. bypassing file name extension verification

Third one is more interesting ” Injection PHP codes into *.jpg file ”

The journal has been written in Persian language - Farsi - but maybe I’ll put piece of journal , either by explanation of PERL exploits , either security reasons or some important notes in English here …. I have to give notice before finishing , one of my best friends ( Amir - ScorpinO ) helped me write more than what ever you would think … the most appreciate for him . at last I’m telling you since the security is not an absolute thing , I am not responsible for my safe uploader !

Loading journal && loading tutorial clip wriiten by Sc0rpion , all rights reserved .

  1. Stevensoft
    January 2nd, 2009 at 16:58 | #1

    mmmm omg im trying to bypass a rsgallery image uploader but i couldt i have been doingit mnually and i m going to see if i can use this programs to do it thank youuuuuu.

  2. January 3rd, 2009 at 04:56 | #2

    At beginning you should see what is the structure of the target’s uploader for a exploit which have to be chosen or bypass it by manually .

  1. No trackbacks yet.