Function at 0x478d00
Capabilities:
Get socket status

Disassembly:
push r14
push r13
mov eax, 0xc090
push r12
push rbp
push rdi
push rsi
push rbx
call fcn.0048ac50
sub rsp, rax
movzx ebp, byte [rcx + 0x178]
mov rbx, rcx
mov esi, edx
mov qword [rsp + 0x58], 0
test bpl, bpl
jne 0x478f50
mov eax, dword [rcx + 0x194]
mov dword [rsp + 0x60], 0
mov dword [rsp + 0x4070], 0
mov dword [rsp + 0x8080], 0
mov qword [rsp + 0x48], 0xffffffffffffffff
test ah, 0x20
jne 0x478fc0
test al, 4
jne 0x478f71
movzx ebp, byte [rbx + 0x178]
test bpl, bpl
je 0x478fd5
lea rdx, str.Could_not_obtain_daemon_fdsets
mov rcx, rbx
mov ebp, 1
mov edi, 1
call fcn.0047b4a0
mov rcx, qword [rbx + 0x168]
cmp rcx, 0xffffffffffffffff
je 0x478dcc
lea r13, [rsp + 0x48]
lea r12, [rsp + 0x60]
mov r9d, 0x800
mov r8, r13
mov rdx, r12
call fcn.0047cd70
test eax, eax
je 0x479020
mov rcx, qword [rbx + 0x158]
xor esi, 1
and esi, 1
or esi, ebp
cmp rcx, 0xffffffffffffffff
je 0x478e45
cmp qword [rbx + 0x168], 0xffffffffffffffff
je 0x478e45
mov eax, dword [rbx + 0x184]
cmp dword [rbx + 0x180], eax
je 0x478e02
cmp byte [rbx + 0x17a], 0
je 0x478e45
mov r10d, dword [rsp + 0x60]
test r10d, r10d
je 0x478e45
cmp qword [rsp + 0x68], rcx
je 0x479171
lea r8d, [r10 - 1]
mov edx, 1
lea r9, [rsp + 0x60]
mov rbp, r8
add r8, 1
jmp 0x478e3e
add rdx, 1
cmp qword [r9 + rdx*8], rcx
je 0x479180
cmp r8, rdx
mov eax, edx
jne 0x478e30
test sil, sil
je 0x4790f0
lea rsi, [rsp + 0x58]
mov qword [rsp + 0x58], 0
mov ecx, dword [rsp + 0x60]
test ecx, ecx
jne 0x478ef0
mov edx, dword [rsp + 0x4070]
test edx, edx
jne 0x478ef0
mov eax, dword [rsp + 0x8080]
test eax, eax
jne 0x478ef0
test rsi, rsi
je 0x478ea9
mov r8d, dword [rsi + 4]
mov edx, 0x10624dd3
imul ecx, dword [rsi], 0x3e8
mov eax, r8d
sar r8d, 0x1f
imul edx
sar edx, 6
sub edx, r8d
add ecx, edx
call qword [sym.imp.KERNEL32.dll_Sleep]
movzx eax, byte [rbx + 0x178]
test al, al
jne 0x478f50
lea r13, [rsp + 0x8080]
lea rbp, [rsp + 0x4070]
lea r12, [rsp + 0x60]
mov r9, r13
mov r8, rbp
mov rdx, r12
mov rcx, rbx
call fcn.00476410
cmp eax, 1
jne 0x478f50
mov eax, edi
xor eax, 1
jmp 0x478f52
lea r13, [rsp + 0x8080]
lea rbp, [rsp + 0x4070]
lea r12, [rsp + 0x60]
xor ecx, ecx
mov qword [rsp + 0x20], rsi
mov rdx, r12
mov r9, r13
mov r8, rbp
call qword [sym.imp.WS2_32.dll_select]
movzx edx, byte [rbx + 0x178]
test dl, dl
jne 0x478f50
test eax, eax
jns 0x478ecd
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2714
je 0x478ee3
mov ecx, eax
call fcn.0047c1a0
lea rdx, str.select_failed:__s_n
mov r8, rax
mov rcx, rbx
call fcn.0047b4a0
xor eax, eax
add rsp, 0xc090
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
ret
test byte [rbx + 0x194], 4
je 0x4791c4
mov rcx, qword [rbx + 0x158]
cmp rcx, 0xffffffffffffffff
je 0x478fb0
movzx eax, byte [rbx + 0x179]
test al, al
jne 0x478fb0
lea r12, [rsp + 0x60]
lea r8, [rsp + 0x48]
mov r9d, 0x800
mov rdx, r12
call fcn.0047cd70
test eax, eax
je 0x4791d0
nop dword [rax]
xor edi, edi
jmp 0x478d9c
call fcn.00474af0
cmp eax, 1
je 0x478f64
mov eax, dword [rbx + 0x194]
jmp 0x478d6b
lea rax, [rsp + 0x48]
lea r12, [rsp + 0x60]
lea r9, [rsp + 0x8080]
lea r8, [rsp + 0x4070]
mov dword [rsp + 0x28], 0x800
mov rcx, rbx
mov qword [rsp + 0x20], rax
mov rdx, r12
call fcn.00476160
test eax, eax
je 0x478d83
xor edi, edi
jmp 0x478d9c
mov rcx, qword [rbx + 0x158]
cmp rcx, 0xffffffffffffffff
je 0x4791f0
movzx eax, byte [rbx + 0x179]
test al, al
jne 0x4791b3
mov r9d, dword [rsp + 0x60]
test r9d, r9d
je 0x479086
cmp qword [rsp + 0x68], rcx
je 0x4791fd
lea edx, [r9 - 1]
mov eax, 1
mov r14, rdx
add rdx, 1
jmp 0x47907e
add rax, 1
cmp qword [r12 + rax*8], rcx
je 0x479204
cmp rdx, rax
mov r8d, eax
jne 0x479070
mov rcx, qword [rbx + 0x168]
mov r9d, 0x800
mov r8, r13
mov rdx, r12
call fcn.0047cd70
test eax, eax
jne 0x478dcc
lea rdx, str.Could_not_add_control_inter_thread_communication_channel_FD_to_fdset
mov rcx, rbx
mov edi, 1
call fcn.0047b4a0
mov rcx, qword [rbx + 0x158]
cmp rcx, 0xffffffffffffffff
je 0x478e4e
cmp qword [rbx + 0x168], 0xffffffffffffffff
mov esi, 1
mov edi, 1
jne 0x478deb
jmp 0x478e4e
xor esi, esi
test byte [rbx + 0x194], 4
jne 0x478e5c
lea rdx, [rsp + 0x50]
mov rcx, rbx
call sym.xmrig.exe_MHD_get_timeout
cmp eax, 1
jne 0x478e5c
mov rcx, qword [rsp + 0x50]
movabs r8, 0x20c49ba5e353f7cf
mov rdx, rcx
mov rsi, rcx
shr rdx, 3
mov rax, rdx
mul r8
shr rdx, 4
imul rax, rdx, 0x3e8
sub rsi, rax
imul eax, esi, 0x3e8
mov dword [rsp + 0x5c], eax
movabs rax, 0x1f3ffffffff
cmp rcx, rax
jbe 0x479235
mov dword [rsp + 0x58], 0x7fffffff
lea rsi, [rsp + 0x58]
jmp 0x478e5c
lea ebp, [r10 - 1]
xor eax, eax
nop word [rax + rax]
cmp ebp, eax
jbe 0x4791aa
lea r12, [rsp + 0x60]
sub r10d, 2
lea edx, [rax + 1]
sub r10d, eax
lea rdx, [r12 + rdx*8 + 8]
lea rcx, [r12 + rax*8 + 8]
lea r8, [r10*8 + 8]
call sub.msvcrt.dll_memmove
mov dword [rsp + 0x60], ebp
jmp 0x478e45
mov eax, esi
xor eax, 1
and eax, 1
or eax, ebp
mov esi, eax
jmp 0x478de1
xor esi, esi
jmp 0x478d73
lea rdx, str.Could_not_add_listen_socket_to_fdset
mov rcx, rbx
mov dword [rsp + 0x3c], eax
call fcn.0047b4a0
mov eax, dword [rsp + 0x3c]
jmp 0x478f52
xor esi, 1
and esi, 1
or esi, ebp
jmp 0x478e45
lea r14d, [r9 - 1]
xor r8d, r8d
cmp r8d, r14d
jae 0x47922b
lea eax, [r8 + 1]
sub r9d, 2
lea rcx, [r12 + r8*8 + 8]
sub r9d, r8d
lea rdx, [r12 + rax*8 + 8]
lea r8, [r9*8 + 8]
call sub.msvcrt.dll_memmove
mov dword [rsp + 0x60], r14d
jmp 0x479086
mov dword [rsp + 0x58], edx
lea rsi, [rsp + 0x58]
jmp 0x478e5c