Function at 0x460821
Capabilities:
Get socket status

Disassembly:
push ebp
mov ebp, esp
push esi
push ebx
sub esp, 0x4f0
cmp dword [ebp + 8], 0x40
jle 0x460839
mov dword [ebp + 8], 0x40
cmp dword [ebp + 0x18], 0
jne 0x460848
mov dword [ebp - 0xc], 0xffffffff
jmp 0x46089f
mov eax, dword [ebp + 0x18]
mov eax, dword [eax]
imul ebx, eax, 0x3e8
mov eax, dword [ebp + 0x18]
mov ecx, dword [eax + 4]
mov edx, 0x10624dd3
mov eax, ecx
imul edx
sar edx, 6
mov eax, ecx
sar eax, 0x1f
sub edx, eax
mov eax, edx
add eax, ebx
mov dword [ebp - 0xc], eax
cmp dword [ebp + 0xc], 0
jne 0x46089f
cmp dword [ebp + 0x10], 0
jne 0x46089f
cmp dword [ebp + 0x14], 0
jne 0x46089f
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_Sleep]
call eax
sub esp, 4
mov eax, 0
jmp 0x4617de
mov eax, dword [0x6ea2b8]
test eax, eax
jne 0x4608d6
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov dword [esp], 0
mov eax, dword [sym.imp.KERNEL32.dll_CreateEventA]
call eax
sub esp, 0x10
mov dword [0x6ea2b8], eax
mov eax, dword [0x6ea2b8]
mov dword [ebp - 0x170], eax
mov dword [ebp - 0x10], 1
mov dword [ebp - 0x14], 0
mov dword [esp + 8], 0x10
mov dword [esp + 4], 0
lea eax, [ebp - 0x48c]
mov dword [esp], eax
call sub.msvcrt.dll_memset
mov dword [esp + 8], 0x10
mov dword [esp + 4], 0
lea eax, [ebp - 0x49c]
mov dword [esp], eax
call sub.msvcrt.dll_memset
mov dword [esp + 8], 0x10
mov dword [esp + 4], 0
lea eax, [ebp - 0x4ac]
mov dword [esp], eax
call sub.msvcrt.dll_memset
mov dword [esp + 8], 8
mov dword [esp + 4], 0
lea eax, [ebp - 0x4b4]
mov dword [esp], eax
call sub.msvcrt.dll_memset
cmp dword [ebp + 0xc], 0
je 0x460a41
mov dword [ebp - 0x18], 0
jmp 0x460a2f
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp - 0x18]
mov eax, dword [eax + edx*4 + 4]
mov dword [ebp - 0x58], eax
mov eax, dword [ebp - 0x58]
mov dword [esp], eax
call fcn.0044e87c
mov dword [ebp - 0x5c], eax
mov eax, dword [ebp - 0x5c]
mov dword [esp], eax
call fcn.00460320
test eax, eax
je 0x4609c7
lea eax, [ebp - 0x4b8]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x5c]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_GetNumberOfConsoleInputEvents]
call eax
sub esp, 8
test eax, eax
jne 0x4609c7
jmp 0x460a2b
mov eax, dword [ebp - 0x58]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx edx, byte [ebp + eax - 0x48c]
mov ebx, edx
mov edx, dword [ebp - 0x58]
and edx, 7
mov esi, 1
mov ecx, edx
shl esi, cl
mov edx, esi
or edx, ebx
mov byte [ebp + eax - 0x48c], dl
mov eax, dword [ebp - 0x58]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx edx, byte [ebp + eax - 0x4b4]
mov ebx, edx
mov edx, dword [ebp - 0x58]
and edx, 7
mov esi, 1
mov ecx, edx
shl esi, cl
mov edx, esi
or edx, ebx
mov byte [ebp + eax - 0x4b4], dl
add dword [ebp - 0x18], 1
mov edx, dword [ebp - 0x18]
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
cmp edx, eax
jb 0x46097d
jmp 0x460a74
mov eax, 0x10
sub eax, 1
add eax, 0x113
mov ebx, 0x10
mov edx, 0
div ebx
imul eax, eax, 0x10
call fcn.00625290
sub esp, eax
lea eax, [esp + 0x14]
add eax, 0xf
shr eax, 4
shl eax, 4
mov dword [ebp + 0xc], eax
cmp dword [ebp + 0x10], 0
je 0x460b4e
mov dword [ebp - 0x18], 0
jmp 0x460b3c
mov eax, dword [ebp + 0x10]
mov edx, dword [ebp - 0x18]
mov eax, dword [eax + edx*4 + 4]
mov dword [ebp - 0x58], eax
mov eax, dword [ebp - 0x58]
mov dword [esp], eax
call fcn.0044e87c
mov dword [ebp - 0x5c], eax
mov eax, dword [ebp - 0x5c]
mov dword [esp], eax
call fcn.00460320
test eax, eax
je 0x460ad4
lea eax, [ebp - 0x4b8]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x5c]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_GetNumberOfConsoleInputEvents]
call eax
sub esp, 8
test eax, eax
je 0x460ad4
jmp 0x460b38
mov eax, dword [ebp - 0x58]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx edx, byte [ebp + eax - 0x49c]
mov ebx, edx
mov edx, dword [ebp - 0x58]
and edx, 7
mov esi, 1
mov ecx, edx
shl esi, cl
mov edx, esi
or edx, ebx
mov byte [ebp + eax - 0x49c], dl
mov eax, dword [ebp - 0x58]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx edx, byte [ebp + eax - 0x4b4]
mov ebx, edx
mov edx, dword [ebp - 0x58]
and edx, 7
mov esi, 1
mov ecx, edx
shl esi, cl
mov edx, esi
or edx, ebx
mov byte [ebp + eax - 0x4b4], dl
add dword [ebp - 0x18], 1
mov edx, dword [ebp - 0x18]
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
cmp edx, eax
jb 0x460a8a
jmp 0x460b81
mov eax, 0x10
sub eax, 1
add eax, 0x113
mov ebx, 0x10
mov edx, 0
div ebx
imul eax, eax, 0x10
call fcn.00625290
sub esp, eax
lea eax, [esp + 0x14]
add eax, 0xf
shr eax, 4
shl eax, 4
mov dword [ebp + 0x10], eax
cmp dword [ebp + 0x14], 0
je 0x460c1b
mov dword [ebp - 0x18], 0
jmp 0x460c09
mov eax, dword [ebp + 0x14]
mov edx, dword [ebp - 0x18]
mov eax, dword [eax + edx*4 + 4]
mov dword [ebp - 0x58], eax
mov eax, dword [ebp - 0x58]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx edx, byte [ebp + eax - 0x4ac]
mov ebx, edx
mov edx, dword [ebp - 0x58]
and edx, 7
mov esi, 1
mov ecx, edx
shl esi, cl
mov edx, esi
or edx, ebx
mov byte [ebp + eax - 0x4ac], dl
mov eax, dword [ebp - 0x58]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx edx, byte [ebp + eax - 0x4b4]
mov ebx, edx
mov edx, dword [ebp - 0x58]
and edx, 7
mov esi, 1
mov ecx, edx
shl esi, cl
mov edx, esi
or edx, ebx
mov byte [ebp + eax - 0x4b4], dl
add dword [ebp - 0x18], 1
mov edx, dword [ebp - 0x18]
mov eax, dword [ebp + 0x14]
mov eax, dword [eax]
cmp edx, eax
jb 0x460b94
jmp 0x460c4e
mov eax, 0x10
sub eax, 1
add eax, 0x113
mov ebx, 0x10
mov edx, 0
div ebx
imul eax, eax, 0x10
call fcn.00625290
sub esp, eax
lea eax, [esp + 0x14]
add eax, 0xf
shr eax, 4
shl eax, 4
mov dword [ebp + 0x14], eax
mov eax, dword [ebp + 0xc]
mov dword [eax], 0
mov eax, dword [ebp + 0x10]
mov dword [eax], 0
mov eax, dword [ebp + 0x14]
mov dword [eax], 0
mov dword [ebp - 0x274], 0
mov dword [ebp - 0x378], 0
mov dword [ebp - 0x47c], 0
mov dword [ebp - 0x18], 0
jmp 0x461043
mov eax, dword [ebp - 0x18]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx eax, byte [ebp + eax - 0x4b4]
movzx edx, al
mov eax, dword [ebp - 0x18]
and eax, 7
mov ecx, eax
sar edx, cl
mov eax, edx
and eax, 1
test eax, eax
jne 0x460cc4
jmp 0x46103f
mov eax, dword [ebp - 0x18]
mov dword [esp], eax
call fcn.0044e87c
mov dword [ebp - 0x5c], eax
cmp dword [ebp - 0x5c], 0
jne 0x460cef
mov eax, dword [sym.imp.msvcrt.dll__errno]
call eax
mov dword [eax], 9
mov eax, 0xffffffff
jmp 0x4617de
mov eax, dword [ebp - 0x5c]
mov dword [esp], eax
call fcn.00460347
test eax, eax
je 0x460feb
mov dword [ebp - 0x24], 0x20
mov eax, dword [ebp - 0x18]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx eax, byte [ebp + eax - 0x48c]
movzx edx, al
mov eax, dword [ebp - 0x18]
and eax, 7
mov ecx, eax
sar edx, cl
mov eax, edx
and eax, 1
test eax, eax
je 0x460df2
or dword [ebp - 0x24], 9
mov dword [ebp - 0x28], 0
jmp 0x460d5d
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp - 0x28]
mov edx, dword [eax + edx*4 + 4]
mov eax, dword [ebp - 0x5c]
cmp edx, eax
jne 0x460d59
jmp 0x460d67
add dword [ebp - 0x28], 1
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x28]
ja 0x460d46
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x28]
jne 0x460d95
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
cmp eax, 0x3f
ja 0x460d95
mov ecx, dword [ebp - 0x5c]
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp - 0x28]
mov dword [eax + edx*4 + 4], ecx
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
lea edx, [eax + 1]
mov eax, dword [ebp + 0xc]
mov dword [eax], edx
mov dword [ebp - 0x2c], 0
jmp 0x460db5
mov eax, dword [ebp - 0x2c]
mov edx, dword [ebp + eax*4 - 0x270]
mov eax, dword [ebp - 0x5c]
cmp edx, eax
jne 0x460db1
jmp 0x460dc0
add dword [ebp - 0x2c], 1
mov eax, dword [ebp - 0x274]
cmp eax, dword [ebp - 0x2c]
ja 0x460d9e
mov eax, dword [ebp - 0x274]
cmp eax, dword [ebp - 0x2c]
jne 0x460df2
mov eax, dword [ebp - 0x274]
cmp eax, 0x3f
ja 0x460df2
mov edx, dword [ebp - 0x5c]
mov eax, dword [ebp - 0x2c]
mov dword [ebp + eax*4 - 0x270], edx
mov eax, dword [ebp - 0x274]
add eax, 1
mov dword [ebp - 0x274], eax
mov eax, dword [ebp - 0x18]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx eax, byte [ebp + eax - 0x49c]
movzx edx, al
mov eax, dword [ebp - 0x18]
and eax, 7
mov ecx, eax
sar edx, cl
mov eax, edx
and eax, 1
test eax, eax
je 0x460edb
or dword [ebp - 0x24], 0x12
mov dword [ebp - 0x30], 0
jmp 0x460e46
mov eax, dword [ebp + 0x10]
mov edx, dword [ebp - 0x30]
mov edx, dword [eax + edx*4 + 4]
mov eax, dword [ebp - 0x5c]
cmp edx, eax
jne 0x460e42
jmp 0x460e50
add dword [ebp - 0x30], 1
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x30]
ja 0x460e2f
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x30]
jne 0x460e7e
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
cmp eax, 0x3f
ja 0x460e7e
mov ecx, dword [ebp - 0x5c]
mov eax, dword [ebp + 0x10]
mov edx, dword [ebp - 0x30]
mov dword [eax + edx*4 + 4], ecx
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
lea edx, [eax + 1]
mov eax, dword [ebp + 0x10]
mov dword [eax], edx
mov dword [ebp - 0x34], 0
jmp 0x460e9e
mov eax, dword [ebp - 0x34]
mov edx, dword [ebp + eax*4 - 0x374]
mov eax, dword [ebp - 0x5c]
cmp edx, eax
jne 0x460e9a
jmp 0x460ea9
add dword [ebp - 0x34], 1
mov eax, dword [ebp - 0x378]
cmp eax, dword [ebp - 0x34]
ja 0x460e87
mov eax, dword [ebp - 0x378]
cmp eax, dword [ebp - 0x34]
jne 0x460edb
mov eax, dword [ebp - 0x378]
cmp eax, 0x3f
ja 0x460edb
mov edx, dword [ebp - 0x5c]
mov eax, dword [ebp - 0x34]
mov dword [ebp + eax*4 - 0x374], edx
mov eax, dword [ebp - 0x378]
add eax, 1
mov dword [ebp - 0x378], eax
mov eax, dword [ebp - 0x18]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx eax, byte [ebp + eax - 0x4ac]
movzx edx, al
mov eax, dword [ebp - 0x18]
and eax, 7
mov ecx, eax
sar edx, cl
mov eax, edx
and eax, 1
test eax, eax
je 0x460fc4
or dword [ebp - 0x24], 4
mov dword [ebp - 0x38], 0
jmp 0x460f2f
mov eax, dword [ebp + 0x14]
mov edx, dword [ebp - 0x38]
mov edx, dword [eax + edx*4 + 4]
mov eax, dword [ebp - 0x5c]
cmp edx, eax
jne 0x460f2b
jmp 0x460f39
add dword [ebp - 0x38], 1
mov eax, dword [ebp + 0x14]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x38]
ja 0x460f18
mov eax, dword [ebp + 0x14]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x38]
jne 0x460f67
mov eax, dword [ebp + 0x14]
mov eax, dword [eax]
cmp eax, 0x3f
ja 0x460f67
mov ecx, dword [ebp - 0x5c]
mov eax, dword [ebp + 0x14]
mov edx, dword [ebp - 0x38]
mov dword [eax + edx*4 + 4], ecx
mov eax, dword [ebp + 0x14]
mov eax, dword [eax]
lea edx, [eax + 1]
mov eax, dword [ebp + 0x14]
mov dword [eax], edx
mov dword [ebp - 0x3c], 0
jmp 0x460f87
mov eax, dword [ebp - 0x3c]
mov edx, dword [ebp + eax*4 - 0x478]
mov eax, dword [ebp - 0x5c]
cmp edx, eax
jne 0x460f83
jmp 0x460f92
add dword [ebp - 0x3c], 1
mov eax, dword [ebp - 0x47c]
cmp eax, dword [ebp - 0x3c]
ja 0x460f70
mov eax, dword [ebp - 0x47c]
cmp eax, dword [ebp - 0x3c]
jne 0x460fc4
mov eax, dword [ebp - 0x47c]
cmp eax, 0x3f
ja 0x460fc4
mov edx, dword [ebp - 0x5c]
mov eax, dword [ebp - 0x3c]
mov dword [ebp + eax*4 - 0x478], edx
mov eax, dword [ebp - 0x47c]
add eax, 1
mov dword [ebp - 0x47c], eax
mov edx, dword [0x6ea2b8]
mov eax, dword [ebp - 0x5c]
mov ecx, dword [ebp - 0x24]
mov dword [esp + 8], ecx
mov dword [esp + 4], edx
mov dword [esp], eax
mov eax, dword [sym.imp.WS2_32.dll_WSAEventSelect]
call eax
sub esp, 0xc
add dword [ebp - 0x14], 1
jmp 0x46103f
mov eax, dword [ebp - 0x10]
lea edx, [eax + 1]
mov dword [ebp - 0x10], edx
mov edx, dword [ebp - 0x5c]
mov dword [ebp + eax*4 - 0x170], edx
cmp dword [ebp - 0xc], 0
je 0x46103f
lea eax, [ebp - 0x4ac]
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x49c]
mov dword [esp + 0xc], eax
lea eax, [ebp - 0x48c]
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x18]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x5c]
mov dword [esp], eax
call fcn.00460399
test eax, eax
je 0x46103f
mov dword [ebp - 0xc], 0
add dword [ebp - 0x18], 1
mov eax, dword [ebp - 0x18]
cmp eax, dword [ebp + 8]
jl 0x460c93
mov eax, dword [ebp - 0x10]
mov dword [ebp + eax*4 - 0x170], 0
cmp dword [ebp - 0xc], 0xffffffff
je 0x461072
call sub.msvcrt.dll_clock
mov edx, eax
mov eax, dword [ebp - 0xc]
add eax, edx
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0xc], 0
je 0x46107e
cmp dword [ebp - 0x14], 0
jne 0x46108a
mov dword [ebp - 0x1c], 0
jmp 0x46112a
mov dword [esp + 0x10], 0x6ea2bc
lea eax, [ebp - 0x47c]
mov dword [esp + 0xc], eax
lea eax, [ebp - 0x378]
mov dword [esp + 8], eax
lea eax, [ebp - 0x274]
mov dword [esp + 4], eax
mov dword [esp], 0
mov eax, dword [sym.imp.WS2_32.dll_select]
call eax
sub esp, 0x14
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 0
jne 0x461123
mov dword [esp + 8], 0x104
mov eax, dword [ebp + 0xc]
mov dword [esp + 4], eax
lea eax, [ebp - 0x274]
mov dword [esp], eax
call sub.msvcrt.dll_memcpy
mov dword [esp + 8], 0x104
mov eax, dword [ebp + 0x10]
mov dword [esp + 4], eax
lea eax, [ebp - 0x378]
mov dword [esp], eax
call sub.msvcrt.dll_memcpy
mov dword [esp + 8], 0x104
mov eax, dword [ebp + 0x14]
mov dword [esp + 4], eax
lea eax, [ebp - 0x47c]
mov dword [esp], eax
call sub.msvcrt.dll_memcpy
jmp 0x46112a
mov dword [ebp - 0xc], 0
cmp dword [ebp - 0xc], 0xffffffff
je 0x461152
call sub.msvcrt.dll_clock
mov dword [ebp - 0x60], eax
mov eax, dword [ebp - 0x20]
cmp eax, dword [ebp - 0x60]
jl 0x46114b
mov eax, dword [ebp - 0x20]
sub eax, dword [ebp - 0x60]
mov dword [ebp - 0xc], eax
jmp 0x461152
mov dword [ebp - 0xc], 0
mov dword [esp + 0x10], 0x4ff
mov eax, dword [ebp - 0xc]
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0
lea eax, [ebp - 0x170]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
mov eax, dword [sym.imp.USER32.dll_MsgWaitForMultipleObjects]
call eax
sub esp, 0x14
mov dword [ebp - 0x64], eax
mov eax, dword [ebp - 0x64]
cmp eax, dword [ebp - 0x10]
jne 0x4611f4
jmp 0x4611b6
lea eax, [ebp - 0x4d4]
mov dword [esp], eax
mov eax, dword [sym.imp.USER32.dll_TranslateMessage]
call eax
sub esp, 4
lea eax, [ebp - 0x4d4]
mov dword [esp], eax
mov eax, dword [sym.imp.USER32.dll_DispatchMessageA]
call eax
sub esp, 4
mov dword [esp + 0x10], 1
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0
lea eax, [ebp - 0x4d4]
mov dword [esp], eax
mov eax, dword [sym.imp.USER32.dll_PeekMessageA]
call eax
sub esp, 0x14
mov dword [ebp - 0x68], eax
cmp dword [ebp - 0x68], 0
jne 0x461190
jmp 0x4611fd
nop
cmp dword [ebp - 0x1c], 0
jne 0x461242
jmp 0x461202
jmp 0x461152
cmp dword [ebp - 0x14], 0
je 0x461242
mov dword [esp + 0x10], 0x6ea2bc
lea eax, [ebp - 0x47c]
mov dword [esp + 0xc], eax
lea eax, [ebp - 0x378]
mov dword [esp + 8], eax
lea eax, [ebp - 0x274]
mov dword [esp + 4], eax
mov dword [esp], 0
mov eax, dword [sym.imp.WS2_32.dll_select]
call eax
sub esp, 0x14
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x10], 1
jbe 0x461435
mov dword [ebp - 0x10], 1
mov dword [ebp - 0x18], 0
jmp 0x461371
mov eax, dword [ebp - 0x18]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx eax, byte [ebp + eax - 0x4b4]
movzx edx, al
mov eax, dword [ebp - 0x18]
and eax, 7
mov ecx, eax
sar edx, cl
mov eax, edx
and eax, 1
test eax, eax
jne 0x461290
jmp 0x46136d
mov eax, dword [ebp - 0x18]
mov dword [esp], eax
call fcn.0044e87c
mov dword [ebp - 0x5c], eax
mov eax, dword [ebp - 0x10]
mov eax, dword [ebp + eax*4 - 0x170]
cmp eax, dword [ebp - 0x5c]
jne 0x46136d
add dword [ebp - 0x10], 1
lea eax, [ebp - 0x4ac]
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x49c]
mov dword [esp + 0xc], eax
lea eax, [ebp - 0x48c]
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x18]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x5c]
mov dword [esp], eax
call fcn.00460399
mov eax, dword [ebp - 0x18]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx eax, byte [ebp + eax - 0x484]
movzx edx, al
mov eax, dword [ebp - 0x18]
and eax, 7
mov ecx, eax
sar edx, cl
mov eax, edx
and eax, 1
test eax, eax
jne 0x461369
mov eax, dword [ebp - 0x18]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx eax, byte [ebp + eax - 0x494]
movzx edx, al
mov eax, dword [ebp - 0x18]
and eax, 7
mov ecx, eax
sar edx, cl
mov eax, edx
and eax, 1
test eax, eax
jne 0x461369
mov eax, dword [ebp - 0x18]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx eax, byte [ebp + eax - 0x4a4]
movzx edx, al
mov eax, dword [ebp - 0x18]
and eax, 7
mov ecx, eax
sar edx, cl
mov eax, edx
and eax, 1
test eax, eax
je 0x46136d
add dword [ebp - 0x1c], 1
add dword [ebp - 0x18], 1
mov eax, dword [ebp - 0x18]
cmp eax, dword [ebp + 8]
jl 0x46125f
cmp dword [ebp - 0x1c], 0
jne 0x46140e
cmp dword [ebp - 0xc], 0xffffffff
je 0x461399
cmp dword [ebp - 0xc], 0
je 0x46140e
cmp dword [ebp - 0x10], 1
jbe 0x46140e
mov dword [esp + 8], 0x104
mov eax, dword [ebp + 0xc]
mov dword [esp + 4], eax
lea eax, [ebp - 0x274]
mov dword [esp], eax
call sub.msvcrt.dll_memcpy
mov dword [esp + 8], 0x104
mov eax, dword [ebp + 0x10]
mov dword [esp + 4], eax
lea eax, [ebp - 0x378]
mov dword [esp], eax
call sub.msvcrt.dll_memcpy
mov dword [esp + 8], 0x104
mov eax, dword [ebp + 0x14]
mov dword [esp + 4], eax
lea eax, [ebp - 0x47c]
mov dword [esp], eax
call sub.msvcrt.dll_memcpy
mov dword [esp + 4], 1
mov dword [esp], 1
mov eax, dword [sym.imp.KERNEL32.dll_SleepEx]
call eax
sub esp, 8
jmp 0x461072
cmp dword [ebp + 0x18], 0
je 0x461435
cmp dword [ebp - 0xc], 0
jne 0x461435
cmp dword [ebp - 0x1c], 0
jne 0x461435
mov eax, dword [ebp + 0x18]
mov dword [eax + 4], 0
mov eax, dword [ebp + 0x18]
mov edx, dword [eax + 4]
mov eax, dword [ebp + 0x18]
mov dword [eax], edx
mov eax, dword [ebp + 0xc]
mov dword [eax], 0
mov eax, dword [ebp + 0x10]
mov dword [eax], 0
mov eax, dword [ebp + 0x14]
mov dword [eax], 0
mov dword [ebp - 0x10], 1
mov dword [ebp - 0x18], 0
jmp 0x4617cf
mov eax, dword [ebp - 0x18]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx eax, byte [ebp + eax - 0x4b4]
movzx edx, al
mov eax, dword [ebp - 0x18]
and eax, 7
mov ecx, eax
sar edx, cl
mov eax, edx
and eax, 1
test eax, eax
jne 0x461494
jmp 0x4617cb
mov eax, dword [ebp - 0x18]
mov dword [esp], eax
call fcn.0044e87c
mov dword [ebp - 0x5c], eax
mov eax, dword [ebp - 0x10]
mov eax, dword [ebp + eax*4 - 0x170]
cmp eax, dword [ebp - 0x5c]
je 0x46163b
mov eax, dword [ebp - 0x5c]
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov dword [esp], eax
mov eax, dword [sym.imp.WS2_32.dll_WSAEventSelect]
call eax
sub esp, 0xc
mov eax, dword [ebp - 0x5c]
lea edx, [ebp - 0x274]
mov dword [esp + 4], edx
mov dword [esp], eax
call sub.WS2_32.dll___WSAFDIsSet
sub esp, 8
test eax, eax
je 0x461549
mov dword [ebp - 0x40], 0
jmp 0x461511
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp - 0x40]
mov edx, dword [eax + edx*4 + 4]
mov eax, dword [ebp - 0x18]
cmp edx, eax
jne 0x46150d
jmp 0x46151b
add dword [ebp - 0x40], 1
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x40]
ja 0x4614fa
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x40]
jne 0x461549
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
cmp eax, 0x3f
ja 0x461549
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp - 0x40]
mov dword [eax + edx*4 + 4], ecx
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
lea edx, [eax + 1]
mov eax, dword [ebp + 0xc]
mov dword [eax], edx
mov eax, dword [ebp - 0x5c]
lea edx, [ebp - 0x378]
mov dword [esp + 4], edx
mov dword [esp], eax
call sub.WS2_32.dll___WSAFDIsSet
sub esp, 8
test eax, eax
je 0x4615bd
mov dword [ebp - 0x44], 0
jmp 0x461585
mov eax, dword [ebp + 0x10]
mov edx, dword [ebp - 0x44]
mov edx, dword [eax + edx*4 + 4]
mov eax, dword [ebp - 0x18]
cmp edx, eax
jne 0x461581
jmp 0x46158f
add dword [ebp - 0x44], 1
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x44]
ja 0x46156e
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x44]
jne 0x4615bd
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
cmp eax, 0x3f
ja 0x4615bd
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp + 0x10]
mov edx, dword [ebp - 0x44]
mov dword [eax + edx*4 + 4], ecx
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
lea edx, [eax + 1]
mov eax, dword [ebp + 0x10]
mov dword [eax], edx
mov eax, dword [ebp - 0x5c]
lea edx, [ebp - 0x47c]
mov dword [esp + 4], edx
mov dword [esp], eax
call sub.WS2_32.dll___WSAFDIsSet
sub esp, 8
test eax, eax
je 0x461636
mov dword [ebp - 0x48], 0
jmp 0x4615f9
mov eax, dword [ebp + 0x14]
mov edx, dword [ebp - 0x48]
mov edx, dword [eax + edx*4 + 4]
mov eax, dword [ebp - 0x18]
cmp edx, eax
jne 0x4615f5
jmp 0x461603
add dword [ebp - 0x48], 1
mov eax, dword [ebp + 0x14]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x48]
ja 0x4615e2
mov eax, dword [ebp + 0x14]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x48]
jne 0x461636
mov eax, dword [ebp + 0x14]
mov eax, dword [eax]
cmp eax, 0x3f
ja 0x461636
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp + 0x14]
mov edx, dword [ebp - 0x48]
mov dword [eax + edx*4 + 4], ecx
mov eax, dword [ebp + 0x14]
mov eax, dword [eax]
lea edx, [eax + 1]
mov eax, dword [ebp + 0x14]
mov dword [eax], edx
jmp 0x4617cb
jmp 0x4617cb
add dword [ebp - 0x10], 1
mov eax, dword [ebp - 0x18]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx eax, byte [ebp + eax - 0x484]
movzx edx, al
mov eax, dword [ebp - 0x18]
and eax, 7
mov ecx, eax
sar edx, cl
mov eax, edx
and eax, 1
test eax, eax
je 0x4616c3
mov dword [ebp - 0x4c], 0
jmp 0x46168b
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp - 0x4c]
mov edx, dword [eax + edx*4 + 4]
mov eax, dword [ebp - 0x18]
cmp edx, eax
jne 0x461687
jmp 0x461695
add dword [ebp - 0x4c], 1
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x4c]
ja 0x461674
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x4c]
jne 0x4616c3
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
cmp eax, 0x3f
ja 0x4616c3
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp - 0x4c]
mov dword [eax + edx*4 + 4], ecx
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
lea edx, [eax + 1]
mov eax, dword [ebp + 0xc]
mov dword [eax], edx
mov eax, dword [ebp - 0x18]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx eax, byte [ebp + eax - 0x494]
movzx edx, al
mov eax, dword [ebp - 0x18]
and eax, 7
mov ecx, eax
sar edx, cl
mov eax, edx
and eax, 1
test eax, eax
je 0x461747
mov dword [ebp - 0x50], 0
jmp 0x46170f
mov eax, dword [ebp + 0x10]
mov edx, dword [ebp - 0x50]
mov edx, dword [eax + edx*4 + 4]
mov eax, dword [ebp - 0x18]
cmp edx, eax
jne 0x46170b
jmp 0x461719
add dword [ebp - 0x50], 1
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x50]
ja 0x4616f8
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x50]
jne 0x461747
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
cmp eax, 0x3f
ja 0x461747
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp + 0x10]
mov edx, dword [ebp - 0x50]
mov dword [eax + edx*4 + 4], ecx
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
lea edx, [eax + 1]
mov eax, dword [ebp + 0x10]
mov dword [eax], edx
mov eax, dword [ebp - 0x18]
lea edx, [eax + 7]
test eax, eax
cmovs eax, edx
sar eax, 3
movzx eax, byte [ebp + eax - 0x4a4]
movzx edx, al
mov eax, dword [ebp - 0x18]
and eax, 7
mov ecx, eax
sar edx, cl
mov eax, edx
and eax, 1
test eax, eax
je 0x4617cb
mov dword [ebp - 0x54], 0
jmp 0x461793
mov eax, dword [ebp + 0x14]
mov edx, dword [ebp - 0x54]
mov edx, dword [eax + edx*4 + 4]
mov eax, dword [ebp - 0x18]
cmp edx, eax
jne 0x46178f
jmp 0x46179d
add dword [ebp - 0x54], 1
mov eax, dword [ebp + 0x14]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x54]
ja 0x46177c
mov eax, dword [ebp + 0x14]
mov eax, dword [eax]
cmp eax, dword [ebp - 0x54]
jne 0x4617cb
mov eax, dword [ebp + 0x14]
mov eax, dword [eax]
cmp eax, 0x3f
ja 0x4617cb
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp + 0x14]
mov edx, dword [ebp - 0x54]
mov dword [eax + edx*4 + 4], ecx
mov eax, dword [ebp + 0x14]
mov eax, dword [eax]
lea edx, [eax + 1]
mov eax, dword [ebp + 0x14]
mov dword [eax], edx
add dword [ebp - 0x18], 1
mov eax, dword [ebp - 0x18]
cmp eax, dword [ebp + 8]
jl 0x461463
mov eax, dword [ebp - 0x1c]
lea esp, [ebp - 8]
pop ebx
pop esi
pop ebp
ret