Function at 0x10012b970
Capabilities:
Get hostname

Disassembly:
push rbp
push rsi
push rdi
sub rsp, 0x40
mov qword [rsp + 0x30], 0xfffffffffffffffe
mov qword [rsp + 0x60], rbx
mov edi, ecx
or rbp, 0xffffffffffffffff
mov qword [rsp + 0x70], rbp
mov eax, dword [0x10029a8b0]
and eax, 0x20004
cmp eax, 0x20004
jne 0x10012b9c3
mov rax, qword [0x1004e2d38]
test rax, rax
je 0x10012b9c3
mov r8d, ecx
mov rdx, qword [0x1004e2d38]
lea rcx, [rsp + 0x70]
call fcn.100126900
xor esi, esi
mov dword [rsp + 0x68], esi
lea r8, [rsp + 0x68]
xor edx, edx
mov ecx, edi
call qword [sym.imp.KERNEL32.dll_GetComputerNameExW]
test eax, eax
je 0x10012ba29
test byte [0x10029a8b0], 2
je 0x10012ba21
mov rax, qword [0x1004e2b00]
test rax, rax
je 0x10012ba21
cmp qword [0x10023faa8], 0xffffffffffffffff
je 0x10012ba21
mov qword [rsp + 0x20], rsi
mov r9, qword [0x1004e2b00]
mov r8d, 0xc9000
mov rdx, qword [0x1004e2510]
mov rcx, qword [0x10023faa8]
call qword [0x10023faf0]
or ebx, 0xffffffff
jmp 0x10012bb47
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
cmp eax, 0xea
je 0x10012ba75
test byte [0x10029a8b0], 2
je 0x10012bb47
mov rcx, qword [0x1004e2b08]
test rcx, rcx
je 0x10012bb47
mov r9d, eax
mov r8, qword [0x1004e2b08]
mov edx, 0xcac00
mov rcx, qword [0x1004e2518]
call fcn.100126850
jmp 0x10012bb47
cmp dword [rsp + 0x68], esi
jne 0x10012bace
test byte [0x10029a8b0], 2
je 0x10012bb47
mov rax, qword [0x1004e2b10]
test rax, rax
je 0x10012bb47
cmp qword [0x10023faa8], 0xffffffffffffffff
je 0x10012bb47
mov qword [rsp + 0x20], rsi
mov r9, qword [0x1004e2b10]
mov r8d, 0xcc400
mov rdx, qword [0x1004e2520]
mov rcx, qword [0x10023faa8]
call qword [0x10023faf0]
jmp 0x10012bb47
mov ebx, esi
call fcn.100058d10
mov rcx, qword [rax + 0x38]
mov r10, qword [rcx]
mov ecx, dword [rsp + 0x68]
inc ecx
mov eax, 2
mul rcx
mov rdx, rax
cmovo rdx, rbp
cmp rdx, 0xffffffffffffffff
jne 0x10012bafc
mov rax, rsi
jmp 0x10012bb17
mov rax, qword [r10]
mov byte [rsp + 0x20], 6
mov r9d, 0x33c
lea r8, [0x100037b10]
mov rcx, r10
call qword [rax + 0x48]
mov edx, dword [0x10029aa18]
mov rcx, qword [0x10029aa10]
mov qword [rcx + rdx*8], rax
mov ecx, dword [0x10029aa18]
mov rax, qword [0x10029aa10]
lea rdx, [rax + rcx*8]
cmp qword [rdx], rbx
jne 0x10012bbc7
mov ebx, ntohs
mov ecx, dword [0x10029aa18]
mov rax, qword [0x10029aa10]
cmp qword [rax + rcx*8], rsi
je 0x10012bc79
mov rdx, qword [rax + rcx*8]
test rdx, rdx
je 0x10012bbb1
mov rax, rdx
mov r8d, 0x200
and rax, 0xffffffffffffe000
je 0x10012bb83
cmp word [rax + 4], r8w
jne 0x10012bb83
mov rax, qword [rax + 0x28]
mov rax, qword [rax + 8]
mov rcx, qword [rax + 0x10]
dec rcx
not rcx
and rcx, rdx
je 0x10012bba1
cmp word [rcx + 4], r8w
jne 0x10012bba1
mov rcx, qword [rcx + 0x28]
mov rcx, qword [rcx + 8]
test byte [rcx + 0x28], 8
jne 0x10012bbb1
mov rax, qword [rcx]
call qword [rax + 0x28]
mov ecx, dword [0x10029aa18]
mov rax, qword [0x10029aa10]
mov qword [rax + rcx*8], rsi
jmp 0x10012bc79
lea r8, [rsp + 0x68]
mov rdx, qword [rdx]
mov ecx, edi
call qword [sym.imp.KERNEL32.dll_GetComputerNameExW]
test eax, eax
jne 0x10012bc19
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
test byte [0x10029a8b0], 2
je 0x10012bc79
mov rax, qword [0x1004e2b18]
test rax, rax
je 0x10012bc79
mov r9d, ebx
mov r8, qword [0x1004e2b18]
mov edx, 0xd1800
mov rcx, qword [0x1004e2528]
call fcn.100126850
jmp 0x10012bc79
mov ecx, dword [0x10029aa18]
mov edx, dword [rsp + 0x68]
mov rax, qword [0x10029aa10]
mov rcx, qword [rax + rcx*8]
mov word [rcx + rdx*2], si
mov eax, dword [0x10029a8b0]
and eax, 0x20002
cmp eax, 0x20002
jne 0x10012bc79
mov rax, qword [0x1004e2b20]
test rax, rax
je 0x10012bc79
mov eax, dword [0x10029aa18]
mov r9, qword [0x10029aa10]
mov r9, qword [r9 + rax*8]
mov r8, qword [0x1004e2b20]
mov edx, 0xd2c00
mov rcx, qword [0x1004e2530]
call fcn.100126850
mov eax, dword [0x10029a8b0]
and eax, 0x20002
cmp eax, 0x20002
jne 0x10012bcb3
mov rax, qword [0x1004e2b28]
test rax, rax
je 0x10012bcb3
mov r9d, ebx
mov r8, qword [0x1004e2b28]
mov edx, 0xd5c00
mov rcx, qword [0x1004e2538]
call fcn.100126850
nop
lea rcx, [rsp + 0x70]
call fcn.100126960
mov eax, ebx
mov rbx, qword [rsp + 0x60]
add rsp, 0x40
pop rdi
pop rsi
pop rbp
ret