Function at 0x410c50
Capabilities:
Receive data
Receive data on socket
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1074
call fcn.0043d750
mov eax, dword [0x47b014]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov eax, ecx
mov dword [ebp - 0x50], 1
mov ecx, dword [ebp + 8]
push edi
mov dword [ebp - 0x106c], eax
mov edi, dword [eax + 0x3fa0]
mov dword [ecx], 0
mov dword [ebp - 0x1074], ecx
movzx ecx, word [edx + 1]
mov eax, ecx
mov dword [ebp - 0x1070], edx
shr eax, 8
add al, 0x55
mov dword [ebp - 0x1068], 0
add al, byte [edx]
add al, cl
add ecx, 4
mov byte [edx + 3], al
mov eax, dword [edi + 4]
push 0
mov dword [ebp - 0x3c], eax
lea eax, [ebp - 0x4c]
push eax
push 0
lea eax, [ebp - 0x1068]
mov dword [ebp - 0x34], edx
push eax
push 1
lea eax, [ebp - 0x38]
mov dword [ebp - 0x38], ecx
push eax
mov byte [ebp - 0x30], 0
push dword [edi]
call dword [sym.imp.WS2_32.dll_WSASend]
mov ebx, dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edx, 2
test eax, eax
jne 0x410d32
mov ecx, dword [ebp - 0x1068]
mov eax, dword [ebp - 0x38]
cmp ecx, eax
ja 0x410d0f
add dword [ebp - 0x34], ecx
sub eax, ecx
mov dword [ebp - 0x38], eax
mov eax, dword [ebp - 0x50]
cmove eax, edx
mov dword [ebp - 0x50], eax
jmp 0x410d4c
xor edx, edx
mov dword [ebp - 0x50], 3
mov ecx, edi
call fcn.00410480
mov esi, eax
mov dword [ebp - 0x28], 0
test esi, esi
jne 0x410fc4
jmp 0x410d51
cmp eax, 0xffffffff
jne 0x410fb1
call ebx
cmp eax, 0x3e5
jne 0x410fb1
mov byte [ebp - 0x30], 1
xor esi, esi
mov dword [ebp - 0x28], esi
cmp dword [ebp - 0x28], 0
jne 0x410fa3
mov dword [ebp - 0x28], 1
mov eax, dword [edi + 8]
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x1064]
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0x24]
push 0
push eax
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x10], 4
push eax
lea eax, [ebp - 0x1068]
mov byte [ebp - 8], 0
push eax
push 1
lea eax, [ebp - 0x10]
mov dword [ebp - 0x1068], 0
push eax
push dword [edi]
mov dword [ebp - 0x2c], 0
call dword [sym.imp.WS2_32.dll_WSARecv]
test eax, eax
jne 0x410df1
mov ecx, dword [ebp - 0x1068]
mov eax, dword [ebp - 0x10]
cmp ecx, eax
ja 0x410dd5
add dword [ebp - 0xc], ecx
sub eax, ecx
mov dword [ebp - 0x10], eax
mov ecx, 2
mov eax, dword [ebp - 0x28]
cmove eax, ecx
mov dword [ebp - 0x28], eax
jmp 0x410e0b
xor edx, edx
mov dword [ebp - 0x28], 3
mov ecx, edi
call fcn.00410480
mov esi, eax
test esi, esi
jne 0x410fc4
jmp 0x410e10
cmp eax, 0xffffffff
jne 0x410f9a
call ebx
cmp eax, 0x3e5
jne 0x410f9a
mov byte [ebp - 8], 1
xor esi, esi
nop dword [eax]
cmp dword [ebp - 0x28], 1
jne 0x410e32
lea eax, [ebp - 0x28]
mov ecx, edi
push eax
lea edx, [ebp - 0x50]
call fcn.00410a80
mov esi, eax
add esp, 4
test esi, esi
je 0x410e10
jmp 0x410fc4
cmp dword [ebp - 0x28], 2
jne 0x410fbf
mov eax, dword [ebp - 0x1063]
mov cl, byte [ebp - 0x1064]
shr eax, 8
add al, 0x55
add al, byte [ebp - 0x1063]
add al, cl
cmp byte [ebp - 0x1061], al
jne 0x410f91
mov ax, word [ebp - 0x1063]
test ax, ax
je 0x410f50
movzx ecx, ax
mov dword [ebp - 0x28], 1
mov eax, dword [edi + 8]
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x1060]
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0x24]
push 0
push eax
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x10], ecx
push eax
lea eax, [ebp - 0x1068]
mov byte [ebp - 8], 0
push eax
push 1
lea eax, [ebp - 0x10]
mov dword [ebp - 0x1068], 0
push eax
push dword [edi]
mov dword [ebp - 0x2c], 0
call dword [sym.imp.WS2_32.dll_WSARecv]
test eax, eax
jne 0x410f06
mov ecx, dword [ebp - 0x1068]
mov eax, dword [ebp - 0x10]
cmp ecx, eax
ja 0x410eea
add dword [ebp - 0xc], ecx
sub eax, ecx
mov dword [ebp - 0x10], eax
mov ecx, 2
mov eax, dword [ebp - 0x28]
cmove eax, ecx
mov dword [ebp - 0x28], eax
jmp 0x410f20
xor edx, edx
mov dword [ebp - 0x28], 3
mov ecx, edi
call fcn.00410480
mov esi, eax
test esi, esi
jne 0x410fc4
jmp 0x410f22
cmp eax, 0xffffffff
jne 0x410f9a
call ebx
cmp eax, 0x3e5
jne 0x410f9a
mov byte [ebp - 8], 1
xor esi, esi
cmp dword [ebp - 0x28], 1
jne 0x410f44
lea eax, [ebp - 0x28]
mov ecx, edi
push eax
lea edx, [ebp - 0x50]
call fcn.00410a80
mov esi, eax
add esp, 4
test esi, esi
je 0x410f22
jmp 0x410fc4
cmp dword [ebp - 0x28], 2
jne 0x410fbf
mov cl, byte [ebp - 0x1064]
cmp cl, 0xfe
jne 0x410f72
mov ecx, dword [ebp - 0x106c]
lea edx, [ebp - 0x1064]
mov dword [ebp - 0x28], 0
call fcn.004149b0
jmp 0x410d51
push 0x1012
lea eax, [ebp - 0x1064]
push eax
push dword [ebp - 0x1070]
call fcn.00424db0
add esp, 0xc
jmp 0x410d51
mov eax, dword [ebp - 0x1074]
or dword [eax], 1
mov dword [ebp - 0x28], 3
jmp 0x410fbf
cmp dword [ebp - 0x50], 2
jne 0x410fbf
cmp dword [ebp - 0x28], 2
je 0x410fea
jmp 0x410fbf
mov dword [ebp - 0x50], 3
mov dword [ebp - 0x28], 0
mov esi, 9
push dword [edi]
call dword [sym.imp.KERNEL32.dll_CancelIo]
mov eax, dword [edi]
cmp eax, 0xffffffff
je 0x410fea
push 2
push eax
call dword [sym.imp.WS2_32.dll_shutdown]
push dword [edi]
call dword [sym.imp.WS2_32.dll_closesocket]
mov dword [edi], 0xffffffff
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00422009
mov esp, ebp
pop ebp
ret