int 2eh 方式调用Native api

小技巧。但是用的人好像不多。

例子:  Windows 2000 下

  1. NtQuerySystemInformationNo = 0x97;
  2.  
  3. _declspec(naked)
  4. NTSTATUS __stdcall PrivateNtQuerySystemInformation
  5. (IN     SYSTEM_INFORMATION_CLASS,
  6. IN OUT PVOID,
  7. IN     ULONG,
  8. OUT    PULONG OPTIONAL)
  9. {
  10.  
  11. _asm {
  12. mov eax, NtQuerySystemInformationNo
  13. lea edx, [esp+4]
  14. int 2Eh
  15. ret 10h
  16. }
  17.  
  18. }

评论数量(0) | Add Comments
本文网址:http://www.6code.net/security/int-2eh-native-ap.html

随机文章:

There are No comments.

leave a reply

You must be logged in to post a comment.