Course contentsShow
← Security
Lesson 1551 of 3,05231. Operating System Security - MalwareFree lesson

Import Address Table (IAT) and Export Address Table Hooking

Manipulating function pointer tables to intercept API calls at the user-mode and kernel-mode boundary.

Import Address Table (IAT) and Export Address Table Hooking

You'll learn how malware intercepts API calls by modifying function pointer tables before the operating system or application even knows the real function address.

What Are IAT and EAT?

When a Windows program wants to call a function from a DLL (like CreateFile from kernel32.dll), it doesn't hardcode the function's memory address. Instead, it uses a lookup table:

  • Import Address Table (IAT): The calling program's table of pointers to external functions it needs. Think of it as your phone's contact list pointing to actual phone numbers.
  • Export Address Table (EAT): The DLL's table advertising which functions it offers and where they're located. This is like the phone company's directory.

How Hooking Works

IAT Hooking happens when malware rewrites entries in the caller's import table to point to malicious code instead of the legitimate function. When your program thinks it's calling recv() to receive network data, it's actually calling the attacker's monitoring function first.

EAT Hooking modifies the DLL's export table itself, affecting all programs that import from that DLL. This is like changing the master phone directory so everyone gets the wrong number.

Why Attackers Use This

Unlike inline hooking (which modifies function code directly), table hooking is stealthier and easier to implement. The actual function code remains untouched—only the pointer changes. It operates at the user-mode/kernel-mode boundary by intercepting the transition points where applications request OS services.

Key Takeaway: IAT and EAT hooking redirect API calls by manipulating function pointer tables rather than function code, making them effective persistence and evasion techniques that are harder to detect than direct code modifications.