Function at 0x46ceb1
Capabilities:
Get socket status

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xfec
mov eax, dword [ebp + 0x14]
push ebx
push esi
xor esi, esi
cmp eax, esi
push edi
je 0x46cec9
and byte [eax], 0
cmp dword [ebp + 0x18], esi
jne 0x46ced6
call fcn.0046cb1c
mov dword [ebp + 0x18], eax
mov eax, dword [ebp + 0x1c]
cmp eax, esi
je 0x46cee0
mov esi, dword [eax + 2]
push dword [ebp + 0xc]
mov edi, dword [ebp + 0x18]
push esi
push edi
call fcn.004728ed
push dword [ebp + 0xc]
inc edi
mov ebx, eax
push esi
push edi
mov dword [ebp - 0xc], ebx
call fcn.004728ed
add esp, 0x18
cmp ebx, 0xffffffff
mov dword [ebp - 0x18], eax
je 0x46d439
cmp eax, 0xffffffff
je 0x46d439
mov esi, dword [ebp + 8]
lea edi, [ebp - 0x38]
movsd dword es:[edi], dword [esi]
and byte [ebp - 8], 0
and byte [ebp - 0x2c], 0
and byte [ebp - 0x14], 0
and byte [ebp - 0x24], 0
and byte [ebp - 1], 0
push 6
movsw word es:[edi], word [esi]
xor esi, esi
lea eax, [ebp - 0x20]
push esi
push eax
mov byte [ebp - 0x30], 1
call fcn.0044e2f0
mov word [ebp - 0x258], si
mov word [ebp - 0x154], si
mov dword [ebp - 0x10], esi
add esp, 0xc
mov esi, 0x493730
jmp 0x46cf62
mov ebx, dword [ebp - 0xc]
xor edi, edi
mov dword [ebp - 0x14c], ebx
push 1
inc ebx
pop edx
test ebx, ebx
mov dword [ebp - 0x150], edx
jbe 0x46cf7a
mov edi, ebx
xor ebx, ebx
lea eax, [ebp - 0x14c]
mov ecx, dword [ebp - 0x18]
cmp dword [eax], ecx
je 0x46cf91
inc ebx
add eax, 4
cmp ebx, edx
jb 0x46cf82
cmp ebx, edx
jne 0x46cfa5
mov dword [ebp - 0x148], ecx
mov dword [ebp - 0x150], 2
lea eax, [ecx + 1]
cmp eax, edi
jbe 0x46cfae
mov edi, eax
xor eax, eax
mov dword [ebp - 0x40], 0x493e0
cmp dword [ebp - 0x10], eax
mov dword [ebp - 0x44], eax
jne 0x46cfc2
mov dword [ebp - 0x40], eax
lea ecx, [ebp - 0x44]
push ecx
push eax
push eax
lea eax, [ebp - 0x150]
push eax
push edi
call dword [sym.imp.WS2_32.dll_select]
mov edi, eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp edi, 0xffffffff
mov ebx, eax
je 0x46d2a6
xor ebx, ebx
cmp edi, ebx
jne 0x46d0f1
inc dword [ebp - 0x10]
cmp byte [ebp - 8], bl
jne 0x46d01c
push dword [ebp + 0xc]
lea eax, [ebp - 0x254]
push 1
push eax
lea eax, [ebp - 0x358]
push eax
push dword [ebp + 8]
push dword [ebp - 0xc]
call fcn.0046cd7e
add esp, 0x18
cmp byte [ebp - 0x2c], 0
jne 0x46d055
cmp byte [ebp - 8], 0
je 0x46d055
cmp dword [ebp - 0x36], ebx
je 0x46d055
cmp word [ebp - 0x38], bx
je 0x46d055
push dword [ebp + 0xc]
lea eax, [ebp - 0x254]
push 0xa
push eax
lea eax, [ebp - 0x358]
push eax
lea eax, [ebp - 0x38]
push eax
push dword [ebp - 0xc]
call fcn.0046cd7e
add esp, 0x18
cmp byte [ebp - 0x14], 0
jne 0x46d07c
push dword [ebp + 0xc]
lea eax, [ebp - 0x254]
push 2
push eax
lea eax, [ebp - 0x358]
push eax
push dword [ebp + 8]
push dword [ebp - 0x18]
call fcn.0046cd7e
add esp, 0x18
cmp byte [ebp - 0x24], 0
jne 0x46d0a3
push dword [ebp + 0xc]
lea eax, [ebp - 0x254]
push 3
push eax
lea eax, [ebp - 0x358]
push eax
push dword [ebp + 8]
push dword [ebp - 0x18]
call fcn.0046cd7e
add esp, 0x18
cmp byte [ebp - 8], 0
je 0x46d279
cmp byte [ebp - 1], 0
jne 0x46d279
cmp dword [ebp - 0x1e], ebx
je 0x46d279
cmp word [ebp - 0x20], bx
je 0x46d279
push dword [ebp + 0xc]
lea eax, [ebp - 0x254]
push 0xb
push eax
lea eax, [ebp - 0x358]
push eax
lea eax, [ebp - 0x20]
push eax
push dword [ebp - 0xc]
call fcn.0046cd7e
add esp, 0x18
jmp 0x46d279
mov dword [ebp - 0x28], ebx
cmp dword [ebp - 0x28], ebx
mov edi, dword [ebp - 0xc]
je 0x46d0ff
mov edi, dword [ebp - 0x18]
cmp edi, 0xffffffff
je 0x46d26c
lea eax, [ebp - 0x150]
push eax
push edi
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x46d26c
push dword [ebp + 0xc]
lea eax, [ebp - 0x4c]
mov dword [ebp - 0x3c], 0x800
push eax
lea eax, [ebp - 0x4a]
push eax
lea eax, [ebp - 0x3c]
push eax
lea eax, [ebp - 0xfec]
push eax
push edi
call fcn.00472af6
push 0x491
lea eax, [ebp - 0x7ec]
push ebx
push eax
call fcn.0044e2f0
push dword [ebp + 0xc]
lea eax, [ebp - 0x7ec]
push eax
lea eax, [ebp - 0xfec]
push dword [ebp - 0x3c]
push eax
call fcn.0046b999
add esp, 0x34
cmp byte [ebp + 0xc], 0
je 0x46d1bc
movzx eax, byte [ebp - 0x7e8]
push eax
push str.__id
push dword [ebp - 0x7ec]
push str.Received_message_of_type
push esi
call fcn.0046626f
pop ecx
pop ecx
mov ecx, eax
call fcn.0046d577
push eax
call fcn.0046626f
pop ecx
pop ecx
mov ecx, eax
call fcn.00465ed2
mov edi, eax
push 0xa
mov ecx, edi
call fcn.0046610c
mov ecx, edi
call fcn.004661d3
movzx eax, byte [ebp - 0x7e8]
dec eax
je 0x46d223
dec eax
je 0x46d21d
dec eax
je 0x46d217
sub eax, 7
je 0x46d1eb
dec eax
jne 0x46d26c
mov eax, dword [ebp + 0x14]
cmp eax, ebx
je 0x46d1e2
mov byte [eax], 1
mov byte [ebp - 1], 1
jmp 0x46d26c
cmp byte [ebp - 0x2c], 0
jne 0x46d211
mov eax, dword [ebp - 0x7d3]
and byte [ebp - 0x30], 0
cmp eax, dword [ebp - 0x1e]
jne 0x46d211
mov ax, word [ebp - 0x7d5]
cmp ax, word [ebp - 0x20]
jne 0x46d211
mov byte [ebp - 0x30], 1
mov byte [ebp - 0x2c], 1
jmp 0x46d26c
mov byte [ebp - 0x24], 1
jmp 0x46d26c
mov byte [ebp - 0x14], 1
jmp 0x46d26c
cmp byte [ebp - 8], 0
jne 0x46d268
mov ecx, dword [ebp + 0x10]
mov edi, dword [ebp - 0x7d3]
mov ax, word [ebp - 0x7d5]
cmp ecx, ebx
mov dword [ebp - 0x1e], edi
mov word [ebp - 0x20], ax
je 0x46d24f
movzx edx, ax
cmp edx, dword [ebp + 0x18]
sete dl
mov byte [ecx], dl
mov ecx, dword [ebp - 0x7b3]
mov dword [ebp - 0x36], ecx
mov ecx, dword [ebp + 0x1c]
cmp ecx, ebx
je 0x46d265
mov word [ecx], ax
mov dword [ecx + 2], edi
mov dword [ebp - 0x10], ebx
mov byte [ebp - 8], 1
inc dword [ebp - 0x28]
cmp dword [ebp - 0x28], 2
jl 0x46d0f4
cmp dword [ebp - 0x10], 7
jl 0x46cf5f
push 0
push dword [ebp - 0x1e]
push 0
call fcn.004728ed
mov edi, dword [sym.imp.WS2_32.dll_closesocket]
add esp, 0xc
cmp eax, 0xffffffff
je 0x46d2e7
push eax
call edi
and byte [ebp + 8], 0
jmp 0x46d2eb
push str._in_select
push ebx
call fcn.0044e930
pop ecx
push eax
push 0x490714
push ebx
push 0x490bb0
push 0x4938e8
call fcn.0046626f
pop ecx
pop ecx
mov ecx, eax
call fcn.00465ed2
push eax
call fcn.0046626f
pop ecx
pop ecx
push eax
call fcn.0046626f
pop ecx
pop ecx
push eax
jmp 0x46d443
mov byte [ebp + 8], 1
cmp byte [ebp + 0xc], 0
je 0x46d3f1
push dword [ebp - 8]
push str.test_I_
push esi
call fcn.0046626f
pop ecx
pop ecx
mov ecx, eax
call fcn.0046d464
mov ebx, eax
push 0xa
mov ecx, ebx
call fcn.0046610c
mov ecx, ebx
call fcn.004661d3
push dword [ebp - 0x14]
push str.test_II_
push esi
call fcn.0046626f
pop ecx
pop ecx
mov ecx, eax
call fcn.0046d464
push 0xa
mov ecx, eax
pop ebx
mov dword [ebp + 0xc], ecx
push ebx
call fcn.0046610c
mov ecx, dword [ebp + 0xc]
call fcn.004661d3
push dword [ebp - 0x24]
push str.test_III_
push esi
call fcn.0046626f
pop ecx
pop ecx
mov ecx, eax
call fcn.0046d464
mov ecx, eax
push ebx
mov dword [ebp + 0xc], ecx
call fcn.0046610c
mov ecx, dword [ebp + 0xc]
call fcn.004661d3
push dword [ebp - 0x2c]
push str.test_I_2__
push esi
call fcn.0046626f
pop ecx
pop ecx
mov ecx, eax
call fcn.0046d464
mov ecx, eax
push ebx
mov dword [ebp + 0xc], ecx
call fcn.0046610c
mov ecx, dword [ebp + 0xc]
call fcn.004661d3
push dword [ebp + 8]
push str.is_nat__
push esi
call fcn.0046626f
pop ecx
pop ecx
mov ecx, eax
call fcn.0046d464
mov ecx, eax
push ebx
mov dword [ebp + 0xc], ecx
call fcn.0046610c
mov ecx, dword [ebp + 0xc]
call fcn.004661d3
push dword [ebp - 0x30]
push str.mapped_IP_same_
push esi
call fcn.0046626f
pop ecx
pop ecx
mov ecx, eax
call fcn.0046d464
mov esi, eax
push ebx
mov ecx, esi
call fcn.0046610c
mov ecx, esi
call fcn.004661d3
push dword [ebp - 0xc]
call edi
push dword [ebp - 0x18]
call edi
cmp byte [ebp - 8], 0
je 0x46d435
cmp byte [ebp + 8], 0
je 0x46d427
cmp byte [ebp - 0x14], 0
je 0x46d411
push 2
jmp 0x46d45e
cmp byte [ebp - 0x30], 0
je 0x46d423
mov al, byte [ebp - 0x24]
neg al
sbb eax, eax
add eax, 4
jmp 0x46d45f
push 5
jmp 0x46d45e
mov al, byte [ebp - 0x14]
neg al
sbb eax, eax
and al, 0xfb
add eax, 6
jmp 0x46d45f
push 7
jmp 0x46d45e
push str.Some_problem_opening_port_interface_to_send_on
push 0x4938e8
call fcn.0046626f
pop ecx
mov esi, eax
pop ecx
push 0xa
mov ecx, esi
call fcn.0046610c
mov ecx, esi
call fcn.004661d3
push 8
pop eax
pop edi
pop esi
pop ebx
leave
ret