Function at 0x446310
Capabilities:
Get socket status
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5641b0
mov eax, dword fs:[0]
push eax
sub esp, 0x44c
mov eax, dword [0x5d21e8]
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 esi, ecx
mov dword [ebp - 0x418], esi
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x440], eax
lea eax, [esi + 0x18]
push eax
mov dword [ebp - 0x434], eax
mov dword [ebp - 0x458], eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov byte [ebp - 0x454], 1
cmp byte [esi + 0xd0], 0
mov eax, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov dword [ebp - 4], 0
mov dword [ebp - 0x444], eax
jne 0x446a56
mov eax, dword [esi + 0xa8]
lea ebx, [esi + 0xa8]
lea ecx, [esi + 0xc0]
mov dword [ebp - 0x428], ecx
mov dword [eax], 0
mov eax, dword [esi + 0xb4]
mov dword [ebx + 8], 0xffffffff
mov dword [eax], 0
mov dword [esi + 0xbc], 0xffffffff
mov eax, dword [ecx]
mov dword [eax], 0
mov dword [ecx + 8], 0xffffffff
xor ecx, ecx
mov eax, dword [ebx]
mov esi, dword [esi + 0x30]
mov edx, dword [eax]
test edx, edx
je 0x4463f1
add eax, 4
cmp dword [eax], esi
je 0x446408
inc ecx
add eax, 4
cmp ecx, edx
jb 0x4463e5
lea eax, [edx + 1]
mov ecx, ebx
push eax
call fcn.00445fa0
mov ecx, dword [ebx]
mov eax, dword [ecx]
mov dword [ecx + eax*4 + 4], esi
mov eax, dword [ebx]
inc dword [eax]
mov ecx, dword [ebp - 0x418]
xor edi, edi
mov dword [ebp - 0x430], edi
mov esi, dword [ecx + 0xcc]
test esi, esi
je 0x446434
mov eax, dword [esi]
mov ecx, esi
mov eax, dword [eax + 4]
call eax
test al, al
je 0x446452
mov esi, dword [esi + 4]
test esi, esi
jne 0x446420
xor cl, cl
mov eax, dword [ebp - 0x418]
mov edx, 3
add eax, 0x3c
mov dword [ebp - 0x41c], edx
mov dword [ebp - 0x42c], eax
jmp 0x44645c
mov cl, 1
jmp 0x446436
mov cl, byte [ebp - 0x411]
test cl, cl
jne 0x44646c
cmp dword [eax + 4], 0
mov byte [ebp - 0x411], cl
je 0x446473
mov byte [ebp - 0x411], 1
mov eax, dword [eax]
mov esi, dword [eax]
cmp esi, eax
je 0x44653e
nop
mov ecx, dword [ebx]
mov edi, esi
mov esi, dword [esi]
mov dword [ebp - 0x448], edi
mov edx, dword [ecx]
lea eax, [edx + 1]
mov dword [ebp - 0x420], eax
mov eax, dword [ebx + 4]
cmp dword [ebp - 0x420], eax
jbe 0x446519
mov ecx, dword [ebp - 0x420]
shr eax, 1
add eax, dword [ebx + 4]
cmp eax, ecx
cmovae ecx, eax
mov dword [ebp - 0x420], ecx
lea eax, [ecx*4 + 4]
push eax
call fcn.0053274c
mov ecx, dword [ebx]
add esp, 4
mov dword [ebp - 0x424], eax
mov ecx, dword [ecx]
mov dword [eax], ecx
xor ecx, ecx
mov edx, dword [ebx]
cmp dword [edx], ecx
jbe 0x4464fd
add eax, 4
mov dword [ebp - 0x450], eax
mov edi, eax
mov eax, dword [ebx]
mov eax, dword [eax + ecx*4 + 4]
mov dword [edi + ecx*4], eax
inc ecx
mov edx, dword [ebx]
cmp ecx, dword [edx]
jb 0x4464e7
mov edi, dword [ebp - 0x448]
push edx
call fcn.00532a98
mov ecx, dword [ebp - 0x424]
add esp, 4
mov eax, dword [ebp - 0x420]
mov dword [ebx], ecx
mov dword [ebx + 4], eax
mov edx, dword [ecx]
mov eax, dword [edi + 8]
mov dword [ecx + edx*4 + 4], eax
mov eax, dword [ebx]
inc dword [eax]
mov eax, dword [ebp - 0x42c]
cmp esi, dword [eax]
jne 0x446480
mov edi, dword [ebp - 0x430]
mov edx, dword [ebp - 0x41c]
cmp dword [ebx + 8], edi
mov eax, dword [ebp - 0x42c]
cmova edi, dword [ebx + 8]
add eax, 0x1c
add ebx, 0xc
mov dword [ebp - 0x430], edi
sub edx, 1
mov dword [ebp - 0x42c], eax
mov dword [ebp - 0x41c], edx
jne 0x446456
cmp byte [ebp - 0x411], 0
mov eax, dword [ebp - 0x418]
jne 0x44658b
cmp dword [eax + 0x94], 0
mov byte [ebp - 0x411], 0
je 0x446592
mov byte [ebp - 0x411], 1
mov ebx, dword [ebp - 0x440]
lea esi, [eax + 0x8c]
push ebx
push esi
lea ecx, [eax + 0xb4]
call fcn.00446f90
mov ecx, dword [ebp - 0x418]
push ebx
push esi
mov eax, dword [ecx + 0xbc]
cmp eax, edi
mov ecx, dword [ebp - 0x428]
cmova edi, eax
call fcn.00446f90
mov edx, dword [ebp - 0x418]
mov eax, dword [edx + 0xc8]
cmp eax, edi
cmovbe eax, edi
mov dword [ebp - 0x448], eax
mov al, byte [ebp + 8]
test al, al
jne 0x4465f3
cmp byte [ebp - 0x411], al
je 0x446a50
mov dword [ebp - 0x43c], 0
mov dword [ebp - 0x438], 0
test al, al
je 0x446656
mov esi, dword [edx + 0xcc]
mov ecx, 0x11e1a300
test esi, esi
je 0x446631
nop word [eax + eax]
mov eax, dword [esi]
push ecx
mov ecx, esi
call dword [eax + 0xc]
mov esi, dword [esi + 4]
mov ecx, eax
test esi, esi
jne 0x446620
mov eax, 0x431bde83
imul ecx
sar edx, 0x12
mov eax, edx
shr eax, 0x1f
add eax, edx
mov dword [ebp - 0x43c], eax
imul eax, eax, 0xf4240
sub ecx, eax
mov dword [ebp - 0x438], ecx
push dword [ebp - 0x434]
call dword [ebp - 0x444]
call fcn.0052c940
mov eax, dword [ebp - 0x428]
mov ecx, dword [ebp - 0x418]
push 0
mov esi, dword [eax]
mov eax, dword [ecx + 0xa8]
mov edi, dword [ecx + 0xb4]
mov dword [ebp - 0x424], eax
call dword [sym.imp.WS2_32.dll_WSASetLastError]
mov edx, dword [ebp - 0x424]
test edx, edx
jne 0x4466f6
test edi, edi
jne 0x4466f6
test esi, esi
jne 0x4466f6
mov eax, 0x10624dd3
imul dword [ebp - 0x438]
imul eax, dword [ebp - 0x43c], 0x3e8
sar edx, 6
mov ecx, edx
shr ecx, 0x1f
add ecx, edx
add ecx, eax
mov eax, 1
cmove ecx, eax
push ecx
call dword [sym.imp.KERNEL32.dll_Sleep]
call fcn.0052c940
push dword [ebp - 0x434]
mov eax, dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
call eax
mov al, 1
mov byte [ebp - 0x411], al
mov byte [ebp - 0x454], al
jmp 0x446a28
cmp dword [ebp - 0x43c], 0
jne 0x446724
mov ecx, dword [ebp - 0x438]
mov dword [ebp - 0x424], 0x3e8
lea eax, [ecx - 1]
cmp eax, 0x3e6
cmovbe ecx, dword [ebp - 0x424]
mov dword [ebp - 0x438], ecx
lea eax, [ebp - 0x43c]
push eax
mov eax, dword [ebp - 0x448]
push esi
push edi
push edx
inc eax
push eax
call dword [sym.imp.WS2_32.dll_select]
mov edi, eax
call fcn.0052c940
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
test edi, edi
js 0x446754
call fcn.0052c940
test edi, edi
jle 0x44688e
mov esi, dword [ebp - 0x418]
push dword [esi + 0xa8]
push dword [esi + 0x30]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x44688e
lea eax, [ebp - 0x410]
mov dword [ebp - 0x44c], 0x400
mov dword [ebp - 0x448], eax
call fcn.0052c940
mov esi, dword [esi + 0x30]
push 0
call dword [sym.imp.WS2_32.dll_WSASetLastError]
push 0
push 0
lea eax, [ebp - 0x424]
mov dword [ebp - 0x41c], 0
push eax
lea eax, [ebp - 0x41c]
mov dword [ebp - 0x424], 0
push eax
push 1
lea eax, [ebp - 0x44c]
push eax
push esi
call dword [sym.imp.WS2_32.dll_WSARecv]
mov esi, eax
call fcn.0052c940
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x40
je 0x4467eb
cmp eax, 0x4d2
jne 0x4467f0
call fcn.0052c940
test esi, esi
jne 0x44688d
call fcn.0052c940
cmp dword [ebp - 0x41c], 0x400
jne 0x44688d
mov ebx, dword [ebp - 0x418]
mov esi, dword [ebx + 0x30]
push 0
call dword [sym.imp.WS2_32.dll_WSASetLastError]
push 0
push 0
lea eax, [ebp - 0x424]
mov dword [ebp - 0x41c], 0
push eax
lea eax, [ebp - 0x41c]
mov dword [ebp - 0x424], 0
push eax
push 1
lea eax, [ebp - 0x44c]
push eax
push esi
call dword [sym.imp.WS2_32.dll_WSARecv]
mov esi, eax
call fcn.0052c940
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x40
je 0x44686d
cmp eax, 0x4d2
jne 0x446872
call fcn.0052c940
test esi, esi
jne 0x446887
call fcn.0052c940
cmp dword [ebp - 0x41c], 0x400
je 0x446813
mov ebx, dword [ebp - 0x440]
dec edi
push dword [ebp - 0x434]
mov eax, dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
call eax
mov al, 1
mov byte [ebp - 0x411], al
mov byte [ebp - 0x454], al
test edi, edi
jle 0x446a28
mov edi, dword [ebp - 0x418]
mov ecx, dword [ebp - 0x428]
push ebx
lea esi, [edi + 0x8c]
push esi
call fcn.00445580
push ebx
push esi
lea ecx, [edi + 0xb4]
call fcn.00445580
mov eax, dword [ebp - 0x428]
mov edx, 2
add edi, 0x88
mov dword [ebp - 0x430], edx
mov dword [ebp - 0x42c], edi
mov eax, dword [eax]
xor ecx, ecx
mov dword [ebp - 0x41c], ecx
cmp dword [eax], ecx
jbe 0x446a01
lea edx, [edi - 0x14]
mov dword [ebp - 0x420], edx
nop
mov esi, dword [edi]
mov ecx, dword [eax + ecx*4 + 4]
test esi, esi
je 0x4469de
xor edx, edx
mov ebx, dword [ebp - 0x420]
mov eax, ecx
div esi
mov eax, dword [edi - 4]
mov esi, dword [eax + edx*8]
cmp esi, dword [ebx]
mov ebx, dword [ebp - 0x440]
je 0x4469de
mov eax, dword [eax + edx*8 + 4]
mov eax, dword [eax]
cmp esi, eax
je 0x4469de
nop dword [eax]
cmp dword [esi + 8], ecx
je 0x446960
mov esi, dword [esi]
cmp esi, eax
jne 0x446950
jmp 0x4469de
lea eax, [edi - 0x14]
mov dword [ebp - 0x420], eax
cmp esi, dword [eax]
je 0x4469de
mov edi, dword [esi + 0xc]
mov dword [ebp - 0x420], eax
test edi, edi
je 0x4469c7
mov dword [ebp - 0x420], eax
mov eax, dword [edi + 0x2c]
push edi
call eax
add esp, 4
test al, al
je 0x4469d8
mov ecx, dword [esi + 0xc]
test ecx, ecx
je 0x4469a8
mov eax, dword [ecx + 0x14]
mov dword [esi + 0xc], eax
test eax, eax
jne 0x4469a1
mov dword [esi + 0x10], eax
mov dword [ecx + 0x14], 0
mov dword [edi + 0x14], 0
mov eax, dword [ebx + 4]
test eax, eax
je 0x4469bb
mov dword [eax + 0x14], edi
jmp 0x4469bd
mov dword [ebx], edi
mov dword [ebx + 4], edi
mov edi, dword [esi + 0xc]
test edi, edi
jne 0x446980
mov edi, dword [ebp - 0x42c]
push esi
lea ecx, [edi - 0x18]
call fcn.004428c0
jmp 0x4469de
mov edi, dword [ebp - 0x42c]
mov eax, dword [ebp - 0x428]
mov ecx, dword [ebp - 0x41c]
inc ecx
mov dword [ebp - 0x41c], ecx
mov eax, dword [eax]
cmp ecx, dword [eax]
jb 0x446910
mov edx, dword [ebp - 0x430]
mov eax, dword [ebp - 0x428]
dec edx
sub eax, 0xc
mov dword [ebp - 0x430], edx
sub edi, 0x1c
mov dword [ebp - 0x428], eax
mov dword [ebp - 0x42c], edi
test edx, edx
jns 0x4468f4
mov eax, dword [ebp - 0x418]
mov esi, dword [eax + 0xcc]
test esi, esi
je 0x446a47
mov eax, dword [esi]
mov ecx, esi
push ebx
call dword [eax + 0x10]
mov esi, dword [esi + 4]
test esi, esi
jne 0x446a38
cmp byte [ebp - 0x411], 0
je 0x446a5e
mov eax, dword [ebp - 0x444]
push dword [ebp - 0x434]
call eax
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.005329db
mov esp, ebp
pop ebp
ret 8