Function at 0x1016aba
Capabilities:
Get hostname

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x12c
mov eax, dword [0x101d774]
or dword [ebp - 0x110], 0xffffffff
push ebx
mov ebx, dword [ebp + 0xc]
push esi
mov esi, dword [ebp + 0x14]
xor ecx, ecx
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
cmp eax, ecx
push edi
mov edi, dword [ebp + 0x1c]
mov dword [ebp - 0x114], ebx
mov dword [ebp - 0x124], esi
mov dword [ebp - 0x128], edi
mov dword [ebp - 0x118], ecx
mov dword [ebp - 0x120], ecx
mov dword [ebp - 0x10c], ecx
je 0x1016b46
cmp word [eax], cx
je 0x1016b46
lea ecx, [ebp - 0x10c]
push ecx
movzx ecx, word [ebp + 0x18]
push ecx
movzx ecx, word [ebp + 0x10]
push esi
push ecx
push ebx
push eax
call fcn.01017c55
mov ebx, eax
mov eax, dword [ebp - 0x10c]
cmp eax, 0xffff
ja 0x1016cc6
mov word [edi], ax
jmp 0x1016ecf
cmp word [ebp + 0x10], 5
mov word [edi], cx
jbe 0x1016b5f
cmp word [ebp + 0x10], 0x34
je 0x1016b5f
push 0x7c
pop ebx
jmp 0x1016f0b
cmp ebx, ecx
je 0x1016ecc
cmp word [ebx], cx
je 0x1016ecc
push ecx
lea eax, [ebp - 0x110]
push eax
push ebx
call fcn.010174b9
test eax, eax
jne 0x1016ba0
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
cmp ebx, 0x709
jne 0x1016ecf
mov ebx, 0x866
jmp 0x1016ecf
cmp word [ebp + 0x10], 0x34
lea eax, [ebp - 0x10c]
push eax
jne 0x1016ccd
lea eax, [ebp - 0x106]
push eax
mov dword [ebp - 0x10c], 0x102
mov byte [ebp - 0x107], 0x5c
mov byte [ebp - 0x108], 0x5c
call dword [sym.imp.KERNEL32.dll_GetComputerNameA]
test eax, eax
jne 0x1016be6
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x1016d39
lea eax, [ebp - 0x108]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x1016bef
sub eax, edx
add eax, 0x10
cmp eax, 0x104
ja 0x1016cc6
lea edi, [ebp - 0x108]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x1016c0d
mov esi, 0x10026e8
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
lea eax, [ebp - 0x10c]
push eax
movsd dword es:[edi], dword [esi]
push 0
push 0
movsd dword es:[edi], dword [esi]
push 3
mov esi, 0x10026dc
push esi
push dword [ebp - 0x110]
call fcn.01017537
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
call edi
mov ebx, eax
cmp ebx, 0x7a
jne 0x1016ecf
push dword [ebp - 0x10c]
push 0
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov ebx, eax
test ebx, ebx
mov dword [ebp - 0x120], ebx
je 0x1016cc6
lea eax, [ebp - 0x10c]
push eax
push dword [ebp - 0x10c]
push ebx
push 3
push esi
push dword [ebp - 0x110]
call fcn.01017537
test eax, eax
je 0x1016d37
lea eax, [ebp - 0x11c]
push eax
lea eax, [ebp - 0x108]
push eax
push 0x34
mov eax, ebx
call fcn.01015fe3
cmp dword [ebp - 0x11c], 0x40
mov dword [ebp - 0x10c], eax
ja 0x1016cc6
mov esi, dword [ebp - 0x124]
mov edi, 0xffff
cmp eax, edi
jbe 0x1016d5b
push 8
jmp 0x1016ece
push 0
push 0
push 2
push dword [ebp - 0x110]
call fcn.01017576
test eax, eax
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
jne 0x1016d13
call edi
mov ebx, eax
cmp ebx, 0x7a
jne 0x1016ecf
push dword [ebp - 0x10c]
push 0
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
test eax, eax
mov dword [ebp - 0x118], eax
je 0x1016cc6
mov ebx, dword [ebp - 0x114]
lea eax, [ebp - 0x10c]
push eax
push dword [ebp - 0x10c]
push dword [ebp - 0x118]
push 2
push dword [ebp - 0x110]
call fcn.01017576
test eax, eax
jne 0x1016d40
call edi
mov ebx, eax
jmp 0x1016ecf
movzx eax, word [ebp + 0x10]
mov ecx, dword [ebp - 0x118]
push ebx
call fcn.01015e23
mov dword [ebp - 0x10c], eax
jmp 0x1016cb9
movzx ebx, word [ebp + 0x18]
cmp eax, ebx
mov ecx, dword [ebp - 0x128]
mov word [ecx], ax
ja 0x1016e77
cmp word [ebp + 0x10], 0x34
jne 0x1016dae
mov ecx, eax
mov edx, ecx
shr ecx, 2
xor eax, eax
mov edi, esi
rep stosd dword es:[edi], eax
add ebx, esi
push ebx
mov ecx, edx
push esi
mov esi, dword [ebp - 0x120]
and ecx, 3
rep stosb byte es:[edi], al
push 0x34
lea eax, [ebp - 0x108]
push eax
push dword [ebp - 0x11c]
call fcn.01016334
jmp 0x1016e73
movzx eax, word [ebp + 0x10]
push dword [ebp - 0x114]
lea ecx, [ebx + esi]
mov edx, esi
mov esi, dword [ebp - 0x118]
mov dword [ebp - 0x11c], eax
call fcn.010161cd
cmp word [ebp + 0x10], 2
je 0x1016de0
cmp word [ebp + 0x10], 4
jne 0x1016e73
xor ecx, ecx
cmp word [ebp + 0x18], di
sete cl
sub ebx, dword [ebp - 0x10c]
push ecx
lea ecx, [ebp - 0x12c]
push ecx
lea ecx, [ebp - 0x114]
push ecx
push 0
push eax
mov eax, dword [ebp - 0x11c]
push ebx
call fcn.010161a0
add eax, dword [ebp - 0x124]
push eax
push dword [ebp - 0x110]
push dword [ebp - 0x11c]
push dword [ebp - 0x114]
call fcn.0101650d
mov ecx, dword [ebp - 0x10c]
mov ebx, eax
mov eax, dword [ebp - 0x114]
lea edx, [eax + ecx]
cmp edx, edi
jbe 0x1016e4b
mov eax, dword [ebp - 0x128]
mov word [eax], di
jmp 0x1016e56
add eax, ecx
mov ecx, dword [ebp - 0x128]
mov word [ecx], ax
push dword [ebp - 0x12c]
push 1
push dword [ebp - 0x124]
push dword [ebp - 0x11c]
call fcn.01016a7c
test ebx, ebx
jne 0x1016ecf
xor ebx, ebx
jmp 0x1016ecf
cmp word [ebp + 0x10], 2
je 0x1016e85
cmp word [ebp + 0x10], 4
jne 0x1016eba
lea eax, [ebp - 0x114]
push eax
push dword [ebp - 0x110]
movzx eax, word [ebp + 0x10]
push eax
push dword [ebp - 0x114]
call fcn.01016425
mov ebx, eax
test ebx, ebx
jne 0x1016ecf
mov eax, dword [ebp - 0x10c]
add eax, dword [ebp - 0x114]
mov dword [ebp - 0x10c], eax
cmp edi, eax
sbb ebx, ebx
and ebx, 0xfffff7bd
add ebx, 0x84b
jmp 0x1016ecf
push 0x57
pop ebx
cmp dword [ebp - 0x110], 0xffffffff
je 0x1016ee3
push dword [ebp - 0x110]
call fcn.010173bd
cmp dword [ebp - 0x118], 0
mov esi, dword [sym.imp.KERNEL32.dll_GlobalFree]
je 0x1016efa
push dword [ebp - 0x118]
call esi
cmp dword [ebp - 0x120], 0
je 0x1016f0b
push dword [ebp - 0x120]
call esi
mov ecx, dword [ebp - 4]
pop edi
pop esi
mov eax, ebx
pop ebx
call fcn.0100f4dc
leave
ret 0x18