Function at 0x4037e0
Capabilities:
Get socket status
Print debug messages
Receive data
Receive data on socket
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x36c
mov eax, dword [0x4a3300]
xor eax, esp
mov dword [esp + 0x368], eax
push ebx
xor eax, eax
xorps xmm0, xmm0
push esi
mov word [esp + 0x14], ax
mov esi, ecx
mov dword [esp + 0x1e], eax
mov word [esp + 0x22], ax
lea eax, [esp + 0x14]
push edi
push eax
movq qword [esp + 0x1e], xmm0
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
push 0x40
lea edi, [esi + 0x146]
push 0
push edi
call fcn.00453200
movzx eax, word [esp + 0x30]
add esp, 0xc
push eax
movzx eax, word [esp + 0x26]
push eax
movzx eax, word [esp + 0x28]
push eax
movzx eax, word [esp + 0x2a]
push eax
movzx eax, word [esp + 0x2a]
push eax
movzx eax, word [esp + 0x2c]
push eax
push str._d__02d__02d__02d:_02d:_02d
push edi
call fcn.004582cf
call fcn.00409e10
push 0xc7
mov dword [esp + 0x34], eax
lea eax, [esp + 0x2cd]
push 0
push eax
mov dword [esp + 0x40], edx
mov byte [esp + 0x2d4], 0
call fcn.00453200
movzx eax, word [esi + 0x102]
add esp, 0x2c
push eax
movzx eax, byte [esi + 0x6f]
push eax
movzx eax, byte [esi + 0x6e]
push eax
movzx eax, byte [esi + 0x6d]
push eax
movzx eax, byte [esi + 0x6c]
push eax
movzx eax, word [esi + 0x62]
push eax
call dword [sym.imp.WS2_32.dll_htons]
movzx eax, ax
push eax
movzx eax, byte [esi + 0x67]
push eax
movzx eax, byte [esi + 0x66]
push eax
movzx eax, byte [esi + 0x65]
push eax
movzx eax, byte [esi + 0x64]
push eax
push dword [esi]
lea eax, [esp + 0x2d4]
push 0x4818f8
push eax
call fcn.004582cf
add esp, 0x34
lea eax, [esp + 0x2a8]
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov dx, word [esi + 0x102]
mov ecx, dword [esi + 0x6c]
call fcn.004017a0
mov dword [esi + 4], eax
test eax, eax
je 0x403aca
mov edi, dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ebx, dword [sym.imp.WS2_32.dll_recv]
jmp 0x403920
push 2
push 4
push dword [esi + 0x198]
push dword [esi]
call ebx
test eax, eax
je 0x403a24
cmp eax, 0xffffffff
jne 0x403948
call edi
cmp eax, 0x2733
jne 0x403a24
call fcn.00409e10
sub eax, dword [esp + 0x10]
sbb edx, dword [esp + 0x14]
test edx, edx
jg 0x403a24
jl 0x40396a
cmp eax, 0x7530
ja 0x403a24
push 0x100
lea eax, [esp + 0x38]
push 0
push eax
call fcn.00453200
add esp, 0xc
lea eax, [esp + 0x13c]
push 0x100
push 0
push eax
call fcn.00453200
mov eax, dword [esi + 4]
add esp, 0xc
mov dword [esp + 0x34], eax
mov dword [esp + 0x13c], eax
lea eax, [esp + 0x28]
mov dword [esp + 0x2c], 0
push eax
lea eax, [esp + 0x13c]
mov dword [esp + 0x2c], 0
push eax
push 0
lea eax, [esp + 0x3c]
mov dword [esp + 0x38], 0x64
push eax
push 0
mov dword [esp + 0x44], 1
mov dword [esp + 0x14c], 1
call dword [sym.imp.WS2_32.dll_select]
push 0
push 0
push 0
push dword [esi + 4]
call dword [sym.imp.WS2_32.dll_send]
test eax, eax
je 0x403adf
cmp eax, 0xffffffff
jne 0x403920
call edi
cmp eax, 0x2733
je 0x403920
call edi
cmp eax, 0x2749
je 0x403920
push 0x63
lea eax, [esp + 0x245]
mov byte [esp + 0x244], 0
push 0
push eax
call fcn.00453200
movzx eax, word [esi + 0x102]
add esp, 0xc
push eax
movzx eax, byte [esi + 0x6f]
push eax
movzx eax, byte [esi + 0x6e]
push eax
movzx eax, byte [esi + 0x6d]
push eax
movzx eax, byte [esi + 0x6c]
push eax
movzx eax, word [esi + 0x62]
push eax
mov eax, dword [sym.imp.WS2_32.dll_htons]
call eax
movzx eax, ax
push eax
movzx eax, byte [esi + 0x67]
push eax
movzx eax, byte [esi + 0x66]
push eax
movzx eax, byte [esi + 0x65]
push eax
movzx eax, byte [esi + 0x64]
push eax
call fcn.00409e10
sub eax, dword [esp + 0x38]
sbb edx, dword [esp + 0x3c]
push edx
push eax
push dword [esi]
lea eax, [esp + 0x274]
push 0x481980
push eax
call fcn.004582cf
add esp, 0x3c
lea eax, [esp + 0x240]
push eax
mov eax, dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
call eax
mov eax, dword [esi + 4]
test eax, eax
je 0x403aca
push eax
call dword [sym.imp.WS2_32.dll_closesocket]
mov dword [esi + 4], 0
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x368]
xor ecx, esp
call fcn.004524fc
mov esp, ebp
pop ebp
ret
push 0x63
lea eax, [esp + 0x245]
mov byte [esp + 0x244], 0
push 0
push eax
call fcn.00453200
movzx eax, word [esi + 0x102]
add esp, 0xc
push eax
movzx eax, byte [esi + 0x6f]
push eax
movzx eax, byte [esi + 0x6e]
push eax
movzx eax, byte [esi + 0x6d]
push eax
movzx eax, byte [esi + 0x6c]
push eax
movzx eax, word [esi + 0x62]
push eax
mov eax, dword [sym.imp.WS2_32.dll_htons]
call eax
movzx eax, ax
push eax
movzx eax, byte [esi + 0x67]
push eax
movzx eax, byte [esi + 0x66]
push eax
movzx eax, byte [esi + 0x65]
push eax
movzx eax, byte [esi + 0x64]
push eax
call fcn.00409e10
sub eax, dword [esp + 0x38]
sbb edx, dword [esp + 0x3c]
push edx
push eax
push dword [esi]
lea eax, [esp + 0x274]
push 0x481938
push eax
call fcn.004582cf
add esp, 0x3c
lea eax, [esp + 0x240]
push eax
mov eax, dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
call eax
mov eax, 1
mov word [esi + 0x5e], ax
call fcn.00409e10
mov dword [esi + 0x1d0], eax
mov dword [esi + 0x1d4], edx
call fcn.00409e10
mov ecx, dword [esp + 0x374]
pop edi
mov dword [esi + 0x1c8], eax
mov dword [esi + 0x1cc], edx
pop esi
pop ebx
xor ecx, esp
call fcn.004524fc
mov esp, ebp
pop ebp
ret