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

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

[复制链接]
发表于 2007-11-16 12:13:14 | 显示全部楼层 |阅读模式
Keyboard Interrupt Hook using I/O APIC(ZT)% k  o. I# h; O# N* [- }
5 \5 x! z6 f* o
Keyboard Interrupt Hook using I/O APIC
2 {- g- c1 @; E8 n: V4 b) K% U
6 g0 V1 u) K8 h+ ]By: chpie
  q" g. v: [+ e5 I4 M" UKeyboard Interrupt Hooking by manipulating the I/O APIC
" n5 g6 {/ ?' w0 `7 u. i$ Etested on the winXP, Pentium D Hyper-threading Enabled.
* m: W: s* a) ?  s: `& _$ q3 C+ R$ A: z6 y5 K9 W0 S; b/ s* ^
/ t  ~, B( Z1 r% [) d: f
Summary :: Using the 8259a compatible PIC to be deliver the interrupt
7 J* }3 @7 c2 @4 r: R* Lsignal by Delivery mode of the I/O APIC to be the ExtINT,
3 r* S% O, Z1 `. \+ j- x0 athe interrupt related by the IRQ 1 able to be not refer' {7 e- s! ]7 L  G: w
the I/O APIC's Redirection Table.: M- F8 I  K% M0 x3 b
# S( k- t. C$ @) b* q' v# P+ b
- It is higher priority of the hooking than the direct# ?" m2 k7 f1 d1 l% I$ o- A" v6 t
modification of the I/O APIC's vector.6 S7 ]+ T; X/ m2 H2 C2 S6 N
- The vector can be hidden on the thread getting the keyboard9 i' K$ g+ o( b2 q0 g/ s5 G
vector from the I/O APIC.
# w% C( m! K* ?* t$ O. R+ a1 ]
$ H8 Z* b  e: |1 e# @* c9 p% c4 fFlow ::+ p/ f$ o( V$ O9 I9 @

& R1 l  B* H9 A  a: P8 f. T1. IRQ 1 Assert !!!
) g6 m/ |) W0 s3 S8 e2. The I/O APIC receives the signal and refers the I/O Redirection table.* @4 z* @; G+ P) s, K7 {8 T
3. Sending the signal from the destination Local APIC.
3 A' |% G( r, B6 K& t2 g9 G4 q* a9 S4. Local APIC pass the signal to the processor for its delivery mode ExtINT1 q( Z4 v6 Y, l. _1 S6 ^3 O2 [
5. A processor receives the signal.
4 P# n# a& p" N( P, D, l6. The processor Assert the INTA signal.
4 c/ }! x# P* s9 P) v' x2 _( o, g2 b7. The I/O APIC acknowledged.$ y! O5 r0 u2 N4 k. }3 l) G( t* I
8. The processor Assert the second INTA signal.! D# e* T( F) T$ H
9. The I/O APIC delivers the signal to the 8259a compatible PIC
; ^" l( I$ {" _" N' afor ExtINT to its Delivery mode.
5 ~! Q$ ?5 e& P! v  O/ u& O1 h+ C  Y10. 8259a compatible PIC sends 2 bytes after second INTA pulse." C* _/ v9 U& Z) R; B/ a; Q% M/ t$ S
11. The processor execute 2 bytes sended.$ r9 C) C4 u- W% S0 F
12. our interrupt handler executed.
, L3 b" B9 N5 X2 m
  i: Y4 s" e5 \% S5 q  H% Y- P# v/ z
sourcecode and binary are available on the8 F3 k0 r; F3 p* Y# W( M
http://www.rootkit.com/vault/chpie/apic_keyboard.zip

本帖子中包含更多资源

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

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

本版积分规则

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

GMT+8, 2026-3-5 12:49 , Processed in 0.059495 second(s), 18 queries .

Powered by Discuz! X3.5

© 2001-2025 Discuz! Team.

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