Can someone help me?
why does
invoke OpenProcessToken, ps.th32ProcessID,TOKEN_ADJUST_PRIVILEGES or TOKEN_QUERY, addr htoken
returns ERROR_INVALID_HANDLE (00000006)
but i know for shure that that handle is valid.
why does
invoke OpenProcessToken, ps.th32ProcessID,TOKEN_ADJUST_PRIVILEGES or TOKEN_QUERY, addr htoken
returns ERROR_INVALID_HANDLE (00000006)
but i know for shure that that handle is valid.
You should be using the process handle not the process ID...
invoke GetCurrentProcess
mov ,eax
invoke OpenProcessToken, ,TOKEN_ADJUST_PRIVILEGES | TOKEN_QUERY, offset hToken
test eax,eax
jnz >
xor eax,eax
ret
: