Advertisement
Guest User

Untitled

a guest
Oct 4th, 2015
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.35 KB | None | 0 0
  1. ;irackit 2015
  2. .486
  3. .model flat,stdcall
  4. option casemap:none
  5.  
  6. include F:\masm32\include\windows.inc
  7. include F:\masm32\include\kernel32.inc
  8. include F:\masm32\include\user32.inc
  9. include F:\masm32\include\msvcrt.inc
  10. ;include F:\masm32\include\TlHelp32.inc
  11.  
  12. includelib F:\masm32\lib\kernel32.lib
  13. includelib F:\masm32\lib\user32.lib
  14. includelib F:\masm32\lib\msvcrt.lib
  15. ;includelib F:\masm32\lib\TlHelp32.lib
  16.  
  17.  
  18. _DATA SEGMENT PUBLIC 'DATA'
  19. formatA db '%s',0
  20. dwFlags dd ?
  21. handle dd ?
  22. th32ProcessID dd ?
  23. p32 PROCESSENTRY32 <>
  24. debuging db 'debug message',0
  25. _DATA ENDS
  26.  
  27. _TEXT SEGMENT PUBLIC READONLY 'CODE'
  28. main:
  29.  
  30. mov [dwFlags],02h
  31. push offset th32ProcessID
  32. push dwFlags
  33. call CreateToolhelp32Snapshot
  34. mov [handle],eax
  35. add esp,8
  36. cmp eax,0
  37. je endmission
  38. mov [p32.dwSize],SIZEOF PROCESSENTRY32
  39.  
  40. push offset p32
  41. mov eax,handle
  42. push eax
  43. call Process32FirstW
  44. cmp eax,0
  45. je endmission
  46.  
  47. mov esi,offset debuging
  48. call printstdout
  49.  
  50. irackit_display_process:
  51. mov esi, offset debuging
  52. call printstdout
  53. push offset p32
  54. push handle
  55. call Process32NextW
  56. cmp eax,0
  57. jne irackit_display_process
  58.  
  59. endmission:
  60. xor eax,eax
  61. xor ebx,ebx
  62. call ExitProcess
  63.  
  64. printstdout PROC
  65. push offset formatA
  66. push esi
  67. call _imp__printf
  68. add esp,8
  69. ret
  70. printstdout ENDP
  71.  
  72. _TEXT ENDS
  73. end main
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement