Advertisement
Guest User

Untitled

a guest
Feb 16th, 2013
136
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.32 KB | None | 0 0
  1. __attribute__((naked)) void CheckProtocol_AsmHelper_LDyn() {
  2. asm (
  3. push esi;
  4. mov eax, pnet_from;
  5. push eax;
  6. call SV_CheckProtocol_rev;
  7. add esp, 8;
  8. test eax, eax;
  9. jz __dpfail2;
  10. mov eax, DSEngineData.CheckProto_GoodRet_addr;
  11. jmp eax;
  12.  
  13. __dpfail2:
  14. mov eax, DSEngineData.CheckProto_BadRet_addr;
  15. jmp eax;
  16. )
  17. }
  18.  
  19. __attribute__((naked)) void CheckCDKey_Helper_LDyn() {
  20. asm (
  21. mov eax, LastUserInfo;
  22. push eax;
  23. mov eax, DSEngineData.ConnectClient_CDKey_soff;
  24. add eax, ebp;
  25. push eax;
  26. mov eax, DSEngineData.ConnectClient_AuthProto_soff;
  27. add eax, ebp;
  28. mov eax, [eax];
  29. push eax;
  30. mov eax, pnet_from;
  31. push eax;
  32. call SV_CheckCDKey_rev;
  33. add esp, 0x10;
  34. test eax, eax;
  35. jz __cdfail2;
  36. mov eax, DSEngineData.CheckCDKey_GoodRet_addr;
  37. jmp eax;
  38.  
  39. __cdfail2:
  40. mov eax, DSEngineData.CheckProto_BadRet_addr;
  41. jmp eax;
  42. )
  43. }
  44.  
  45.  
  46.  
  47. __attribute__((naked)) void SendSrvInfo_WriteLongProto_LDyn() {
  48. asm (
  49. mov eax, [esp+4]; //sbuf
  50. push eax;
  51. mov eax, [ebp+0xC]; //client
  52. push eax;
  53. call SendSrvInfo_WriteProto;
  54. retn;
  55. )
  56. }
  57.  
  58. __attribute__((naked)) void DenyHelper_Hooked_WDyn() {
  59. asm (
  60. mov eax, [esp+8];
  61. cmp eax, 0xE;
  62. ja _ret;
  63. cmp eax, 7;
  64. jz _ret;
  65.  
  66. mov eax, DSEngineData.GSClientDenyHelper_addr;
  67. jmp eax;
  68.  
  69. _ret:
  70. retn 0xC;
  71.  
  72. )
  73. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement