This project demonstrates how to resolve Windows API functions dynamically using custom hashing instead of storing API names in plain text. It helps avoid detection by AV and static analysis tools.
- Custom hash function to obfuscate API names
- Manual parsing of PE headers to locate exports
- Resolves
LoadLibraryA
without IAT - Generic function resolver via hashed names
- Include
HashResolver.h
in your project. - Call
CalculateHash("FunctionName")
to get the hash. - Use
ResolveFunctionByHash("module.dll", HASH)
to get the function pointer.
auto VirtualAllocPtr = (pVirtualAlloc)ResolveFunctionByHash("kernel32.dll", 0x123456);
📝 Replace
0x123456
with the hash of the desired API usingCalculateHash
.
🔗 Read the detailed breakdown here: API Hashing Blog
This technique is often used in malware for stealth and dynamic resolution—understand it to defend against it.