09-17-2023, 08:30 PM
Instrumentation callbacks are a post-op syscall hook that allows a user to execute a specified function before the kernel returns execution to the userland process.
Various security products place hooks in user-mode APIs which allow them to redirect execution flow to their engines and detect for suspicious behaviour. The functions in ntdll.dll that make the syscalls consist of just a few assembly instructions, so re-implementing them in your own implant can bypass the triggering of those security product hooks.
More info and credit about this tecnique here:
https://outflank.nl/blog/2019/06/19/red-...ss-av-edr/
Here a simple POC:
Please if you like this share rep me, I have a lot of material on this and if you like it I want to post it all!
Various security products place hooks in user-mode APIs which allow them to redirect execution flow to their engines and detect for suspicious behaviour. The functions in ntdll.dll that make the syscalls consist of just a few assembly instructions, so re-implementing them in your own implant can bypass the triggering of those security product hooks.
More info and credit about this tecnique here:
https://outflank.nl/blog/2019/06/19/red-...ss-av-edr/
Here a simple POC:
Please if you like this share rep me, I have a lot of material on this and if you like it I want to post it all!