Adversaries may obfuscate then dynamically resolve API functions called by their malware in order to conceal malicious functionalities and impair defensive analysis. Malware commonly uses various Native API functions provided by the OS to perform various tasks such as those involving processes, files, and other system artifacts.
API functions called by malware may leave static artifacts such as strings in payload files. Defensive analysts may also uncover which functions a binary file may execute via an import address table (IAT) or other structures that help dynamically link calling code to the shared modules that provide functions.[1][2]
To avoid static or other defensive analysis, adversaries may use dynamic API resolution to conceal malware characteristics and functionalities. Similar to Software Packing, dynamic API resolution may change file signatures and obfuscate malicious API function calls until they are resolved and invoked during runtime.
Various methods may be used to obfuscate malware calls to API functions. For example, hashes of function names are commonly stored in malware in lieu of literal strings. Malware can use these hashes (or other identifiers) to manually reproduce the linking and loading process using functions such as GetProcAddress() and LoadLibrary(). These hashes/identifiers can also be further obfuscated using encryption or other string manipulation tricks (requiring various forms of Deobfuscate/Decode Files or Information during execution).[3][4][1]
| ID | Name | Description |
|---|---|---|
| S1053 | AvosLocker |
AvosLocker has used obfuscated API calls that are retrieved by their checksums.[5] |
| S0534 | Bazar | |
| S1063 | Brute Ratel C4 |
Brute Ratel C4 can call and dynamically resolve hashed APIs.[8] |
| S1237 | CANONSTAGER |
CANONSTAGER has utilized custom API hashing to obfuscate the Windows APIs being used.[9] |
| S1149 | CHIMNEYSWEEP |
CHIMNEYSWEEP can use |
| S1236 | CLAIMLOADER |
CLAIMLOADER has utilized XOR-encrypted API names and native APIs of |
| S1160 | Latrodectus |
Latrodectus can resolve Windows APIs dynamically by hash.[13] |
| G0032 | Lazarus Group |
Lazarus Group has used a custom hashing method to resolve APIs used in shellcode.[14] |
| G0129 | Mustang Panda |
Mustang Panda has leveraged obfuscated Windows API function calls that were concealed as unique names, or hashes of the Windows API.[15] |
| S0013 | PlugX |
PlugX has leveraged obfuscated Windows API function calls that were concealed as unique names, or hashes of the Windows API.[15] |
| S0147 | Pteranodon |
Pteranodon can use a dynamic Windows hashing algorithm to map API components.[16] |
| S1148 | Raccoon Stealer |
Raccoon Stealer dynamically links key WinApi functions during execution.[17][18] |
| S1099 | Samurai |
Samurai can encrypt API name strings with an XOR-based algorithm.[19] |
| S1232 | SplatDropper |
SplatDropper has leveraged hashed Windows API calls using a seed value of "131313".[20] |
| S1239 | TONESHELL |
TONESHELL has utilized a modified DJB2 algorithm to resolve APIs.[21] |
This type of attack technique cannot be easily mitigated with preventive controls since it is based on the abuse of system features.
| ID | Name | Analytic ID | Analytic Description |
|---|---|---|---|
| DET0091 | Detection Strategy for Dynamic API Resolution via Hash-Based Function Lookups | AN0250 |
Behavioral chain involving suspicious use of GetProcAddress and LoadLibrary following memory allocation and manual mapping, often paired with low entropy strings, abnormal API use without static import tables, or delayed module load behaviors. |