找回密码
 加入计匠网
搜索
热搜: BIOS ACPI CPU Windows
查看: 15188|回复: 0

[转载]Keyboard Interrupt Hook using I/O APIC

[复制链接]
发表于 2007-11-16 12:13:14 | 显示全部楼层 |阅读模式
Keyboard Interrupt Hook using I/O APIC(ZT)
" t1 R, M  Q% e8 O9 s8 z
" l! D8 A/ t3 LKeyboard Interrupt Hook using I/O APIC
+ F& _9 W- S3 N, g3 g$ N0 }. H; c3 f% J% p
By: chpie
) `2 |. |; E+ F6 BKeyboard Interrupt Hooking by manipulating the I/O APIC2 V1 T; L+ x: Z: S7 D1 S, K
tested on the winXP, Pentium D Hyper-threading Enabled.
) J: v! v' f9 `& v7 f- j* a0 _+ w! _4 N' V9 u; O) }

1 O$ R& W; T; r: i8 p! U* dSummary :: Using the 8259a compatible PIC to be deliver the interrupt. c2 r" m% b) w3 d- Q% M
signal by Delivery mode of the I/O APIC to be the ExtINT,
7 D/ R) h' Y  r& Tthe interrupt related by the IRQ 1 able to be not refer0 d% p/ ]( ~( f# N% X
the I/O APIC's Redirection Table.  P$ p0 U) P2 [, ^
; j7 G' L3 `/ K- W
- It is higher priority of the hooking than the direct+ m% m1 s1 j9 v9 Y
modification of the I/O APIC's vector.- R+ ^4 Z! l) P4 v* b
- The vector can be hidden on the thread getting the keyboard  W3 T6 j8 n' |1 d
vector from the I/O APIC.
) L" G$ _' l$ D2 u4 D
/ `7 x, {9 j% j6 m; i! zFlow ::
3 G% @0 n8 x+ h- }
4 r$ Z/ h1 m* t4 j: a( ^# r1. IRQ 1 Assert !!!
+ Z! `0 F, W# N7 i& R7 Y1 b- x( T2. The I/O APIC receives the signal and refers the I/O Redirection table.
# u1 B: U5 \4 j% p6 D. r) B3. Sending the signal from the destination Local APIC.
$ A) V: Q9 H* y5 ?# ^! A( u$ Z4. Local APIC pass the signal to the processor for its delivery mode ExtINT
- a2 F9 k1 D/ m5 D/ m8 q5. A processor receives the signal.
3 t" l* s# I6 `! @* _# @" T: m6 S6. The processor Assert the INTA signal.) Z8 }& _2 w4 _
7. The I/O APIC acknowledged.
* G& B2 j5 y, M9 L. R8. The processor Assert the second INTA signal.& ^8 C; x  O2 ~0 c
9. The I/O APIC delivers the signal to the 8259a compatible PIC0 T, J2 Y: ^8 s& {: ]( }
for ExtINT to its Delivery mode.5 V6 h2 ^5 i' u. M% N% v
10. 8259a compatible PIC sends 2 bytes after second INTA pulse.
0 ?. j) {9 E! X/ a( F11. The processor execute 2 bytes sended.
6 i: H% Z# m1 q2 c/ w3 S+ T12. our interrupt handler executed.1 A  r' @  D# K$ j6 Z

- E$ K8 O( e4 M$ g! b1 h) x3 \1 @
) y4 z2 \% c' _# qsourcecode and binary are available on the
: `$ F* l) R6 G) H# t% t$ {http://www.rootkit.com/vault/chpie/apic_keyboard.zip

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?加入计匠网

×
您需要登录后才可以回帖 登录 | 加入计匠网

本版积分规则

Archiver|手机版|小黑屋|计匠网

GMT+8, 2026-9-22 10:00 , Processed in 0.144979 second(s), 18 queries .

Powered by Discuz! X3.5

© 2001-2025 Discuz! Team.

快速回复 返回顶部 返回列表