Function at 0x10008060
Capabilities:
Get socket status

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x35c
push ebx
push esi
push edi
mov edi, dword [0x1003e900]
xor ebx, ebx
mov dword [ebp - 4], edi
mov dword [ebp - 0x20], ebx
mov dword [ebp - 0x1c], 0x64
cmp edi, ebx
je 0x1000829f
jmp 0x1000808e
mov edi, dword [ebp - 4]
cmp dword [edi + 4], 2
jne 0x10008291
push dword [edi]
call sub.WS2_32.dll_htonl
mov dword [ebp - 8], eax
mov dword [ebp - 0x358], ebx
mov dword [ebp - 0x250], ebx
mov dword [ebp - 0x148], ebx
mov eax, dword [edi + 0x1c]
mov dword [ebp - 0x354], eax
xor esi, esi
inc esi
mov dword [ebp - 0x358], esi
mov eax, dword [edi + 0x1c]
mov dword [ebp - 0x24c], eax
mov dword [ebp - 0x250], esi
mov eax, dword [edi + 0x1c]
mov dword [ebp - 0x144], eax
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x250]
push eax
lea eax, [ebp - 0x358]
push eax
lea eax, [ebp - 0x148]
push eax
push ebx
mov dword [ebp - 0x148], esi
call dword [sym.imp.WS2_32.dll_select]
mov eax, dword [edi + 0x10]
cmp eax, 2
jne 0x1000819a
lea eax, [ebp - 0x148]
push eax
push dword [edi + 0x1c]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x10008291
push ebx
push ebx
push dword [edi + 0x1c]
call dword [sym.imp.WS2_32.dll_accept]
mov ecx, eax
call fcn.1000804a
push esi
push ebx
push ebx
push 0x2bf20
push ecx
mov ebx, eax
mov dword [ebp - 8], eax
call fcn.10007c69
add esp, 0x14
lea eax, [ebp - 0x18]
push 0x80
push eax
call fcn.1000176d
push ebx
lea esi, [ebp - 0x18]
call fcn.100017a0
add esp, 0xc
push dword [edi + 0x14]
call fcn.100017a0
pop ecx
push 0x17
mov eax, esi
call fcn.10007b6a
push eax
mov eax, esi
call fcn.10001846
push eax
call fcn.10001355
add esp, 0xc
mov eax, esi
call fcn.1000182d
xor ebx, ebx
jmp 0x10008291
cmp eax, 3
jne 0x100081f5
lea eax, [ebp - 0x148]
push eax
push dword [edi + 0x1c]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x10008291
push ebx
push ebx
push dword [edi + 0x1c]
call dword [sym.imp.WS2_32.dll_accept]
mov edi, eax
lea esi, [ebp - 0x40]
call fcn.100077c7
mov esi, eax
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x14]
sub esp, 0x20
push 8
pop ecx
or eax, 0x110000
mov edi, esp
push eax
rep movsd dword es:[edi], dword [esi]
call fcn.10007029
mov edi, dword [ebp - 4]
add esp, 0x24
xor ebx, ebx
jmp 0x10008291
lea eax, [ebp - 0x250]
push eax
push dword [edi + 0x1c]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
jne 0x1000827e
lea eax, [ebp - 0x358]
push eax
push dword [edi + 0x1c]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x10008222
mov dword [edi + 4], esi
push 6
jmp 0x10008283
lea eax, [ebp - 0x148]
push eax
push dword [edi + 0x1c]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x10008270
mov eax, dword [edi + 0x1c]
push ebx
push ebx
push eax
mov dword [ebp - 4], eax
call dword [sym.imp.WS2_32.dll_accept]
mov dword [edi + 0x1c], eax
cmp eax, 0xffffffff
lea eax, [ebp - 8]
jne 0x10008256
mov dword [edi + 4], ebx
push 4
jmp 0x1000825b
mov dword [edi + 4], esi
push 6
push 4
push eax
call fcn.10001355
add esp, 0xc
push dword [ebp - 4]
call sub.WS2_32.dll_closesocket
jmp 0x10008291
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [edi + 0x18]
cmp eax, dword [edi + 8]
jbe 0x10008291
push 4
mov dword [edi + 4], ebx
lea eax, [ebp - 8]
push 4
push eax
call fcn.10001355
add esp, 0xc
mov eax, dword [edi + 0x20]
mov dword [ebp - 4], eax
cmp eax, ebx
jne 0x1000808b
pop edi
pop esi
pop ebx
leave
ret