Function at 0x485be0
Capabilities:
Get socket status

Disassembly:
push ebp
push edi
push esi
push ebx
push eax
mov eax, 0x6068
call fcn.00497490
sub esp, eax
mov eax, dword [esp + eax]
mov dword [esp + 0x4c], 0
mov dword [esp + 0x50], 0
movzx edi, byte [eax + 0xc4]
mov ebx, eax
mov eax, edi
test al, al
jne 0x485e40
mov eax, dword [ebx + 0xdc]
mov esi, edx
mov dword [esp + 0x54], 0
mov dword [esp + 0x2058], 0
mov dword [esp + 0x405c], 0
mov dword [esp + 0x3c], 0xffffffff
test ah, 0x20
jne 0x485eb0
test al, 4
jne 0x485e60
movzx edi, byte [ebx + 0xc4]
mov eax, edi
test al, al
je 0x485ed0
mov dword [esp + 4], str.Could_not_obtain_daemon_fdsets
mov dword [esp], ebx
mov edi, 1
call fcn.00488450
mov dword [esp + 0x2c], 1
mov eax, dword [ebx + 0xbc]
cmp eax, 0xffffffff
je 0x485cb7
lea edx, [esp + 0x3c]
lea ebp, [esp + 0x54]
mov dword [esp + 0xc], 0x800
mov dword [esp], eax
mov dword [esp + 8], edx
mov dword [esp + 4], ebp
call fcn.00489fb0
test eax, eax
je 0x485f10
xor esi, 1
mov edx, dword [ebx + 0xb4]
mov ecx, esi
and ecx, 1
or ecx, edi
cmp edx, 0xffffffff
je 0x485d12
cmp dword [ebx + 0xbc], 0xffffffff
je 0x485d12
mov eax, dword [ebx + 0xd0]
cmp dword [ebx + 0xcc], eax
je 0x485cec
cmp byte [ebx + 0xc6], 0
je 0x485d12
mov esi, dword [esp + 0x54]
test esi, esi
je 0x485d12
xor eax, eax
cmp dword [esp + 0x58], edx
jne 0x485d0b
jmp 0x486033
cmp dword [esp + eax*4 + 0x58], edx
je 0x486033
add eax, 1
cmp eax, esi
jne 0x485d01
test cl, cl
je 0x485fc0
lea esi, [esp + 0x4c]
mov dword [esp + 0x50], 0
mov dword [esp + 0x4c], 0
mov ecx, dword [esp + 0x54]
test ecx, ecx
jne 0x485dc4
mov edx, dword [esp + 0x2058]
test edx, edx
jne 0x485dc4
mov eax, dword [esp + 0x405c]
test eax, eax
jne 0x485dc4
test esi, esi
je 0x485d7c
imul ecx, dword [esi], 0x3e8
mov esi, dword [esi + 4]
mov edx, 0x10624dd3
mov eax, esi
sar esi, 0x1f
imul edx
sar edx, 6
sub edx, esi
add edx, ecx
mov dword [esp], edx
call dword [sym.imp.KERNEL32.dll_Sleep]
sub esp, 4
movzx eax, byte [ebx + 0xc4]
test al, al
jne 0x485e40
lea ecx, [esp + 0x2058]
lea ebp, [esp + 0x54]
lea edx, [esp + 0x405c]
mov dword [esp], edx
mov eax, ebx
mov edx, ebp
call fcn.004837d0
cmp eax, 1
jne 0x485e40
mov eax, dword [esp + 0x2c]
add esp, 0x606c
pop ebx
pop esi
xor eax, 1
pop edi
pop ebp
ret
lea ecx, [esp + 0x2058]
lea edx, [esp + 0x405c]
lea ebp, [esp + 0x54]
mov dword [esp + 0x10], esi
mov dword [esp], 0
mov dword [esp + 8], ecx
mov dword [esp + 0x24], ecx
mov dword [esp + 0xc], edx
mov dword [esp + 0x28], edx
mov dword [esp + 4], ebp
call dword [sym.imp.WS2_32.dll_select]
movzx esi, byte [ebx + 0xc4]
sub esp, 0x14
mov ecx, esi
test cl, cl
jne 0x485e40
test eax, eax
mov ecx, dword [esp + 0x24]
mov edx, dword [esp + 0x28]
jns 0x485d9d
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2714
je 0x485db2
mov dword [esp], eax
call fcn.00489370
mov dword [esp + 4], str.select_failed:__s_n
mov dword [esp + 8], eax
mov dword [esp], ebx
call fcn.00488450
xor eax, eax
add esp, 0x606c
pop ebx
pop esi
pop edi
pop ebp
ret
test byte [ebx + 0xdc], 4
je 0x486090
lea esi, [esi]
mov eax, dword [ebx + 0xb4]
cmp eax, 0xffffffff
je 0x485ea0
movzx edx, byte [ebx + 0xc5]
test dl, dl
jne 0x485ea0
lea edx, [esp + 0x3c]
lea ebp, [esp + 0x54]
mov dword [esp + 0xc], 0x800
mov dword [esp], eax
mov dword [esp + 8], edx
mov dword [esp + 4], ebp
call fcn.00489fb0
test eax, eax
je 0x4860a0
nop
mov dword [esp + 0x2c], 0
jmp 0x485c84
mov eax, ebx
call fcn.004821d0
cmp eax, 1
je 0x485e50
mov eax, dword [ebx + 0xdc]
jmp 0x485c4e
lea eax, [esp + 0x3c]
lea edx, [esp + 0x405c]
lea ebp, [esp + 0x54]
lea ecx, [esp + 0x2058]
mov dword [esp + 8], 0x800
mov dword [esp + 4], eax
mov dword [esp], edx
mov eax, ebx
mov edx, ebp
call fcn.00482490
test eax, eax
je 0x485c67
jmp 0x485ea0
mov edx, dword [ebx + 0xb4]
cmp edx, 0xffffffff
je 0x4860c0
movzx eax, byte [ebx + 0xc5]
test al, al
jne 0x486080
mov ecx, dword [esp + 0x54]
test ecx, ecx
je 0x485f54
xor eax, eax
cmp dword [esp + 0x58], edx
jne 0x485f4d
jmp 0x4860d0
cmp dword [ebp + eax*4 + 4], edx
je 0x4860d0
add eax, 1
cmp ecx, eax
jne 0x485f43
lea eax, [esp + 0x3c]
mov dword [esp + 0xc], 0x800
mov dword [esp + 4], ebp
mov dword [esp + 8], eax
mov eax, dword [ebx + 0xbc]
mov dword [esp], eax
call fcn.00489fb0
test eax, eax
jne 0x485cb7
mov dword [esp + 4], str.Could_not_add_control_inter_thread_communication_channel_FD_to_fdset
mov dword [esp], ebx
call fcn.00488450
mov edx, dword [ebx + 0xb4]
cmp edx, 0xffffffff
je 0x486139
cmp dword [ebx + 0xbc], 0xffffffff
mov ecx, 1
mov dword [esp + 0x2c], 1
jne 0x485cd5
jmp 0x485d1a
xor esi, esi
test byte [ebx + 0xdc], 4
jne 0x485d2e
lea eax, [esp + 0x40]
mov dword [esp], ebx
mov dword [esp + 4], eax
call sym.xmrig.exe_MHD_get_timeout
cmp eax, 1
jne 0x485d2e
mov esi, dword [esp + 0x44]
mov edi, dword [esp + 0x40]
mov dword [esp + 8], 0x3e8
mov dword [esp + 0xc], 0
mov dword [esp], edi
mov dword [esp + 4], esi
call fcn.004978b0
imul eax, eax, 0x3e8
cmp esi, 0x1f3
mov dword [esp + 0x50], eax
jbe 0x486110
mov dword [esp + 0x4c], 0x7fffffff
lea esi, [esp + 0x4c]
jmp 0x485d2e
lea edi, [esi - 1]
cmp edi, eax
jbe 0x48606f
sub esi, eax
lea edx, [eax*4]
lea ebp, [esp + 0x54]
lea eax, [esi*4 - 4]
mov byte [esp + 0x24], cl
mov dword [esp + 8], eax
lea eax, [ebp + edx + 8]
mov dword [esp + 4], eax
lea eax, [ebp + edx + 4]
mov dword [esp], eax
call sub.msvcrt.dll_memmove
movzx ecx, byte [esp + 0x24]
mov dword [esp + 0x54], edi
jmp 0x485d12
xor esi, 1
mov ecx, esi
and ecx, 1
or ecx, edi
jmp 0x485ccc
xor esi, esi
jmp 0x485c56
mov dword [esp + 4], str.Could_not_add_listen_socket_to_fdset
mov dword [esp], ebx
mov dword [esp + 0x24], eax
call fcn.00488450
mov eax, dword [esp + 0x24]
jmp 0x485e42
xor esi, 1
mov ecx, esi
and ecx, 1
or ecx, edi
jmp 0x485d12
lea edx, [ecx - 1]
cmp eax, edx
mov dword [esp + 0x24], edx
jae 0x486103
sub ecx, eax
lea edx, [eax*4]
lea eax, [ecx*4 - 4]
mov dword [esp + 8], eax
lea eax, [ebp + edx + 8]
mov dword [esp + 4], eax
lea eax, [ebp + edx + 4]
mov dword [esp], eax
call sub.msvcrt.dll_memmove
mov eax, dword [esp + 0x24]
mov dword [esp + 0x54], eax
jmp 0x485f54
mov dword [esp + 4], esi
mov dword [esp + 8], 0x3e8
lea esi, [esp + 0x4c]
mov dword [esp + 0xc], 0
mov dword [esp], edi
call fcn.004977a0
mov dword [esp + 0x4c], eax
jmp 0x485d2e
mov dword [esp + 0x2c], 1
jmp 0x485d1a