joyce8/EMBER2024-capa huggingface dataset:
Function at 0x46effc
Capabilities:
Create udp socket

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
push edi
push 0x48
push 1
call dword [0x4b1380]
mov esi, dword [ebp + 8]
mov edi, eax
pop ecx
pop ecx
push 8
mov dword [esi + 0x3bc], edi
pop ebx
test edi, edi
je 0x46f0bc
push dword [ebp + 0x14]
mov eax, dword [ebp + 0x10]
xor ecx, ecx
mov dword [esi + 0x3b4], ecx
mov dword [esi + 0x3b8], ecx
mov dword [esi + 0x3b0], ecx
push eax
push dword [ebp + 0xc]
mov dword [esi + 0x3ac], eax
or dword [edi + 4], 0xffffffff
mov dword [edi], ecx
lea ecx, [edi + 0x10]
push ecx
call fcn.0046f0dc
add esp, 0x10
test eax, eax
je 0x46f0bc
mov eax, dword [esi + 0x3a8]
test eax, eax
je 0x46f077
push eax
call dword [0x4b1374]
and dword [esi + 0x3a8], 0
pop ecx
push dword [ebp + 0xc]
call dword [0x4b137c]
mov dword [esi + 0x3a8], eax
pop ecx
test eax, eax
je 0x46f0bc
push 0
push 2
push 2
call dword [sym.imp.WS2_32.dll_socket]
mov dword [edi + 4], eax
cmp eax, 0xffffffff
je 0x46f0bc
lea eax, [edi + 0x10]
push eax
push 0x46ef6f
call fcn.00479181
mov dword [edi], eax
pop ecx
pop ecx
test eax, eax
jne 0x46f0d7
call fcn.004934ba
mov ebx, dword [eax]
lea eax, [esi + 0x3a8]
push eax
call fcn.0046eea9
pop ecx
push ebx
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
pop edi
pop esi
pop ebx
pop ebp
ret
xor eax, eax
inc eax
jmp 0x46f0d2

Function at 0x476829
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 0xc]
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
push 0
push dword [ebp + 0x14]
push dword [ebp + 0x10]
push dword [edi + eax*4 + 0x130]
call dword [sym.imp.WS2_32.dll_send]
mov ebx, dword [ebp + 0x18]
mov esi, eax
and dword [ebx], 0
cmp esi, 0xffffffff
jne 0x476899
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp + 8], eax
cmp eax, 0x2733
jne 0x476871
xor esi, esi
mov dword [ebx], 0x51
jmp 0x476899
push eax
push edi
call fcn.0046bb65
push eax
push 0x407540
push dword [edi]
call fcn.00476566
mov eax, dword [edi]
add esp, 0x14
mov ecx, dword [ebp + 8]
mov dword [eax + 0x856c], ecx
mov dword [ebx], 0x37
pop edi
mov eax, esi
pop esi
pop ebx
pop ebp
ret

Function at 0x476a22
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
mov eax, dword [esi + 0x164]
test eax, eax
je 0x476a4a
push dword [esi + 0xf4]
push dword [ebp + 0x14]
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push esi
call eax
add esp, 0x14
jmp 0x476a82
mov eax, dword [ebp + 0xc]
cmp eax, 2
ja 0x476a80
push dword [esi + 0xf0]
imul eax, eax, 3
push 1
push 2
add eax, 0x407528
push eax
call fcn.00491c59
push dword [esi + 0xf0]
push 1
push dword [ebp + 0x14]
push dword [ebp + 0x10]
call fcn.00491c59
add esp, 0x20
xor eax, eax
pop esi
pop ebp
ret
Function at 0x476bdc
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
push esi
push edi
or edi, 0xffffffff
mov ecx, dword [eax + 0x530]
cmp ecx, edi
je 0x476c30
mov eax, dword [eax + 0x524]
mov eax, dword [eax]
mov eax, dword [eax + ecx*4]
test eax, eax
je 0x476c30
mov ecx, dword [ebp + 0xc]
test ecx, ecx
je 0x476c09
mov dword [ecx], eax
cmp dword [eax + 0x148], 0
mov esi, dword [eax + 0x130]
jne 0x476c30
push 2
push 1
lea ecx, [ebp + 0xb]
push ecx
push esi
call dword [sym.imp.WS2_32.dll_recv]
test eax, eax
cmove esi, edi
mov eax, esi
jmp 0x476c32
mov eax, edi
pop edi
pop esi
pop ebp
ret

Function at 0x476d83
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x108
mov eax, dword [0x4b1810]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
cmp dword [edi + 0x19c], 0
mov ebx, dword [edi]
jne 0x476ea3
lea eax, [ebp - 0x108]
mov esi, 0x80
push eax
lea eax, [ebp - 0x84]
mov dword [ebp - 0x108], esi
push eax
push dword [ebp + 0xc]
call dword [sym.imp.WS2_32.dll_getpeername]
test eax, eax
je 0x476df5
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, eax
push esi
push edi
call fcn.0046bb65
push eax
push esi
push 0x4076d0
push ebx
call fcn.00476566
add esp, 0x18
jmp 0x476eaa
lea eax, [ebp - 0x108]
mov dword [ebp - 0x108], esi
push eax
lea eax, [ebp - 0x104]
push eax
push dword [ebp + 0xc]
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
je 0x476e2e
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, eax
push esi
push edi
call fcn.0046bb65
push eax
push esi
push 0x407648
jmp 0x476de7
lea eax, [edi + 0xcc]
push eax
lea eax, [edi + 0x9e]
push eax
lea eax, [ebp - 0x84]
push eax
call fcn.00477205
add esp, 0xc
test eax, eax
jne 0x476e67
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push edi
call fcn.0046bb65
push eax
push esi
push 0x4076f8
jmp 0x476de7
lea eax, [edi + 0x100]
push eax
lea eax, [edi + 0xd0]
push eax
lea eax, [ebp - 0x104]
push eax
call fcn.00477205
add esp, 0xc
test eax, eax
jne 0x476ea3
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push edi
call fcn.0046bb65
push eax
push esi
push 0x407724
jmp 0x476de7
push edi
call fcn.00476c36
pop ecx
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00491511
mov esp, ebp
pop ebp
ret
Function at 0x4775e3
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
push esi
push edi
mov edi, dword [ebp + 8]
push 4
mov esi, dword [edi]
mov eax, dword [esi + 0x314]
mov dword [ebp + 8], eax
lea eax, [ebp + 8]
push eax
push 1
push 6
push dword [ebp + 0xc]
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x47762b
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push edi
call fcn.0046bb65
push eax
push 0x407764
push esi
call fcn.004765fc
add esp, 0x14
jmp 0x477638
push 0x407784
push esi
call fcn.004765fc
pop ecx
pop ecx
pop edi
pop esi
pop ebp
ret

Function at 0x477f07
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov cl, byte [ebp + 8]
movsx eax, cl
add eax, 0xffffff9f
cmp eax, 0x19
ja case.default.0x477f18
jmp dword [eax*4 + 0x477f8b]
mov al, 0x41
pop ebp
ret
mov al, 0x42
pop ebp
ret
mov al, 0x43
pop ebp
ret
mov al, 0x44
pop ebp
ret
mov al, 0x45
pop ebp
ret
mov al, 0x46
pop ebp
ret
mov al, 0x47
pop ebp
ret
mov al, 0x48
pop ebp
ret
mov al, 0x49
pop ebp
ret
mov al, 0x4a
pop ebp
ret
mov al, 0x4b
pop ebp
ret
mov al, 0x4c
pop ebp
ret
mov al, 0x4d
pop ebp
ret
mov al, 0x4e
pop ebp
ret
mov al, 0x4f
pop ebp
ret
mov al, 0x50
pop ebp
ret
mov al, 0x51
pop ebp
ret
mov al, 0x52
pop ebp
ret
mov al, 0x53
pop ebp
ret
mov al, 0x54
pop ebp
ret
mov al, 0x55
pop ebp
ret
mov al, 0x56
pop ebp
ret
mov al, 0x57
pop ebp
ret
mov al, 0x58
pop ebp
ret
mov al, 0x59
pop ebp
ret
mov al, 0x5a
pop ebp
ret
mov al, cl
pop ebp
ret
Function at 0x478224
Capabilities:
Resolve dns

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [ebp + 0x14]
push edi
xor edi, edi
and dword [ebp - 0xc], edi
and dword [eax], edi
lea eax, [ebp - 8]
push eax
push dword [ebp + 0x10]
mov dword [ebp - 4], edi
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.WS2_32.dll_getaddrinfo]
mov dword [ebp - 0x14], eax
test eax, eax
jne 0x47838e
push esi
mov esi, dword [ebp - 8]
mov dword [ebp - 0x10], esi
test esi, esi
je 0x47837a
push ebx
cmp dword [esi + 4], 2
jne 0x478319
cmp dword [esi + 0x18], 0
je 0x478319
cmp dword [esi + 0x10], 0
jbe 0x478319
cmp dword [esi + 0x10], 0x10
jb 0x478319
push 0x20
call dword [0x4b1370]
mov ebx, eax
pop ecx
test ebx, ebx
je 0x47836e
mov ecx, dword [esi]
mov dword [ebx], ecx
mov ecx, dword [esi + 4]
mov dword [ebx + 4], ecx
mov ecx, dword [esi + 8]
mov dword [ebx + 8], ecx
mov eax, dword [esi + 0xc]
and dword [ebx + 0x18], 0
and dword [ebx + 0x14], 0
and dword [ebx + 0x1c], 0
push 0x10
mov dword [ebx + 0xc], eax
mov dword [ebx + 0x10], 0x10
call dword [0x4b1370]
mov dword [ebx + 0x18], eax
pop ecx
test eax, eax
je 0x478362
mov esi, dword [esi + 0x18]
mov edi, eax
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov esi, dword [ebp - 0x10]
cmp dword [esi + 0x14], 0
je 0x478301
push dword [esi + 0x14]
call dword [0x4b137c]
mov dword [ebx + 0x14], eax
pop ecx
test eax, eax
je 0x47834b
mov edi, dword [ebp - 4]
test edi, edi
mov eax, dword [ebp - 0xc]
cmove edi, ebx
mov dword [ebp - 4], edi
test eax, eax
je 0x478316
mov dword [eax + 0x1c], ebx
mov dword [ebp - 0xc], ebx
mov esi, dword [esi + 0x1c]
mov dword [ebp - 0x10], esi
test esi, esi
jne 0x478266
mov esi, dword [ebp - 0x14]
cmp dword [ebp - 8], 0
pop ebx
je 0x47833a
push dword [ebp - 8]
call dword [sym.imp.WS2_32.dll_freeaddrinfo]
test esi, esi
je 0x478373
push dword [ebp - 4]
call fcn.004781e3
pop ecx
xor edi, edi
jmp 0x478386
push 8
pop esi
push dword [ebx + 0x18]
call dword [0x4b1374]
push ebx
call dword [0x4b1374]
pop ecx
pop ecx
jmp 0x47832a
push 8
pop esi
push ebx
call dword [0x4b1374]
jmp 0x47835f
push 8
pop esi
jmp 0x47832a
mov edi, dword [ebp - 4]
test edi, edi
jne 0x478386
mov esi, 0x2af9
push esi
call dword [sym.imp.WS2_32.dll_WSASetLastError]
mov eax, dword [ebp + 0x14]
mov dword [eax], edi
mov eax, esi
pop esi
pop edi
mov esp, ebp
pop ebp
ret

Function at 0x479181
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
xor eax, eax
push eax
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
push eax
push eax
call fcn.004964a3
add esp, 0x18
test eax, eax
je 0x4791a1
cmp eax, 0xffffffff
jne 0x4791a3
xor eax, eax
pop ebp
ret
Function at 0x47f51a
Capabilities:
Check for time delay via gettickcount
Get socket status

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x330
mov eax, dword [0x4b1810]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
mov ebx, dword [ebp + 0x10]
push esi
xor esi, esi
mov dword [ebp - 0x320], esi
mov dword [ebp - 0x324], esi
mov dword [ebp - 0x314], esi
push edi
mov edi, dword [ebp + 0xc]
cmp eax, 0xffffffff
jne 0x47f563
cmp edi, 0xffffffff
jne 0x47f563
push ebx
call fcn.0047f760
pop ecx
jmp 0x47f74f
test ebx, ebx
jle 0x47f581
mov dword [ebp - 0x314], ebx
call fcn.004781cd
mov dword [ebp - 0x320], eax
mov eax, dword [ebp + 8]
mov dword [ebp - 0x324], edx
mov ecx, esi
mov dword [ebp - 0x310], esi
or edx, 0xffffffff
mov dword [ebp - 0x108], ecx
mov dword [ebp - 0x31c], 1
cmp eax, 0xffffffff
je 0x47f5c1
mov ecx, dword [ebp - 0x31c]
mov edx, eax
mov dword [ebp - 0x30c], eax
mov dword [ebp - 0x310], ecx
mov dword [ebp - 0x104], eax
mov dword [ebp - 0x108], ecx
mov dword [ebp - 0x20c], esi
cmp edi, 0xffffffff
je 0x47f60b
mov dword [ebp - 0x208], edi
mov eax, esi
mov dword [ebp - 0x20c], 1
test ecx, ecx
je 0x47f5f0
cmp dword [ebp + eax*4 - 0x104], edi
je 0x47f5f0
inc eax
cmp eax, ecx
jb 0x47f5e2
cmp eax, ecx
jne 0x47f606
cmp ecx, 0x40
jae 0x47f606
mov dword [ebp + eax*4 - 0x104], edi
inc dword [ebp - 0x108]
cmp edi, edx
cmova edx, edi
xor ecx, ecx
lea eax, [ebp - 0x32c]
test ebx, ebx
cmovs eax, ecx
lea ecx, [edx + 1]
mov dword [ebp - 0x330], ecx
mov ecx, dword [ebp - 0x314]
mov dword [ebp - 0x318], eax
test ebx, ebx
jle 0x47f655
mov eax, ecx
mov ecx, 0x3e8
cdq
idiv ecx
mov dword [ebp - 0x32c], eax
imul eax, edx, 0x3e8
mov dword [ebp - 0x328], eax
mov eax, dword [ebp - 0x318]
jmp 0x47f663
jne 0x47f663
mov dword [ebp - 0x32c], esi
mov dword [ebp - 0x328], esi
push eax
lea eax, [ebp - 0x108]
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x310]
push eax
push dword [ebp - 0x330]
call dword [sym.imp.WS2_32.dll_select]
cmp eax, 0xffffffff
jne 0x47f6df
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
test eax, eax
je 0x47f69b
cmp eax, 0x2714
jne 0x47f6e3
mov ecx, dword [ebp - 0x314]
mov eax, dword [ebp - 0x318]
test ebx, ebx
jle 0x47f655
push dword [ebp - 0x324]
push dword [ebp - 0x320]
call fcn.004781cd
push edx
push eax
call fcn.00478177
mov ecx, ebx
add esp, 0x10
sub ecx, eax
mov dword [ebp - 0x314], ecx
test ecx, ecx
jle 0x47f6e3
mov eax, dword [ebp - 0x318]
jmp 0x47f62d
test eax, eax
jns 0x47f6e8
or eax, 0xffffffff
jmp 0x47f74f
jne 0x47f6ee
xor eax, eax
jmp 0x47f74f
mov ebx, dword [ebp + 8]
cmp ebx, 0xffffffff
je 0x47f720
lea eax, [ebp - 0x310]
push eax
push ebx
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
lea eax, [ebp - 0x108]
push eax
cmovne esi, dword [ebp - 0x31c]
push ebx
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x47f720
or esi, 4
cmp edi, 0xffffffff
je 0x47f74d
lea eax, [ebp - 0x20c]
push eax
push edi
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x47f739
or esi, 2
lea eax, [ebp - 0x108]
push eax
push edi
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x47f74d
or esi, 4
mov eax, esi
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00491511
mov esp, ebp
pop ebp
ret
Function at 0x48097a
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [0x4b1810]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
or edi, 0xffffffff
mov dword [ebp - 0x1c], 0x10
mov eax, dword [ebx + 0x134]
mov esi, dword [ebx]
mov dword [ebp - 0x18], eax
jmp 0x4809cc
mov eax, 0x3e8
cmp ecx, eax
cmovl eax, ecx
push eax
push 0xffffffffffffffff
push dword [ebp - 0x18]
call fcn.0047f51a
add esp, 0xc
cmp eax, 0xffffffff
je 0x480a73
test eax, eax
jne 0x480a00
push 1
push 0
push esi
call fcn.00476ce2
mov ecx, eax
add esp, 0xc
test ecx, ecx
jns 0x4809a7
push 0x408f14
push esi
call fcn.00476566
pop ecx
pop ecx
push 0x1c
pop eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00491511
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0x14]
push eax
push dword [ebp - 0x18]
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x480a2f
lea eax, [ebp - 0x1c]
mov dword [ebp - 0x1c], 0x10
push eax
lea eax, [ebp - 0x14]
push eax
push dword [ebp - 0x18]
call dword [sym.imp.WS2_32.dll_accept]
mov edi, eax
push dword [ebp - 0x18]
push ebx
call fcn.00476a85
pop ecx
pop ecx
cmp edi, 0xffffffff
jne 0x480a50
push 0x408f68
push esi
call fcn.00476566
pop ecx
pop ecx
push 0x1e
jmp 0x4809ee
push 0x408f8c
push esi
call fcn.004765fc
push 1
push edi
mov dword [ebx + 0x134], edi
call fcn.00489b7e
add esp, 0x10
xor eax, eax
jmp 0x4809ef
push 0x408f40
jmp 0x480a44

Function at 0x48282a
Capabilities:
Check http status code

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 0xc]
push ebx
push esi
push edi
push 0x64
cdq
xor esi, esi
pop ebx
idiv ebx
mov edi, dword [ebp + 8]
mov ecx, dword [edi]
cmp eax, 2
je 0x482857
push 0x40948c
push ecx
call fcn.00476566
pop ecx
pop ecx
push 0x11
pop eax
jmp 0x4828ae
cmp dword [ebp + 0xc], 0xc8
je 0x482871
push dword [ebp + 0xc]
push 0x4094a8
push ecx
call fcn.004765fc
add esp, 0xc
mov eax, dword [ebp + 0x10]
cmp eax, 0x13
jne 0x482882
push edi
call fcn.00482449
pop ecx
jmp 0x4828aa
cmp eax, 0x14
jne 0x48288f
push edi
call fcn.00482009
jmp 0x48287f
cmp eax, 0x15
jne 0x482898
push 0xd
jmp 0x48289f
cmp eax, 0x16
jne 0x4828ac
push 0xe
push 1
push edi
call fcn.004824c3
add esp, 0xc
mov esi, eax
mov eax, esi
pop edi
pop esi
pop ebx
pop ebp
ret
Function at 0x485da5
Capabilities:
Initialize winsock library

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x194
mov eax, dword [0x4b1810]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x194]
push eax
push 2
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x485de0
push eax
push 0x40a448
push esi
call fcn.00476566
add esp, 0xc
jmp 0x485e08
call dword [sym.imp.WS2_32.dll_WSACleanup]
mov eax, dword [ebp - 0x194]
cmp al, 2
jne 0x485dfb
shr eax, 8
test al, al
jne 0x485dfb
xor eax, eax
jmp 0x485e0b
push 0x40a460
push esi
call fcn.00476566
pop ecx
pop ecx
push 2
pop eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.00491511
mov esp, ebp
pop ebp
ret

Function at 0x4864c6
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, dword [ebp + 0xc]
push esi
mov esi, dword [ebp + 8]
push edi
push 0
mov byte [ebp + 0xa], al
lea eax, [ebp + 8]
mov edi, dword [esi]
push 3
push eax
push dword [esi + 0x130]
mov byte [ebp + 8], 0xff
mov byte [ebp + 9], bl
call dword [sym.imp.WS2_32.dll_send]
test eax, eax
jns 0x48650e
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push 0x40a4d4
push edi
call fcn.00476566
add esp, 0xc
push dword [ebp + 0x10]
push ebx
push 0x40a4f0
push dword [esi]
call fcn.00485f10
add esp, 0x10
pop edi
pop esi
pop ebx
pop ebp
ret
Function at 0x4865cd
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x90c
mov eax, dword [0x4b1810]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
mov dword [ebp - 0x90c], ebx
mov esi, dword [ebx]
mov dword [ebp - 0x908], esi
mov edi, dword [esi + 0x8664]
mov eax, dword [edi + 0x1ab0]
sub eax, dword [edi + 0x1aac]
add eax, 2
push eax
lea eax, [edi + 0x18ac]
push eax
push 0x3c
push esi
call fcn.00485ff9
mov eax, dword [edi + 0x1aac]
add esp, 0x10
movzx ecx, byte [eax]
inc eax
mov dword [edi + 0x1aac], eax
cmp ecx, 0x18
je 0x48677a
cmp ecx, 0x23
je 0x486756
cmp ecx, 0x27
jne 0x486805
push 0
push ecx
push 0xfa
push 0xff
push 0x40a620
lea eax, [ebp - 0x904]
push 0x800
push eax
call fcn.0046c66c
mov edi, dword [edi + 0x18a8]
add esp, 0x1c
push 4
pop ebx
test edi, edi
je 0x4866ee
mov ecx, dword [edi]
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x48667f
sub ecx, edx
lea esi, [ebx + 1]
add esi, ecx
cmp esi, 0x7fa
jae 0x4866e1
lea eax, [ebp - 0x84]
push eax
lea eax, [ebp - 0x104]
push eax
push 0x40a62c
push dword [edi]
call fcn.00495a07
lea eax, [ebp - 0x84]
push eax
push 1
lea eax, [ebp - 0x104]
push eax
push 0
mov eax, 0x800
sub eax, ebx
push 0x40a63c
push eax
lea eax, [ebp - 0x904]
add eax, ebx
push eax
call fcn.0046c66c
add esp, 0x2c
mov ebx, esi
mov edi, dword [edi + 4]
test edi, edi
jne 0x48667a
mov esi, dword [ebp - 0x908]
push 0xf0
push 0xff
mov eax, 0x800
sub eax, ebx
push 0x40a648
push eax
lea eax, [ebp - 0x904]
add eax, ebx
push eax
call fcn.0046c66c
add esp, 0x14
lea eax, [ebp - 0x904]
add ebx, 2
push 0
push ebx
push eax
mov eax, dword [ebp - 0x90c]
push dword [eax + 0x130]
call dword [sym.imp.WS2_32.dll_send]
test eax, eax
jns 0x48674e
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push 0x40a4d4
push esi
call fcn.00476566
add esp, 0xc
lea eax, [ebx - 2]
jmp 0x4867f2
lea edx, [edi + 0x1828]
mov ecx, edx
lea edi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x486761
push 0xf0
mov eax, 0xff
push eax
push edx
push 0
push 0x23
jmp 0x48679c
lea edx, [edi + 0x1808]
mov ecx, edx
lea edi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x486785
push 0xf0
mov eax, 0xff
push eax
push edx
push 0
push 0x18
push 0xfa
push eax
push 0x40a610
sub ecx, edi
lea eax, [ebp - 0x904]
push 0x800
push eax
lea edi, [ecx + 6]
call fcn.0046c66c
add esp, 0x28
lea eax, [ebp - 0x904]
push 0
push edi
push eax
push dword [ebx + 0x130]
call dword [sym.imp.WS2_32.dll_send]
test eax, eax
jns 0x4867ef
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push 0x40a4d4
push esi
call fcn.00476566
add esp, 0xc
lea eax, [edi - 2]
push eax
lea eax, [ebp - 0x902]
push eax
push 0x3e
push esi
call fcn.00485ff9
add esp, 0x10
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00491511
mov esp, ebp
pop ebp
ret
Function at 0x4874b6
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x8c
mov eax, dword [0x4b1810]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
mov esi, dword [eax + 0x3d0]
mov edi, dword [eax]
mov dword [ebp - 0x8c], eax
lea eax, [ebp - 0x88]
push eax
mov dword [ebp - 0x88], 0x80
lea eax, [ebp - 0x84]
push eax
mov eax, dword [esi + 0x154]
push 0
add eax, 4
push eax
push dword [esi + 0x15c]
push dword [esi + 0x14]
call dword [sym.imp.WS2_32.dll_recvfrom]
cmp dword [esi + 0x148], 0
mov dword [esi + 0x14c], eax
jne 0x487547
push dword [ebp - 0x88]
lea eax, [ebp - 0x84]
push eax
lea eax, [esi + 0xc8]
push eax
call fcn.0048df60
mov eax, dword [ebp - 0x88]
add esp, 0xc
mov dword [esi + 0x148], eax
mov ebx, dword [esi + 0x14c]
cmp ebx, 4
jge 0x487579
push 0x40ac08
push edi
call fcn.00476566
pop ecx
pop ecx
mov dword [esi + 0xc], 7
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00491511
mov esp, ebp
pop ebp
ret
mov ecx, dword [esi + 0x15c]
movzx eax, byte [ecx]
shl ax, 8
movzx edx, ax
movzx eax, byte [ecx + 1]
or edx, eax
mov dword [esi + 0xc], edx
sub edx, 3
je 0x4875fb
dec edx
je 0x48766d
dec edx
je 0x4875d4
dec edx
je 0x4875b9
push 0x40ac24
push 0x413b24
push edi
call fcn.00476566
jmp 0x48766a
lea eax, [ebx - 2]
push eax
lea eax, [ecx + 2]
push eax
push esi
call fcn.00487269
add esp, 0xc
test eax, eax
je 0x48766d
jmp 0x487568
mov edx, ecx
movzx eax, byte [edx + 2]
shl ax, 8
movzx ecx, ax
movzx eax, byte [edx + 3]
or ecx, eax
lea eax, [edx + 4]
push eax
push 0x40681c
push edi
mov dword [esi + 8], ecx
call fcn.004765fc
jmp 0x48766a
cmp ebx, 4
jle 0x48766d
movzx eax, byte [ecx + 2]
shl ax, 8
movzx edx, ax
movzx eax, byte [ecx + 3]
or edx, eax
movzx eax, word [esi + 0x40]
inc eax
and eax, 0xffff
cmp eax, edx
jne 0x48766d
lea eax, [ebx - 4]
push eax
lea eax, [ecx + 4]
push eax
push 1
push dword [ebp - 0x8c]
call fcn.00476369
mov ebx, eax
add esp, 0x10
test ebx, ebx
je 0x48764e
push 5
push esi
call fcn.00487cf3
pop ecx
pop ecx
mov eax, ebx
jmp 0x487568
mov eax, dword [esi + 0x14c]
sub eax, 4
cdq
add dword [edi + 0x38], eax
adc dword [edi + 0x3c], edx
push dword [edi + 0x3c]
push dword [edi + 0x38]
push edi
call fcn.0047e643
add esp, 0xc
push dword [ebp - 0x8c]
call fcn.0047e82d
pop ecx
test eax, eax
je 0x487566
push 5
push esi
call fcn.00487cf3
pop ecx
pop ecx
push 0x2a
pop eax
jmp 0x487568