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

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

[复制链接]
发表于 2007-11-16 12:13:14 | 显示全部楼层 |阅读模式
Keyboard Interrupt Hook using I/O APIC(ZT)
9 r+ X7 h" p- @$ K) O0 E# D2 ^7 J! U; R( g1 n9 r% l
Keyboard Interrupt Hook using I/O APIC
6 y- f' ~7 W' k1 c$ l
! F6 M5 ~2 |& F% j0 b& k2 R6 xBy: chpie
" V( v$ a, A0 D' o0 t8 BKeyboard Interrupt Hooking by manipulating the I/O APIC
$ |! f! M8 z& ytested on the winXP, Pentium D Hyper-threading Enabled.* |* y' f% E: d. \1 g4 ]

( Y% N+ t2 L0 N& b: A- ]; D( `, b) C/ V$ Q" B. B9 D1 P" L
Summary :: Using the 8259a compatible PIC to be deliver the interrupt
% h1 i! n% R- F( o3 l# usignal by Delivery mode of the I/O APIC to be the ExtINT,4 V5 r5 {. l" a3 v, l3 u- q
the interrupt related by the IRQ 1 able to be not refer% j7 X7 H$ C& |0 n- G# }2 h
the I/O APIC's Redirection Table.
8 e2 r7 c' M% m% x) P$ T
/ n& d2 h; |: @: T6 C% }7 d: r- It is higher priority of the hooking than the direct
! C6 j& |6 }/ ~: Qmodification of the I/O APIC's vector.
' V8 X3 w  B" b4 e8 D8 n- {- The vector can be hidden on the thread getting the keyboard& W  d- Y, k8 v/ n% u2 w% V2 B
vector from the I/O APIC.2 Y4 P0 X% }0 {; x7 I  n$ J% e

1 A! \2 y8 u- @3 [Flow ::
1 e1 ^5 d3 P9 n2 W+ O
* x: Z) g- j( p7 K0 T9 ~! _' J. D/ Y1. IRQ 1 Assert !!!7 t6 K+ L& Y. N" d: p; ^3 c
2. The I/O APIC receives the signal and refers the I/O Redirection table.
( w5 m2 p3 q( S3. Sending the signal from the destination Local APIC./ k2 F- G  s# M5 `0 |* N
4. Local APIC pass the signal to the processor for its delivery mode ExtINT
, d+ }: Q9 W+ z: \2 G7 {5. A processor receives the signal.
7 X& L8 B: M; z" g, S/ d6. The processor Assert the INTA signal.0 O' X2 h  M" \6 O; S# S& |  ?1 f
7. The I/O APIC acknowledged.
; ^, V% u3 ?  H/ z" Q$ R6 J8. The processor Assert the second INTA signal.
# [0 L' S. i4 |. m7 ~9. The I/O APIC delivers the signal to the 8259a compatible PIC
9 Q3 N6 f' }# V1 P$ Zfor ExtINT to its Delivery mode.4 D. L5 Q  Y! B- z
10. 8259a compatible PIC sends 2 bytes after second INTA pulse.) n, l4 l8 H4 e# ?" M; k: I0 s
11. The processor execute 2 bytes sended.2 [. X: D, O9 d; X. ~' s7 V; @% Z% V
12. our interrupt handler executed.4 j/ |2 ~; Z. A& T* X8 D

4 F* Y: E& J3 C  ^$ {
3 @$ l% U5 W5 Gsourcecode and binary are available on the% A- K! V. R- `. z. F% W) G( F0 A: x
http://www.rootkit.com/vault/chpie/apic_keyboard.zip

本帖子中包含更多资源

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

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

本版积分规则

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

GMT+8, 2025-12-1 00:49 , Processed in 0.788509 second(s), 18 queries .

Powered by Discuz! X3.5

© 2001-2025 Discuz! Team.

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