Advertisement
Guest User

OLDPE

a guest
Jun 5th, 2015
372
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. .text:004F3B00     ; int __fastcall processevent(void *Dst)
  2. .text:004F3B00     processevent    proc near               ; CODE XREF: sub_503370+8EEp
  3. .text:004F3B00
  4. .text:004F3B00     var_70          = byte ptr -70h
  5. .text:004F3B00     var_68          = dword ptr -68h
  6. .text:004F3B00     var_64          = dword ptr -64h
  7. .text:004F3B00     var_60          = dword ptr -60h
  8. .text:004F3B00     var_5C          = dword ptr -5Ch
  9. .text:004F3B00     var_58          = dword ptr -58h
  10. .text:004F3B00     var_54          = dword ptr -54h
  11. .text:004F3B00     var_50          = dword ptr -50h
  12. .text:004F3B00     var_4C          = dword ptr -4Ch
  13. .text:004F3B00     var_48          = dword ptr -48h
  14. .text:004F3B00     var_44          = dword ptr -44h
  15. .text:004F3B00     Src             = dword ptr -40h
  16. .text:004F3B00     var_3C          = dword ptr -3Ch
  17. .text:004F3B00     var_38          = dword ptr -38h
  18. .text:004F3B00     var_24          = dword ptr -24h
  19. .text:004F3B00     var_20          = dword ptr -20h
  20. .text:004F3B00     var_1C          = dword ptr -1Ch
  21. .text:004F3B00     var_18          = dword ptr -18h
  22. .text:004F3B00     var_14          = dword ptr -14h
  23. .text:004F3B00     var_10          = dword ptr -10h
  24. .text:004F3B00     var_C           = dword ptr -0Ch
  25. .text:004F3B00     var_4           = dword ptr -4
  26. .text:004F3B00
  27. .text:004F3B00 000                 push    ebp
  28. .text:004F3B01 004                 mov     ebp, esp
  29. .text:004F3B03 004                 push    0FFFFFFFFh
  30. .text:004F3B05 008                 push    offset sub_176DC88
  31. .text:004F3B0A 00C                 mov     eax, large fs:0
  32. .text:004F3B10 00C                 push    eax
  33. .text:004F3B11 010                 sub     esp, 68h
  34. .text:004F3B14 078                 mov     eax, ___security_cookie
  35. .text:004F3B19 078                 xor     eax, ebp
  36. .text:004F3B1B 078                 mov     [ebp+var_10], eax
  37. .text:004F3B1E 078                 push    ebx
  38. .text:004F3B1F 07C                 push    esi
  39. .text:004F3B20 080                 push    edi
  40. .text:004F3B21 084                 push    eax
  41. .text:004F3B22 088                 lea     eax, [ebp+var_C]
  42. .text:004F3B25 088                 mov     large fs:0, eax
  43. .text:004F3B2B 088                 xor     edi, edi
  44. .text:004F3B2D 088                 mov     ebx, ecx
  45. .text:004F3B2F 088                 mov     [ebp+var_64], ebx
  46. .text:004F3B32 088                 mov     [ebp+Src], edi
  47. .text:004F3B35 088                 mov     [ebp+var_3C], edi
  48. .text:004F3B38 088                 mov     [ebp+var_38], edi
  49. .text:004F3B3B 088                 mov     [ebp+var_24], edi
  50. .text:004F3B3E 088                 mov     [ebp+var_1C], edi
  51. .text:004F3B41 088                 mov     [ebp+var_20], edi
  52. .text:004F3B44 088                 mov     [ebp+var_18], edi
  53. .text:004F3B47 088                 mov     [ebp+var_14], edi
  54. .text:004F3B4A 088                 mov     eax, [ebx+4]
  55. .text:004F3B4D 088                 sub     eax, [ebx+2Ch]
  56. .text:004F3B50 088                 lea     ecx, [ebp+Src]
  57. .text:004F3B53 088                 push    eax
  58. .text:004F3B54 08C                 mov     [ebp+var_4], 2
  59. .text:004F3B5B 08C                 call    sub_AD8720
  60. .text:004F3B60 088                 push    edi
  61. .text:004F3B61 08C                 lea     eax, [ebx+0Ch]
  62. .text:004F3B64 08C                 push    eax
  63. .text:004F3B65 090                 lea     ecx, [ebp+var_5C]
  64. .text:004F3B68 090                 mov     [ebp+var_60], ebx
  65. .text:004F3B6B 090                 call    sub_C604B0
  66. .text:004F3B70 088                 mov     ecx, [ebp+var_54]
  67. .text:004F3B73 088                 mov     esi, [ebp+var_4C]
  68. .text:004F3B76 088                 cmp     esi, [ecx+14h]
  69. .text:004F3B79 088                 jge     loc_4F3CB1
  70. .text:004F3B7F 088                 mov     [ebp+var_68], edi
  71. .text:004F3B82
  72. .text:004F3B82     loc_4F3B82:                             ; CODE XREF: processevent+1A8j
  73. .text:004F3B82 088                 lea     edx, [ebp+var_70]
  74. .text:004F3B85 088                 push    edx
  75. .text:004F3B86 08C                 lea     ecx, [ebp+Src]
  76. .text:004F3B89 08C                 call    sub_6510F0
  77. .text:004F3B8E 088                 mov     ebx, [eax+4]
  78. .text:004F3B91 088                 cmp     ebx, edi
  79. .text:004F3B93 088                 jz      short loc_4F3C0A
  80. .text:004F3B95 088                 mov     eax, [ebp+var_60]
  81. .text:004F3B98 088                 mov     edi, [eax]
  82. .text:004F3B9A 088                 lea     ecx, ds:0[esi*8]
  83. .text:004F3BA1 088                 sub     ecx, esi
  84. .text:004F3BA3 088                 mov     edx, [edi+ecx*4]
  85. .text:004F3BA6 088                 lea     edi, [edi+ecx*4]
  86. .text:004F3BA9 088                 mov     [ebx], edx
  87. .text:004F3BAB 088                 mov     eax, [edi+4]
  88. .text:004F3BAE 088                 mov     [ebx+4], eax
  89. .text:004F3BB1 088                 mov     eax, [edi+0Ch]
  90. .text:004F3BB4 088                 lea     esi, [ebx+8]
  91. .text:004F3BB7 088                 mov     [ebp+var_44], esi
  92. .text:004F3BBA 088                 mov     dword ptr [esi], 0
  93. .text:004F3BC0 088                 mov     byte ptr [ebp+var_4], 3
  94. .text:004F3BC4 088                 mov     [esi+4], eax
  95. .text:004F3BC7 088                 mov     [esi+8], eax
  96. .text:004F3BCA 088                 test    eax, eax
  97. .text:004F3BCC 088                 jz      short loc_4F3BE0
  98. .text:004F3BCE 088                 push    8
  99. .text:004F3BD0 08C                 lea     ecx, [eax+eax]
  100. .text:004F3BD3 08C                 push    ecx
  101. .text:004F3BD4 090                 push    0
  102. .text:004F3BD6 094                 call    sub_50C0C0
  103. .text:004F3BDB 094                 add     esp, 0Ch
  104. .text:004F3BDE 088                 mov     [esi], eax
  105. .text:004F3BE0
  106. .text:004F3BE0     loc_4F3BE0:                             ; CODE XREF: processevent+CCj
  107. .text:004F3BE0 088                 mov     eax, [esi+4]
  108. .text:004F3BE3 088                 mov     byte ptr [ebp+var_4], 2
  109. .text:004F3BE7 088                 test    eax, eax
  110. .text:004F3BE9 088                 jz      short loc_4F3BFE
  111. .text:004F3BEB 088                 mov     ecx, [edi+8]
  112. .text:004F3BEE 088                 mov     esi, [esi]
  113. .text:004F3BF0 088                 lea     edx, [eax+eax]
  114. .text:004F3BF3 088                 push    edx             ; Size
  115. .text:004F3BF4 08C                 push    ecx             ; Src
  116. .text:004F3BF5 090                 push    esi             ; Dst
  117. .text:004F3BF6 094                 call    memcpy
  118. .text:004F3BFB 094                 add     esp, 0Ch
  119. .text:004F3BFE
  120. .text:004F3BFE     loc_4F3BFE:                             ; CODE XREF: processevent+E9j
  121. .text:004F3BFE 088                 mov     eax, [edi+14h]
  122. .text:004F3C01 088                 mov     [ebx+14h], eax
  123. .text:004F3C04 088                 mov     ecx, [edi+18h]
  124. .text:004F3C07 088                 mov     [ebx+18h], ecx
  125. .text:004F3C0A
  126. .text:004F3C0A     loc_4F3C0A:                             ; CODE XREF: processevent+93j
  127. .text:004F3C0A 088                 mov     edx, [ebp+var_58]
  128. .text:004F3C0D 088                 mov     edi, [ebp+var_50]
  129. .text:004F3C10 088                 mov     eax, [ebp+var_54]
  130. .text:004F3C13 088                 mov     ecx, [eax+10h]
  131. .text:004F3C16 088                 not     edx
  132. .text:004F3C18 088                 and     edi, edx
  133. .text:004F3C1A 088                 xor     edx, edx
  134. .text:004F3C1C 088                 test    ecx, ecx
  135. .text:004F3C1E 088                 setz    dl
  136. .text:004F3C21 088                 mov     ebx, [ebp+var_5C]
  137. .text:004F3C24 088                 lea     esi, [ebp+var_68]
  138. .text:004F3C27 088                 mov     [ebp+var_50], edi
  139. .text:004F3C2A 088                 neg     edx
  140. .text:004F3C2C 088                 and     eax, edx
  141. .text:004F3C2E 088                 or      eax, ecx
  142. .text:004F3C30 088                 mov     ecx, 0
  143. .text:004F3C35 088                 setz    cl
  144. .text:004F3C38 088                 neg     ecx
  145. .text:004F3C3A 088                 and     esi, ecx
  146. .text:004F3C3C 088                 or      esi, eax
  147. .text:004F3C3E 088                 mov     ecx, [esi+ebx*4]
  148. .text:004F3C41 088                 and     ecx, edi
  149. .text:004F3C43 088                 jnz     short loc_4F3C71
  150. .text:004F3C45 088                 mov     eax, [ebp+var_54]
  151. .text:004F3C48 088                 mov     edi, [eax+14h]
  152. .text:004F3C4B 088                 lea     eax, [edi-1]
  153. .text:004F3C4E 088                 cdq
  154. .text:004F3C4F 088                 and     edx, 1Fh
  155. .text:004F3C52 088                 add     eax, edx
  156. .text:004F3C54 088                 sar     eax, 5
  157. .text:004F3C57
  158. .text:004F3C57     loc_4F3C57:                             ; CODE XREF: processevent+16Cj
  159. .text:004F3C57 088                 add     [ebp+var_48], 20h
  160. .text:004F3C5B 088                 inc     ebx
  161. .text:004F3C5C 088                 cmp     ebx, eax
  162. .text:004F3C5E 088                 jg      short loc_4F3C84
  163. .text:004F3C60 088                 mov     ecx, [esi+ebx*4]
  164. .text:004F3C63 088                 mov     [ebp+var_50], 0FFFFFFFFh
  165. .text:004F3C6A 088                 test    ecx, ecx
  166. .text:004F3C6C 088                 jz      short loc_4F3C57
  167. .text:004F3C6E 088                 mov     [ebp+var_5C], ebx
  168. .text:004F3C71
  169. .text:004F3C71     loc_4F3C71:                             ; CODE XREF: processevent+143j
  170. .text:004F3C71 088                 lea     eax, [ecx-1]
  171. .text:004F3C74 088                 and     eax, ecx
  172. .text:004F3C76 088                 xor     eax, ecx
  173. .text:004F3C78 088                 mov     [ebp+var_58], eax
  174. .text:004F3C7B 088                 jnz     short loc_4F3C8B
  175. .text:004F3C7D 088                 mov     eax, 20h
  176. .text:004F3C82 088                 jmp     short loc_4F3C98
  177. .text:004F3C84     ; ---------------------------------------------------------------------------
  178. .text:004F3C84
  179. .text:004F3C84     loc_4F3C84:                             ; CODE XREF: processevent+15Ej
  180. .text:004F3C84 088                 mov     [ebp+var_5C], ebx
  181. .text:004F3C87 088                 mov     esi, edi
  182. .text:004F3C89 088                 jmp     short loc_4F3CA0
  183. .text:004F3C8B     ; ---------------------------------------------------------------------------
  184. .text:004F3C8B
  185. .text:004F3C8B     loc_4F3C8B:                             ; CODE XREF: processevent+17Bj
  186. .text:004F3C8B 088                 bsr     ecx, eax
  187. .text:004F3C8E 088                 mov     eax, 1Fh
  188. .text:004F3C93 088                 mov     [ebp+var_44], ecx
  189. .text:004F3C96 088                 sub     eax, ecx
  190. .text:004F3C98
  191. .text:004F3C98     loc_4F3C98:                             ; CODE XREF: processevent+182j
  192. .text:004F3C98 088                 mov     esi, [ebp+var_48]
  193. .text:004F3C9B 088                 sub     esi, eax
  194. .text:004F3C9D 088                 add     esi, 1Fh
  195. .text:004F3CA0
  196. .text:004F3CA0     loc_4F3CA0:                             ; CODE XREF: processevent+189j
  197. .text:004F3CA0 088                 mov     edx, [ebp+var_54]
  198. .text:004F3CA3 088                 xor     edi, edi
  199. .text:004F3CA5 088                 cmp     esi, [edx+14h]
  200. .text:004F3CA8 088                 jl      loc_4F3B82
  201. .text:004F3CAE 088                 mov     ebx, [ebp+var_64]
  202. .text:004F3CB1
  203. .text:004F3CB1     loc_4F3CB1:                             ; CODE XREF: processevent+79j
  204. .text:004F3CB1 088                 mov     eax, 30h
  205. .text:004F3CB6 088                 call    __alloca_probe
  206. .text:004F3CBB 0B8                 mov     esi, esp
  207. .text:004F3CBD 0B8                 push    30h             ; Size
  208. .text:004F3CBF 0BC                 push    ebx             ; Src
  209. .text:004F3CC0 0C0                 push    esi             ; Dst
  210. .text:004F3CC1 0C4                 call    memcpy
  211. .text:004F3CC6 0C4                 push    30h             ; Size
  212. .text:004F3CC8 0C8                 lea     eax, [ebp+Src]
  213. .text:004F3CCB 0C8                 push    eax             ; Src
  214. .text:004F3CCC 0CC                 push    ebx             ; Dst
  215. .text:004F3CCD 0D0                 call    memcpy
  216. .text:004F3CD2 0D0                 push    30h             ; Size
  217. .text:004F3CD4 0D4                 lea     ecx, [ebp+Src]
  218. .text:004F3CD7 0D4                 push    esi             ; Src
  219. .text:004F3CD8 0D8                 push    ecx             ; Dst
  220. .text:004F3CD9 0DC                 call    memcpy
  221. .text:004F3CDE 0DC                 add     esp, 24h
  222. .text:004F3CE1 0B8                 push    edi
  223. .text:004F3CE2 0BC                 lea     ecx, [ebp+Src]
  224. .text:004F3CE5 0BC                 mov     [ebp+var_4], 5
  225. .text:004F3CEC 0BC                 call    sub_AD8720
  226. .text:004F3CF1 0B8                 mov     eax, [ebp+var_24]
  227. .text:004F3CF4 0B8                 mov     byte ptr [ebp+var_4], 4
  228. .text:004F3CF8 0B8                 cmp     eax, edi
  229. .text:004F3CFA 0B8                 jz      short loc_4F3D08
  230. .text:004F3CFC 0B8                 push    eax
  231. .text:004F3CFD 0BC                 call    sub_50C0F0
  232. .text:004F3D02 0BC                 add     esp, 4
  233. .text:004F3D05 0B8                 mov     [ebp+var_24], edi
  234. .text:004F3D08
  235. .text:004F3D08     loc_4F3D08:                             ; CODE XREF: processevent+1FAj
  236. .text:004F3D08 0B8                 mov     eax, [ebp+Src]
  237. .text:004F3D0B 0B8                 mov     [ebp+var_38], edi
  238. .text:004F3D0E 0B8                 mov     [ebp+var_3C], edi
  239. .text:004F3D11 0B8                 mov     [ebp+var_4], 0FFFFFFFFh
  240. .text:004F3D18 0B8                 cmp     eax, edi
  241. .text:004F3D1A 0B8                 jz      short loc_4F3D25
  242. .text:004F3D1C 0B8                 push    eax
  243. .text:004F3D1D 0BC                 call    sub_50C0F0
  244. .text:004F3D22 0BC                 add     esp, 4
  245. .text:004F3D25
  246. .text:004F3D25     loc_4F3D25:                             ; CODE XREF: processevent+21Aj
  247. .text:004F3D25 0B8                 lea     esp, [ebp-84h]
  248. .text:004F3D2B 088                 mov     ecx, [ebp+var_C]
  249. .text:004F3D2E 088                 mov     large fs:0, ecx
  250. .text:004F3D35 088                 pop     ecx
  251. .text:004F3D36 084                 pop     edi
  252. .text:004F3D37 080                 pop     esi
  253. .text:004F3D38 07C                 pop     ebx
  254. .text:004F3D39 078                 mov     ecx, [ebp+var_10]
  255. .text:004F3D3C 078                 xor     ecx, ebp
  256. .text:004F3D3E 078                 call    @__security_check_cookie@4 ; __security_check_cookie(x)
  257. .text:004F3D43 078                 mov     esp, ebp
  258. .text:004F3D45 -2C                 pop     ebp
  259. .text:004F3D46 -30                 retn
  260. .text:004F3D46     processevent    endp
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement