Function at 0x58a8d8
Capabilities:
Get hostname
Resolve dns

Disassembly:
mov rax, rsp
mov qword [rax + 8], rcx
push rbx
push rbp
push rsi
push rdi
sub rsp, 0x1c8
mov qword [rsp + 0xb0], 0xfffffffffffffffe
mov rbx, rcx
and dword [rax + 0x18], 0
lea rax, [rsp + 0x40]
mov qword [rsp + 0x60], rax
lea rax, [rsp + 0x40]
mov qword [rsp + 0x68], rax
mov byte [rsp + 0x40], 0
mov edx, 0xff
lea rcx, [rsp + 0xc0]
call qword [sym.imp.WS2_32.dll_gethostname]
lea rcx, [rsp + 0xc0]
call qword [sym.imp.WS2_32.dll_gethostbyname]
mov rsi, rax
test rax, rax
je 0x58ab91
mov rdx, qword [rax + 0x18]
cmp qword [rdx], 0
je 0x58ab91
movsx r8, word [rax + 0x12]
mov rdx, qword [rdx]
lea rcx, [rsp + 0x74]
call fcn.006a4bf0
mov ecx, dword [rsp + 0x74]
call qword [sym.imp.WS2_32.dll_inet_ntoa]
mov rdx, rax
xor eax, eax
or rcx, 0xffffffffffffffff
mov rdi, rdx
repne scasb al, byte [rdi]
not rcx
lea r8, [rcx - 1]
add r8, rdx
lea rcx, [rsp + 0x40]
call fcn.0040289c
lea rdx, [rsp + 0x34]
mov qword [rsp + 0x28], rdx
lea rax, [rsp + 0x30]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x208]
lea r8, [rsp + 0x1f8]
lea rdx, str._d._d._d._d
mov rcx, qword [rsp + 0x68]
call fcn.006a5a7c
cmp eax, 4
jne 0x58a9ea
mov ecx, dword [rsp + 0x1f8]
shl ecx, 8
add ecx, dword [rsp + 0x208]
shl ecx, 8
add ecx, dword [rsp + 0x30]
shl ecx, 8
add ecx, dword [rsp + 0x34]
jmp 0x58a9ec
xor ecx, ecx
call fcn.0058abf0
mov edi, 0x100
test al, al
jne 0x58aa19
mov r8d, 3
lea rdx, [0x007b3e3c]
mov rcx, qword [rsp + 0x68]
call fcn.006a5580
test eax, eax
jne 0x58ab47
mov rax, qword [rsi + 0x18]
cmp qword [rax + 8], 0
je 0x58ab47
mov ebp, 8
movsx r8, word [rsi + 0x12]
mov rdx, qword [rax + rbp]
lea rcx, [rsp + 0x74]
call fcn.006a4bf0
mov ecx, dword [rsp + 0x74]
call qword [sym.imp.WS2_32.dll_inet_ntoa]
mov rdx, rax
lea r8, [rsp + 0x1f8]
lea rcx, [rsp + 0x80]
call fcn.004021a8
nop
lea rax, [rsp + 0x38]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x30]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x34]
lea r8, [rsp + 0x208]
lea rdx, str._d._d._d._d
mov rcx, qword [rsp + 0xa8]
call fcn.006a5a7c
cmp eax, 4
jne 0x58aabb
mov ecx, dword [rsp + 0x208]
shl ecx, 8
add ecx, dword [rsp + 0x34]
shl ecx, 8
add ecx, dword [rsp + 0x30]
shl ecx, 8
add ecx, dword [rsp + 0x38]
jmp 0x58aabd
xor ecx, ecx
call fcn.0058abf0
test al, al
jne 0x58aafe
mov r8d, 3
lea rdx, [0x007b3e3c]
mov rcx, qword [rsp + 0xa8]
call fcn.006a5580
test eax, eax
je 0x58aafe
mov r8, qword [rsp + 0xa0]
mov rdx, qword [rsp + 0xa8]
lea rcx, [rsp + 0x40]
call fcn.0040289c
add rbp, 8
lea rax, [rsp + 0x80]
mov rcx, qword [rsp + 0xa8]
cmp rcx, rax
je 0x58ab38
test rcx, rcx
je 0x58ab38
mov rdx, qword [rsp + 0x80]
sub rdx, rcx
cmp rdx, rdi
jbe 0x58ab33
call fcn.006a4944
jmp 0x58ab38
call fcn.006a3610
mov rax, qword [rsi + 0x18]
cmp qword [rax + rbp], 0
jne 0x58aa2d
lea rdx, [rsp + 0x40]
mov rcx, rbx
call fcn.004029b4
mov dword [rsp + 0x200], 1
lea rax, [rsp + 0x40]
mov rcx, qword [rsp + 0x68]
cmp rcx, rax
je 0x58ab8c
test rcx, rcx
je 0x58ab8c
mov rdx, qword [rsp + 0x40]
sub rdx, rcx
cmp rdx, rdi
jbe 0x58ab87
call fcn.006a4944
jmp 0x58ab8c
call fcn.006a3610
mov rax, rbx
jmp 0x58abe0
lea rdx, [0x0085e820]
mov rcx, rbx
call fcn.004029b4
mov dword [rsp + 0x200], 1
lea rax, [rsp + 0x40]
mov rcx, qword [rsp + 0x68]
cmp rcx, rax
je 0x58abdd
test rcx, rcx
je 0x58abdd
mov rdx, qword [rsp + 0x40]
sub rdx, rcx
mov edi, 0x100
cmp rdx, rdi
jbe 0x58abd8
call fcn.006a4944
jmp 0x58abdd
call fcn.006a3610
mov rax, rbx
add rsp, 0x1c8
pop rdi
pop rsi
pop rbp
pop rbx
ret