-
Notifications
You must be signed in to change notification settings - Fork 262
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MSR_LSTAR syscall hook issue with parameters #6
Comments
Alright so I managed to fix the issue. The problem was that the KiSystemCall64 emulator was missing some crucial code from KiSystemServiceCopyStart which will copy all the arguments from the stack. Furthermore the way this is done is obvious when looking at the code in ntoskrnl.exe or when debugging the current broken one step by step. Another thing to note is that the ArgTble[ssdt_index] should be the number of parameters passed to the stack and not the whole number of parameters of the function. Thats that! |
Maybe you can make a pull request then? |
I will see what I can do I am 2 lazy at the moment and am just messing with this. |
Kolo, what about stop copy and pasting for your iwebz cheat? Edit: that's what you get ;) |
Hi, Any further updates?? |
Lets work it out and resolve the issue... |
where should the code of KiSystemServiceCopyStart be added in the KiSystemCall64_emulate function?? |
@DarthTon, your jmp actually points to To fix this you need instead jump to It will parse arguments currectly. Also too pass arguements counter into function you can use that: |
So I mentioned this already in private but when you try hooking for example ZwQueryVirtualMemory which has more than 4 parameters (after RCX, RDX, R8, R9) aka some on the stack like the 5th and 6th for example, those parameters will be invalid in the hook and therefore the original call of the syscall will usually fail and screw the whole operating system up.
Testing done on windows 8.1, compiled with Visual Studio 2013 using MSR_LSTAR hooking method.
The text was updated successfully, but these errors were encountered: