joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4fa350
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x58c423
mov eax, dword fs:[0]
push eax
sub esp, 0x54
mov eax, dword [0x5ed80c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
mov edx, dword [ebp + 0x14]
mov esi, ecx
mov ecx, dword [ebp + 0x10]
xor ebx, ebx
mov dword [ebp - 0x60], esi
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x4c], ecx
mov dword [ebp - 0x58], edx
mov dword [ebp - 0x5c], ebx
cmp dword [ebp + 0x18], ebx
je 0x4fa3c4
mov dword [esi + 0xc], 0x59c868
mov dword [esi + 0x4c], vtable.boost::exception.0
mov dword [esi + 0x50], ebx
mov dword [esi + 0x54], ebx
mov dword [esi + 0x58], ebx
mov dword [esi + 0x5c], 0xffffffff
mov dword [ebp - 4], ebx
mov dword [ebp - 0x5c], 1
mov edi, dword [sym.imp.KERNEL32.dll_GetACP]
call edi
push eax
mov eax, dword [ebp - 0x50]
push eax
lea ecx, [ebp - 0x2c]
push ecx
call fcn.004021f0
push eax
lea edx, [ebp - 0x48]
push edx
mov dword [ebp - 4], 1
call fcn.004fa070
add esp, 0x14
cmp dword [eax + 0x14], 0x10
mov byte [ebp - 4], 2
jb 0x4fa3fa
mov eax, dword [eax]
lea ecx, [ebp - 0x54]
push ecx
mov ecx, esi
mov dword [ebp - 0x54], eax
call fcn.0055b5ba
cmp dword [ebp - 0x34], 0x10
jb 0x4fa41a
mov edx, dword [ebp - 0x48]
push edx
call fcn.0055ae44
add esp, 4
mov dword [ebp - 0x34], 0xf
mov dword [ebp - 0x38], ebx
mov byte [ebp - 0x48], bl
cmp dword [ebp - 0x18], 0x10
mov byte [ebp - 4], 5
jb 0x4fa43d
mov eax, dword [ebp - 0x2c]
push eax
call fcn.0055ae44
add esp, 4
mov ecx, dword [esi + 0xc]
mov eax, dword [ebp + 0xc]
mov dword [esi], vtable.mailru::exception.0
mov edx, dword [ecx + 4]
mov dword [edx + esi + 0xc], vtable.mailru::exception.1.0
mov dword [ebp - 0x18], 0xf
mov dword [ebp - 0x1c], ebx
mov byte [ebp - 0x2c], bl
mov dword [esi + 0x10], eax
call edi
mov ecx, dword [ebp - 0x4c]
push ecx
lea edx, [esi + 0x14]
push edx
lea ecx, [ebp - 0x50]
mov dword [ebp - 0x50], eax
call fcn.00428960
mov byte [ebp - 4], 6
call edi
mov dword [ebp - 0x4c], eax
mov eax, dword [ebp - 0x58]
push eax
lea ecx, [esi + 0x30]
push ecx
lea ecx, [ebp - 0x4c]
call fcn.00428960
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0055bc32
mov esp, ebp
pop ebp
ret 0x14
Function at 0x4fa4c0
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x58c47f
mov eax, dword fs:[0]
push eax
sub esp, 0x34
mov eax, dword [0x5ed80c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
mov edi, dword [ebp + 0x10]
mov esi, ecx
mov ecx, dword [ebp + 0x14]
xor ebx, ebx
mov dword [ebp - 0x40], esi
mov dword [ebp - 0x38], ecx
mov dword [ebp - 0x3c], ebx
cmp dword [ebp + 0x18], ebx
je 0x4fa52e
mov dword [esi + 0xc], 0x59c868
mov dword [esi + 0x4c], vtable.boost::exception.0
mov dword [esi + 0x50], ebx
mov dword [esi + 0x54], ebx
mov dword [esi + 0x58], ebx
mov dword [esi + 0x5c], 0xffffffff
mov dword [ebp - 4], ebx
mov dword [ebp - 0x3c], 1
push eax
lea edx, [ebp - 0x2c]
push edx
call fcn.004fa070
add esp, 8
cmp dword [eax + 0x14], 0x10
mov dword [ebp - 4], 1
jb 0x4fa54a
mov eax, dword [eax]
lea ecx, [ebp - 0x34]
push ecx
mov ecx, esi
mov dword [ebp - 0x34], eax
call fcn.0055b5ba
cmp dword [ebp - 0x18], 0x10
mov byte [ebp - 4], 3
jb 0x4fa56e
mov edx, dword [ebp - 0x2c]
push edx
call fcn.0055ae44
add esp, 4
mov eax, dword [esi + 0xc]
mov edx, dword [ebp + 0xc]
mov dword [esi], vtable.mailru::exception.0
mov ecx, dword [eax + 4]
mov dword [ebp - 0x1c], ebx
mov byte [ebp - 0x2c], bl
mov ebx, dword [sym.imp.KERNEL32.dll_GetACP]
mov dword [ecx + esi + 0xc], vtable.mailru::exception.1.0
mov dword [ebp - 0x18], 0xf
mov dword [esi + 0x10], edx
call ebx
mov dword [ebp - 0x30], eax
push edi
lea eax, [esi + 0x14]
push eax
lea ecx, [ebp - 0x30]
call fcn.00428960
mov byte [ebp - 4], 4
call ebx
mov ecx, dword [ebp - 0x38]
push ecx
lea edx, [esi + 0x30]
push edx
lea ecx, [ebp - 0x30]
mov dword [ebp - 0x30], eax
call fcn.00428960
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0055bc32
mov esp, ebp
pop ebp
ret 0x14

Function at 0x4fb560
Capabilities:
Get common file path
Get startup folder

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x808
mov eax, dword [0x5ed80c]
xor eax, ebp
mov dword [ebp - 4], eax
mov ecx, dword [ecx]
mov edx, dword [ebp + 0xc]
push esi
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x804]
push eax
push 0
push ecx
or edx, 0x8000
push edx
push 0
mov dword [ebp - 0x808], 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
xor eax, eax
mov dword [esi + 0x14], 7
mov dword [esi + 0x10], 0
mov word [esi], ax
lea eax, [ebp - 0x804]
lea edx, [eax + 2]
jmp 0x4fb5c0
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4fb5c0
sub eax, edx
sar eax, 1
push eax
lea ecx, [ebp - 0x804]
push ecx
mov ecx, esi
call fcn.00401c40
mov ecx, dword [ebp - 4]
mov eax, esi
xor ecx, ebp
pop esi
call fcn.0055bc32
mov esp, ebp
pop ebp
ret 8
Function at 0x4fe450
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push ebx
mov ebx, dword [ebp + 8]
push edi
mov edi, dword [ebp + 0xc]
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
jne 0x4fe46b
pop edi
pop ebx
pop ebp
ret
push esi
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
je 0x4fe4a2
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ecx, dword [ebp + 0x10]
add eax, esi
and ecx, 0xf
jbe 0x4fe49e
jmp 0x4fe490
cmp esi, eax
jae 0x4fe4a2
dec ecx
movzx edx, word [esi]
lea esi, [esi + edx*2 + 2]
jne 0x4fe490
cmp esi, eax
jb 0x4fe4a9
pop esi
pop edi
xor eax, eax
pop ebx
pop ebp
ret
movzx eax, word [esi]
neg eax
sbb eax, eax
and eax, esi
pop esi
pop edi
pop ebx
pop ebp
ret
Function at 0x4fe830
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x58cbb5
mov eax, dword fs:[0]
push eax
sub esp, 0x90
mov eax, dword [0x5ed80c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
mov edx, dword [ebp + 0x10]
mov esi, ecx
mov ecx, dword [ebp + 0xc]
push ecx
push eax
mov eax, dword [esi]
push eax
mov dword [ebp - 0x84], edx
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov edi, eax
xor ebx, ebx
cmp edi, ebx
jne 0x4fe8ad
push 1
push str.mailru::resource::read
push str.Resource.cpp
push 0x18
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea ecx, [ebp - 0x74]
call fcn.004053a0
push 0x5ccbe8
lea ecx, [ebp - 0x74]
push ecx
call fcn.0055b802
mov edx, dword [esi]
push edi
push edx
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov dword [ebp - 0x80], eax
cmp eax, ebx
jne 0x4fe8e9
push 1
push str.mailru::resource::read
push str.Resource.cpp
push 0x1d
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea ecx, [ebp - 0x74]
call fcn.004053a0
push 0x5ccbe8
lea eax, [ebp - 0x74]
push eax
call fcn.0055b802
lea ecx, [ebp - 0x80]
lea edx, [ebp - 0x7c]
mov dword [ebp - 0x7c], ecx
mov dword [ebp - 0x9c], edx
mov eax, dword [esi]
push edi
push eax
mov dword [ebp - 4], ebx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov esi, eax
cmp esi, ebx
jne 0x4fe936
push 1
push str.mailru::resource::read
push str.Resource.cpp
push 0x24
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea ecx, [ebp - 0x74]
call fcn.004053a0
push 0x5ccbe8
lea ecx, [ebp - 0x74]
push ecx
call fcn.0055b802
mov edx, dword [ebp - 0x80]
push edx
call dword [sym.imp.KERNEL32.dll_LockResource]
mov dword [ebp - 0x78], eax
cmp eax, ebx
jne 0x4fe972
push 1
push str.mailru::resource::read
push str.Resource.cpp
push 0x29
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea ecx, [ebp - 0x74]
call fcn.004053a0
push 0x5ccbe8
lea eax, [ebp - 0x74]
push eax
call fcn.0055b802
lea ecx, [ebp - 0x78]
mov dword [ebp - 0x98], ecx
push esi
lea ecx, [ebp - 0x94]
mov dword [ebp - 0x94], ebx
mov dword [ebp - 0x90], ebx
mov dword [ebp - 0x8c], ebx
call fcn.004262e0
mov edx, dword [ebp - 0x78]
mov eax, dword [ebp - 0x94]
push esi
push edx
push eax
mov byte [ebp - 4], 1
call fcn.0055ae50
add esp, 0xc
lea ecx, [ebp - 0x94]
push ecx
mov ecx, dword [ebp - 0x84]
call fcn.004ff5e0
lea ecx, [ebp - 0x94]
call fcn.0041aed0
mov edx, dword [ebp - 0x7c]
mov eax, dword [edx]
push eax
call dword [sym.imp.KERNEL32.dll_FreeResource]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0055bc32
mov esp, ebp
pop ebp
ret 0xc
Function at 0x5006d0
Capabilities:
Hash data with crc32

Disassembly:
xor edx, edx
add ecx, 0x24
mov eax, edx
shr eax, 1
test dl, 1
je 0x5006e3
xor eax, 0xedb88320
test al, 1
je 0x5006f0
shr eax, 1
xor eax, 0xedb88320
jmp 0x5006f2
shr eax, 1
test al, 1
je 0x5006ff
shr eax, 1
xor eax, 0xedb88320
jmp 0x500701
shr eax, 1
test al, 1
je 0x50070e
shr eax, 1
xor eax, 0xedb88320
jmp 0x500710
shr eax, 1
test al, 1
je 0x50071d
shr eax, 1
xor eax, 0xedb88320
jmp 0x50071f
shr eax, 1
test al, 1
je 0x50072c
shr eax, 1
xor eax, 0xedb88320
jmp 0x50072e
shr eax, 1
test al, 1
je 0x50073b
shr eax, 1
xor eax, 0xedb88320
jmp 0x50073d
shr eax, 1
test al, 1
je 0x50074a
shr eax, 1
xor eax, 0xedb88320
jmp 0x50074c
shr eax, 1
mov dword [ecx], eax
inc edx
add ecx, 4
cmp edx, 0x100
jb 0x5006d5
ret

Function at 0x502ee0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
mov edx, dword [ebp + 0x10]
or eax, 0xffffffff
push esi
mov esi, dword [ebp + 0xc]
test edx, edx
je 0x502f08
push ebx
push edi
movzx edi, byte [esi]
movzx ebx, al
xor edi, ebx
shr eax, 8
xor eax, dword [ecx + edi*4 + 0x24]
inc esi
dec edx
jne 0x502ef3
pop edi
pop ebx
not eax
xor ecx, ecx
cmp eax, dword [ebp + 8]
pop esi
sete cl
mov eax, ecx
pop ebp
ret 0xc
Function at 0x5090a0
Capabilities:
Terminate thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push esi
push 0xffffffffffffffff
push 0
mov esi, ecx
mov eax, dword [esi + 8]
mov ecx, dword [esi + 4]
lea edx, [ebp - 8]
push edx
push 2
mov dword [ebp - 8], eax
mov dword [ebp - 4], ecx
call dword [sym.imp.KERNEL32.dll_WaitForMultipleObjects]
mov eax, dword [esi + 8]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0
push 0x5f1544
call dword [sym.imp.KERNEL32.dll_InterlockedExchangeAdd]
push 0
test eax, eax
je 0x5090f1
mov ecx, dword [esi + 4]
push ecx
call dword [sym.imp.KERNEL32.dll_TerminateThread]
pop esi
mov esp, ebp
pop ebp
ret
mov edx, dword [esi + 4]
push edx
push method.std::basic_streambuf_char__struct_std::char_traits_char__.virtual_56
call dword [sym.imp.KERNEL32.dll_QueueUserAPC]
mov eax, dword [esi + 4]
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
pop esi
mov esp, ebp
pop ebp
ret

Function at 0x509240
Capabilities:
Connect socket

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
cmp esi, 0xffffffff
jne 0x509264
mov esi, 0x2719
call fcn.00535e40
mov ecx, dword [ebp + 0x14]
mov dword [ecx], esi
mov dword [ecx + 4], eax
or eax, 0xffffffff
pop esi
pop ebp
ret
push ebx
push edi
push 0
call dword [sym.imp.WS2_32.dll_WSASetLastError]
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp + 0xc]
push eax
push ecx
push esi
call dword [sym.imp.WS2_32.dll_connect]
mov ebx, eax
call fcn.00535e40
mov edi, eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, dword [ebp + 0x14]
mov dword [esi], eax
mov dword [esi + 4], edi
test ebx, ebx
jne 0x5092a4
xor edi, edi
call fcn.00535e40
mov dword [esi], edi
mov dword [esi + 4], eax
pop edi
mov eax, ebx
pop ebx
pop esi
pop ebp
ret

Function at 0x509320
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
push esi
push edi
push 0
call dword [sym.imp.WS2_32.dll_WSASetLastError]
mov eax, dword [ebp + 0x14]
push 0
push 0
lea ecx, [ebp - 8]
push ecx
mov ecx, dword [ebp + 0xc]
lea edx, [ebp - 4]
push edx
mov edx, dword [ebp + 8]
mov dword [ebp - 8], eax
mov eax, dword [ebp + 0x10]
push eax
push ecx
push edx
mov dword [ebp - 4], 0
call dword [sym.imp.WS2_32.dll_WSARecv]
mov ebx, eax
call fcn.00535e40
mov edi, eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, dword [ebp + 0x18]
mov dword [esi], eax
mov dword [esi + 4], edi
cmp eax, 0x40
jne 0x50937f
mov edi, 0x2746
jmp 0x50938b
cmp eax, 0x4d2
jne 0x509395
mov edi, 0x274d
call fcn.00535e40
mov dword [esi + 4], eax
mov dword [esi], edi
test ebx, ebx
je 0x5093a3
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov esp, ebp
pop ebp
ret
xor edi, edi
call fcn.00535e40
mov dword [esi], edi
pop edi
mov dword [esi + 4], eax
mov eax, dword [ebp - 4]
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x509560
Capabilities:
Get socket status

Disassembly:
push ebp
mov ebp, esp
push esi
push edi
push 0
call dword [sym.imp.WS2_32.dll_WSASetLastError]
mov edx, dword [ebp + 0xc]
mov esi, dword [ebp + 0x14]
mov edi, dword [ebp + 0x10]
test edx, edx
jne 0x5095c8
test edi, edi
jne 0x5095c8
test esi, esi
jne 0x5095c8
mov ecx, dword [ebp + 0x18]
test ecx, ecx
je 0x5095e9
mov eax, 0x10624dd3
imul dword [ecx + 4]
mov ecx, dword [ecx]
imul ecx, ecx, 0x3e8
sar edx, 6
mov eax, edx
shr eax, 0x1f
add eax, edx
add eax, ecx
jne 0x5095ac
mov eax, 1
push eax
call dword [sym.imp.KERNEL32.dll_Sleep]
xor esi, esi
call fcn.00535e40
mov ecx, dword [ebp + 0x1c]
pop edi
mov dword [ecx], esi
mov dword [ecx + 4], eax
xor eax, eax
pop esi
pop ebp
ret
mov ecx, dword [ebp + 0x18]
test ecx, ecx
je 0x5095e9
cmp dword [ecx], 0
jne 0x5095e9
mov eax, dword [ecx + 4]
test eax, eax
jle 0x5095e9
cmp eax, 0x3e8
jge 0x5095e9
mov dword [ecx + 4], 0x3e8
push ebx
push ecx
push esi
push edi
push edx
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.WS2_32.dll_select]
mov ebx, eax
call fcn.00535e40
mov edi, eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, dword [ebp + 0x1c]
mov dword [esi], eax
mov dword [esi + 4], edi
test ebx, ebx
js 0x50961f
xor edi, edi
call fcn.00535e40
mov dword [esi], edi
mov dword [esi + 4], eax
mov eax, ebx
pop ebx
pop edi
pop esi
pop ebp
ret
Function at 0x509630
Capabilities:
Get socket status

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x118
mov eax, dword [0x5ed80c]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov bl, byte [ebp + 0xc]
push esi
mov esi, dword [ebp + 0x10]
push edi
mov edi, dword [ebp + 8]
cmp edi, 0xffffffff
jne 0x509677
mov edi, 0x2719
call fcn.00535e40
mov dword [esi], edi
pop edi
mov dword [esi + 4], eax
pop esi
or eax, 0xffffffff
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0055bc32
mov esp, ebp
pop ebp
ret
xor eax, eax
push eax
mov dword [ebp - 0x104], edi
mov dword [ebp - 0x108], 1
mov dword [ebp - 0x110], eax
mov dword [ebp - 0x10c], eax
call dword [sym.imp.WS2_32.dll_WSASetLastError]
and bl, 1
movzx eax, bl
neg eax
sbb eax, eax
lea ecx, [ebp - 0x110]
and eax, ecx
push eax
push 0
push 0
lea edx, [ebp - 0x108]
push edx
push edi
call dword [sym.imp.WS2_32.dll_select]
mov dword [ebp - 0x114], eax
call fcn.00535e40
mov edi, eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [esi + 4], edi
mov edi, dword [ebp - 0x114]
mov dword [esi], eax
test edi, edi
jne 0x509758
test bl, bl
je 0x509720
mov ebx, 0x2733
call fcn.00535e40
mov dword [ebp - 0x10c], eax
lea eax, [ebp - 0x110]
mov dword [ebp - 0x110], ebx
mov ecx, dword [eax]
mov edx, dword [eax + 4]
mov eax, edi
pop edi
mov dword [esi], ecx
mov dword [esi + 4], edx
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0055bc32
mov esp, ebp
pop ebp
ret
mov dword [ebp - 0x118], 0
call fcn.00535e40
mov dword [ebp - 0x114], eax
lea eax, [ebp - 0x118]
mov ecx, dword [eax]
mov edx, dword [eax + 4]
mov eax, edi
pop edi
mov dword [esi], ecx
mov dword [esi + 4], edx
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0055bc32
mov esp, ebp
pop ebp
ret
jle 0x509766
xor ebx, ebx
call fcn.00535e40
mov dword [esi], ebx
mov dword [esi + 4], eax
mov ecx, dword [ebp - 4]
mov eax, edi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0055bc32
mov esp, ebp
pop ebp
ret
Function at 0x509780
Capabilities:
Get socket status

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x118
mov eax, dword [0x5ed80c]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov bl, byte [ebp + 0xc]
push esi
mov esi, dword [ebp + 0x10]
push edi
mov edi, dword [ebp + 8]
cmp edi, 0xffffffff
jne 0x5097c7
mov edi, 0x2719
call fcn.00535e40
mov dword [esi], edi
pop edi
mov dword [esi + 4], eax
pop esi
or eax, 0xffffffff
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0055bc32
mov esp, ebp
pop ebp
ret
xor eax, eax
push eax
mov dword [ebp - 0x104], edi
mov dword [ebp - 0x108], 1
mov dword [ebp - 0x110], eax
mov dword [ebp - 0x10c], eax
call dword [sym.imp.WS2_32.dll_WSASetLastError]
and bl, 1
movzx eax, bl
neg eax
sbb eax, eax
lea ecx, [ebp - 0x110]
and eax, ecx
push eax
push 0
lea edx, [ebp - 0x108]
push edx
push 0
push edi
call dword [sym.imp.WS2_32.dll_select]
mov dword [ebp - 0x114], eax
call fcn.00535e40
mov edi, eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [esi + 4], edi
mov edi, dword [ebp - 0x114]
mov dword [esi], eax
test edi, edi
jne 0x5098a8
test bl, bl
je 0x509870
mov ebx, 0x2733
call fcn.00535e40
mov dword [ebp - 0x10c], eax
lea eax, [ebp - 0x110]
mov dword [ebp - 0x110], ebx
mov ecx, dword [eax]
mov edx, dword [eax + 4]
mov eax, edi
pop edi
mov dword [esi], ecx
mov dword [esi + 4], edx
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0055bc32
mov esp, ebp
pop ebp
ret
mov dword [ebp - 0x118], 0
call fcn.00535e40
mov dword [ebp - 0x114], eax
lea eax, [ebp - 0x118]
mov ecx, dword [eax]
mov edx, dword [eax + 4]
mov eax, edi
pop edi
mov dword [esi], ecx
mov dword [esi + 4], edx
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0055bc32
mov esp, ebp
pop ebp
ret
jle 0x5098b6
xor ebx, ebx
call fcn.00535e40
mov dword [esi], ebx
mov dword [esi + 4], eax
mov ecx, dword [ebp - 4]
mov eax, edi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0055bc32
mov esp, ebp
pop ebp
ret

Function at 0x5098d0
Capabilities:
Get socket status

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20c
mov eax, dword [0x5ed80c]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 0xc]
push edi
mov edi, dword [ebp + 8]
cmp edi, 0xffffffff
jne 0x509912
mov edi, 0x2719
call fcn.00535e40
mov dword [esi], edi
mov dword [esi + 4], eax
pop edi
or eax, 0xffffffff
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0055bc32
mov esp, ebp
pop ebp
ret
push ebx
mov eax, 1
push 0
mov dword [ebp - 0x208], edi
mov dword [ebp - 0x20c], eax
mov dword [ebp - 0x104], edi
mov dword [ebp - 0x108], eax
call dword [sym.imp.WS2_32.dll_WSASetLastError]
push 0
lea eax, [ebp - 0x108]
push eax
lea ecx, [ebp - 0x20c]
push ecx
push 0
push edi
call dword [sym.imp.WS2_32.dll_select]
mov ebx, eax
call fcn.00535e40
mov edi, eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [esi], eax
mov dword [esi + 4], edi
test ebx, ebx
js 0x509975
xor edi, edi
call fcn.00535e40
mov dword [esi], edi
mov dword [esi + 4], eax
mov ecx, dword [ebp - 4]
mov eax, ebx
pop ebx
pop edi
xor ecx, ebp
pop esi
call fcn.0055bc32
mov esp, ebp
pop ebp
ret
Function at 0x509ad0
Capabilities:
Resolve dns

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push esi
push edi
mov edi, dword [ebp + 0xc]
test edi, edi
je 0x509ae4
cmp byte [edi], 0
jne 0x509ae6
xor edi, edi
mov esi, dword [ebp + 0x10]
test esi, esi
je 0x509af2
cmp byte [esi], 0
jne 0x509af4
xor esi, esi
push 0
call dword [sym.imp.WS2_32.dll_WSASetLastError]
mov eax, dword [ebp + 0x18]
mov ecx, dword [ebp + 0x14]
push eax
push ecx
push esi
push edi
call dword [sym.imp.WS2_32.dll_getaddrinfo]
push eax
lea edx, [ebp - 8]
push edx
call fcn.00509990
mov edx, dword [eax]
mov ecx, dword [ebp + 0x1c]
mov dword [ecx], edx
mov edx, dword [eax + 4]
mov dword [ecx + 4], edx
mov edx, dword [eax]
mov ecx, dword [ebp + 8]
mov eax, dword [eax + 4]
add esp, 8
pop edi
mov dword [ecx + 4], eax
mov dword [ecx], edx
mov eax, ecx
pop esi
mov esp, ebp
pop ebp
ret

Function at 0x509b40
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x41c
mov eax, dword [0x5ed80c]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
lea eax, [ebp - 0x404]
push edi
xor ebx, ebx
mov edi, ecx
mov dword [ebp - 0x418], eax
mov dword [ebp - 0x41c], 0x400
mov dword [ebp - 0x414], ebx
call fcn.00535e40
lea ecx, [ebp - 0x414]
push ecx
push ebx
push 1
lea edx, [ebp - 0x41c]
mov dword [ebp - 0x410], eax
mov eax, dword [edi]
push edx
push eax
call fcn.00509320
add esp, 0x14
cmp eax, ebx
setg cl
mov byte [ebp - 0x405], cl
cmp eax, 0x400
jne 0x509c32
push esi
mov esi, dword [edi]
push ebx
call dword [sym.imp.WS2_32.dll_WSASetLastError]
push ebx
push ebx
lea ecx, [ebp - 0x410]
push ecx
lea edx, [ebp - 0x40c]
push edx
push 1
lea eax, [ebp - 0x41c]
push eax
push esi
mov dword [ebp - 0x40c], ebx
mov dword [ebp - 0x410], ebx
call dword [sym.imp.WS2_32.dll_WSARecv]
mov esi, eax
call fcn.00535e40
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x40
je 0x509c01
cmp eax, 0x4d2
jne 0x509c06
call fcn.00535e40
cmp esi, ebx
jne 0x509c1b
call fcn.00535e40
cmp dword [ebp - 0x40c], 0x400
je 0x509bb3
mov al, byte [ebp - 0x405]
pop esi
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0055bc32
mov esp, ebp
pop ebp
ret
mov al, cl
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop ebx
call fcn.0055bc32
mov esp, ebp
pop ebp
ret
Function at 0x50ab20
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
push edi
mov edi, ecx
mov eax, dword [edi + 4]
add eax, 0x18
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedIncrement]
cmp byte [ebp + 0x18], 0
je 0x50ab4e
mov ecx, dword [ebp + 0x1c]
push 0
push 0
push ecx
mov ecx, dword [edi + 4]
call fcn.0050a5d0
pop edi
pop ebp
ret 0x18
mov edx, dword [ebp + 8]
mov eax, dword [edx]
cmp eax, 0xffffffff
jne 0x50ab70
mov eax, dword [ebp + 0x1c]
mov ecx, dword [edi + 4]
push 0
push 0x2719
push eax
call fcn.0050a5d0
pop edi
pop ebp
ret 0x18
mov ecx, dword [ebp + 0x14]
push ebx
push esi
mov esi, dword [ebp + 0x1c]
push 0
push esi
push ecx
mov ecx, dword [ebp + 0x10]
lea edx, [ebp + 0x18]
push edx
mov edx, dword [ebp + 0xc]
push ecx
push edx
push eax
mov dword [ebp + 0x18], 0
call dword [sym.imp.WS2_32.dll_WSASend]
mov ebx, eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x4d2
jne 0x50abaa
mov eax, 0x274d
test ebx, ebx
je 0x50abca
cmp eax, 0x3e5
je 0x50abca
mov ecx, dword [ebp + 0x18]
push ecx
mov ecx, dword [edi + 4]
push eax
push esi
call fcn.0050a5d0
pop esi
pop ebx
pop edi
pop ebp
ret 0x18
mov ecx, dword [edi + 4]
push esi
call fcn.0050a560
pop esi
pop ebx
pop edi
pop ebp
ret 0x18

Function at 0x50abe0
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
push edi
mov edi, ecx
mov eax, dword [edi + 4]
add eax, 0x18
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedIncrement]
cmp byte [ebp + 0x18], 0
je 0x50ac0e
mov ecx, dword [ebp + 0x1c]
push 0
push 0
push ecx
mov ecx, dword [edi + 4]
call fcn.0050a5d0
pop edi
pop ebp
ret 0x18
mov edx, dword [ebp + 8]
mov eax, dword [edx]
cmp eax, 0xffffffff
jne 0x50ac30
mov eax, dword [ebp + 0x1c]
mov ecx, dword [edi + 4]
push 0
push 0x2719
push eax
call fcn.0050a5d0
pop edi
pop ebp
ret 0x18
mov ecx, dword [ebp + 0x14]
push ebx
push esi
mov esi, dword [ebp + 0x1c]
push 0
push esi
mov dword [ebp + 8], ecx
lea edx, [ebp + 8]
push edx
mov edx, dword [ebp + 0x10]
lea ecx, [ebp + 0x18]
push ecx
mov ecx, dword [ebp + 0xc]
push edx
push ecx
push eax
mov dword [ebp + 0x18], 0
call dword [sym.imp.WS2_32.dll_WSARecv]
mov ebx, eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x40
jne 0x50ac70
mov eax, 0x2746
jmp 0x50ac7c
cmp eax, 0x4d2
jne 0x50ac7c
mov eax, 0x274d
test ebx, ebx
je 0x50ac9c
cmp eax, 0x3e5
je 0x50ac9c
mov edx, dword [ebp + 0x18]
mov ecx, dword [edi + 4]
push edx
push eax
push esi
call fcn.0050a5d0
pop esi
pop ebx
pop edi
pop ebp
ret 0x18
mov ecx, dword [edi + 4]
push esi
call fcn.0050a560
pop esi
pop ebx
pop edi
pop ebp
ret 0x18