Mayk0

GetSimple CMS 3.2.1 Arbitrary File Upload / Cross Site Scrip

May 6th, 2013
333
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.67 KB | None | 0 0
  1.  
  2. Full title: GetSimple CMS 3.2.1 Arbitrary File Upload / Cross Site Scripting
  3. Date add: 2013-05-06
  4. Category: web applications
  5. Verified: Not verified yet
  6. Platform: php
  7. Description:
  8. GetSimpleCMS version 3.2.1 suffers from a persistent cross site scripting vulnerability and remote arbitrary file upload vulnerability due to not using whitelisting.
  9. -------------------------------------------------------------------
  10.  
  11.  
  12. GetSimpleCMS Version 3.2.1 Arbitrary File Upload / Cross Site Scripting Vulnerabilities
  13. ===================================================================================
  14. # Exploit Title: GetSimpleCMS Version 3.2.1 Arbitrary File Upload Vulnerability
  15. # Download link: http://code.google.com/p/get-simple-cms/
  16. # version: 3.2.1
  17. # Category: webapps
  18. # Tested on: ubuntu 13.4
  19. # Author: Ahmed Elhady Mohamed
  20. # Website: www.itsec4all.com
  21. ===================================================================================
  22. Description:
  23. - GetSimpleCMS Version 3.2.1 suffers from arbitrary file upload vulnerability which allows an attacker to upload a HTML page.
  24. - The main reason of this vulnerability is that the application uses a blacklist technique to compare the file aganist mime types and extensions.
  25. - If the mime type or the extension is in the blacklist array , the application won't upload it.
  26.  
  27. Exploit:
  28. - For exploiting this vulnerability we will create a file with mutiple extensions for example "exploit.html.fr"
  29. - The application will check the mime type and extension of the file which is "fr" aganist the blacklist array mime type and extensions.
  30. - and ofcourse "fr" extension won't be in the blacklist array so the application will upload it successfully.
  31. - The uploaded file will be under the "data/uploads/" folder.
  32.  
  33. Solution:
  34. - The application should use whitelisting technique which compare the file extensions and mime types aganist
  35. - acceptable mime types and extensions for more information google for "whitelisting vs blacklisting"
  36.  
  37. Stored XSS Vulnerability:
  38.  
  39. Page: edit.php
  40. Desc: inject your javascript code in "Page Title" field.
  41. POC: test" onClick="alert(/HackedByAhmed-Elhady-Mohamed/)
  42.  
  43. Page: edit.php
  44. Desc: click on page option then check "add this page to the menu" then inject your javascript code in "post-menu"" field.
  45. POC: <script>alert(/HackedByAhmed-Elhady-Mohamed/)</script>
  46.  
  47. page: settings.php
  48. Desc: inject javascript event in "Custom Permalink Structure" field
  49. POC: test" onClick="alert(/HackedByAhmed-Elhady-Mohamed/)
  50.  
  51. page: settings.php
  52. Desc: inject javascript event in "Display name" field
  53. POC: test" onClick="alert(/HackedByAhmed-Elhady-Mohamed/)
Advertisement
Add Comment
Please, Sign In to add comment