To replace a function, you need CFF Explorer.
It will be faster to use Dependency Walker to figure out what all is missing instead of going one by one.
Open the application in CFF Explorer and click Import Directory.
Find the dll the error is from.
Find the function you want to replace.
Double click its name and replace it with the new function.
(Optional) Go to Rebuilder, untick Update PE Header and tick Update Checksum, then rebuild. (Required for drivers)
Save.
The list:
Multiple dlls:
- anything2 (IsWow64Process2 for example) can have the 2 removed, or replaced with A or (Ex)W and likely work
(Anywhere from 10+ to XP and maybe earlier compatibility)
- Most anythingEx functions have alternatives, can be as simple as removing the Ex or as complex as K32GetModuleFileNameExA > GetModuleFileNameA.
(Anywhere from 10+ to XP and maybe earlier compatibility)
- It may be possible to replace a function with one even completely unrelated and still have the program work, like ResolveDelayLoadedAPI > ResolveLocaleName. This may not work in all cases.
(Anywhere from 10+ to XP and maybe earlier compatibility)
- CredReadA/CredWriteA > CredFree
(XP+ -> 2000 (extended kernel) compatibility)
- CM_Register_Notification > CMP_RegisterNotification
(8+ -> XP compatibility)
- CopyFile2 > CopyFileW
(8+ -> XP compatibility)
- GetCurrentThreadStackLimits > GetCurrentThread
(8+ -> XP compatibility)
- GetDynamicTimeZoneInformation > GetTimeZoneInformation
(Vista+ -> 2000 compatibility)
- GetSystemTimePreciseAsFileTime > GetSystemTimeAsFileTime
(8+ -> 2000 compatibility)
- K32EnumProcessModules > GetProcAddress
(7+ -> XP compatibility)
- K32GetModuleFileNameExA > GetModuleFileNameA
(7+ -> XP compatibility)
- LoadPackagedLibrary > LoadLibraryExW
(8+ -> XP compatibility)
- RaiseFailFastException > RaiseException
(7+ -> XP compatibility)
- TryAcquireSRWLock*> AcquireSRWLock*
(7+ -> Vista compatibility)
- NdisSetCoalescableTimerObject > NdisSetTimerObject
(7+ -> Vista (RTM) compatibility)
- NtReleaseKeyedEvent > NtReleaseSemaphore
(XP+ -> 2000 (extended kernel) compatibility)
- NtWaitForKeyedEvent > NtWaitHighEventPair
(XP+ -> 2000 (extended kernel) compatibility)
- anything_s (memcpy_s for example) can have the _s removed and likely work
(7+(?) -> XP compatibility(?))
- KeQueryLogicalProcessorRelationship > KeQueryMaximumProcessorCount
(7+ -> Vista compatibility)
- strnlen > strlen
(7+ -> XP compatibility(?))
- PowerDeterminePlatformRoleEx > PowerDeterminePlatformRole
(8+ -> Vista compatibility)