Function at 0x4215b0
Capabilities:
Check for time delay via gettickcount
Get socket status

Disassembly:
sub esp, 0x330
mov ecx, dword [esp + 0x33c]
mov edx, dword [esp + 0x338]
push ebx
push ebp
mov ebp, dword [esp + 0x33c]
push esi
xor esi, esi
push edi
xor edi, edi
mov dword [esp + 0x18], esi
mov dword [esp + 0x1c], esi
cmp ebp, esi
je 0x4215f1
xor eax, eax
cmp edx, esi
jbe 0x4215f1
cmp dword [ebp + eax*8], 0xffffffff
jne 0x421624
inc eax
cmp eax, edx
jb 0x4215e5
cmp ecx, esi
je 0x421617
jge 0x421610
push 0x2726
call dword [sym.imp.WS2_32.dll_WSASetLastError]
or eax, 0xffffffff
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x330
ret
push ecx
call dword [sym.imp.KERNEL32.dll_Sleep]
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x330
ret
cmp ecx, esi
jle 0x421654
mov edi, ecx
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, eax
mov eax, 0x10624dd3
mul ecx
shr edx, 6
mov eax, edx
imul eax, eax, 0x3e8
sub ecx, eax
imul ecx, ecx, 0x3e8
mov dword [esp + 0x18], edx
mov dword [esp + 0x1c], ecx
xor ecx, ecx
xor ebx, ebx
xor eax, eax
mov dword [esp + 0x130], ecx
mov dword [esp + 0x28], esi
mov dword [esp + 0x238], ebx
mov dword [esp + 0x14], 0xffffffff
mov dword [esp + 0x10], eax
jmp 0x421687
mov ebp, dword [esp + 0x344]
xor edx, edx
mov word [ebp + eax*8 + 6], dx
mov ebp, dword [ebp + eax*8]
cmp ebp, 0xffffffff
je 0x421762
mov edx, dword [esp + 0x344]
movzx edx, word [edx + eax*8 + 4]
test dl, 7
je 0x421762
cmp ebp, dword [esp + 0x14]
jbe 0x4216ba
mov dword [esp + 0x14], ebp
test dl, 1
je 0x4216f6
xor eax, eax
test ecx, ecx
jbe 0x4216d3
cmp dword [esp + eax*4 + 0x134], ebp
je 0x4216d3
inc eax
cmp eax, ecx
jb 0x4216c5
cmp eax, ecx
jne 0x4216f2
cmp ecx, 0x40
jae 0x4216f2
mov dword [esp + eax*4 + 0x134], ebp
mov ecx, dword [esp + 0x130]
inc ecx
mov dword [esp + 0x130], ecx
mov eax, dword [esp + 0x10]
test dl, 4
je 0x421726
xor eax, eax
test esi, esi
jbe 0x42170c
cmp dword [esp + eax*4 + 0x2c], ebp
je 0x42170c
inc eax
cmp eax, esi
jb 0x421701
cmp eax, esi
jne 0x421722
cmp esi, 0x40
jae 0x421722
mov dword [esp + eax*4 + 0x2c], ebp
mov esi, dword [esp + 0x28]
inc esi
mov dword [esp + 0x28], esi
mov eax, dword [esp + 0x10]
test dl, 2
je 0x421762
xor eax, eax
test ebx, ebx
jbe 0x42173f
cmp dword [esp + eax*4 + 0x23c], ebp
je 0x42173f
inc eax
cmp eax, ebx
jb 0x421731
cmp eax, ebx
jne 0x42175e
cmp ebx, 0x40
jae 0x42175e
mov dword [esp + eax*4 + 0x23c], ebp
mov ebx, dword [esp + 0x238]
inc ebx
mov dword [esp + 0x238], ebx
mov eax, dword [esp + 0x10]
inc eax
mov dword [esp + 0x10], eax
cmp eax, dword [esp + 0x348]
jb 0x421680
test ecx, ecx
jne 0x4217a5
test esi, esi
jne 0x4217a5
test ebx, ebx
jne 0x4217a5
mov eax, dword [esp + 0x34c]
test eax, eax
je 0x421798
jl 0x4215f7
push eax
call dword [sym.imp.KERNEL32.dll_Sleep]
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x330
ret
mov ebp, dword [esp + 0x34c]
xor eax, eax
test ebp, ebp
setl al
lea edx, [esp + 0x20]
dec eax
and eax, edx
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x14]
inc eax
mov dword [esp + 0x14], eax
jmp 0x4217e2
mov ebx, dword [esp + 0x238]
mov esi, dword [esp + 0x28]
mov ecx, dword [esp + 0x130]
xor eax, eax
cmp ebp, eax
jle 0x421813
mov eax, 0x10624dd3
imul edi
sar edx, 6
mov eax, edx
shr eax, 0x1f
add eax, edx
mov dword [esp + 0x20], eax
imul eax, eax, 0x3e8
mov edx, edi
sub edx, eax
imul edx, edx, 0x3e8
mov dword [esp + 0x24], edx
jmp 0x42181d
jne 0x42181d
mov dword [esp + 0x20], eax
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x10]
neg ebx
sbb ebx, ebx
push eax
lea edx, [esp + 0x23c]
and ebx, edx
neg esi
sbb esi, esi
lea eax, [esp + 0x2c]
and esi, eax
mov eax, dword [esp + 0x18]
neg ecx
push ebx
sbb ecx, ecx
lea edx, [esp + 0x138]
push esi
and ecx, edx
push ecx
push eax
call dword [sym.imp.WS2_32.dll_select]
mov esi, eax
cmp esi, 0xffffffff
jne 0x4218d3
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
test eax, eax
je 0x421875
cmp dword [0x470818], 0
jne 0x4218d3
cmp eax, 0x2714
jne 0x4218d3
test ebp, ebp
jle 0x4217d0
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, eax
mov eax, 0x10624dd3
mul ecx
mov esi, edx
shr esi, 6
mov edx, esi
imul edx, edx, 0x3e8
sub ecx, edx
imul ecx, ecx, 0x3e8
mov eax, ecx
sub eax, dword [esp + 0x1c]
push 0
cdq
push 0x3e8
push edx
push eax
call fcn.00449630
mov edi, dword [esp + 0x18]
sub edi, esi
imul edi, edi, 0x3e8
sub edi, eax
add edi, ebp
test edi, edi
jle 0x421617
jmp 0x4217d0
test esi, esi
jl 0x421602
je 0x421617
mov esi, dword [esp + 0x344]
mov edi, dword [esp + 0x348]
xor ebx, ebx
add esi, 6
xor eax, eax
mov word [esi], ax
mov eax, dword [esi - 6]
cmp eax, 0xffffffff
je 0x42194d
lea ecx, [esp + 0x130]
push ecx
push eax
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x421917
or word [esi], 1
mov eax, dword [esi - 6]
lea edx, [esp + 0x28]
push edx
push eax
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x42192d
or word [esi], 4
mov edx, dword [esi - 6]
lea ecx, [esp + 0x238]
push ecx
push edx
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x421946
or word [esi], 2
cmp word [esi], 0
je 0x42194d
inc ebx
add esi, 8
sub edi, 1
jne 0x4218f4
pop edi
pop esi
pop ebp
mov eax, ebx
pop ebx
add esp, 0x330
ret