Function at 0x47c490
Capabilities:
Get hostname

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x24c
mov esi, dword [ebp + 8]
mov eax, dword [ebp + 0xc]
mov ecx, dword [0x597010]
xor ecx, ebp
mov dword [ebp - 0x10], ecx
xor ecx, ecx
dec ecx
mov dword [esi], ecx
mov dword [esi + 4], ecx
mov dword [esi + 8], ecx
cmp byte [eax + 0xb], 0
js 0x47c4ce
mov ecx, dword [eax + 8]
mov dword [esi + 8], ecx
movsd xmm0, qword [eax]
movsd qword [esi], xmm0
jmp 0x47c4da
mov ecx, esi
push dword [eax + 4]
push dword [eax]
call fcn.0044e310
movzx eax, byte [esi + 0xb]
test al, al
js 0x47c50a
test eax, eax
je 0x47cbd3
cmp eax, 1
je 0x47c590
movzx ecx, word [esi]
cmp ecx, 0x22
je 0x47c568
cmp ecx, 0x27
jne 0x47c590
mov edx, esi
mov ecx, eax
jmp 0x47c549
mov edx, dword [esi + 4]
test edx, edx
je 0x47cbd3
cmp edx, 1
je 0x47c590
mov ecx, dword [esi]
cmp word [ecx], 0x22
jne 0x47c536
cmp word [ecx + edx*2 - 2], 0x22
je 0x47c551
test al, al
js 0x47c536
cmp cx, 0x27
je 0x47c504
jmp 0x47c590
mov ecx, dword [esi + 4]
test ecx, ecx
je 0x47cfde
mov edx, dword [esi]
cmp word [edx], 0x27
jne 0x47c590
cmp word [edx + ecx*2 - 2], 0x27
jne 0x47c590
test al, al
jns 0x47c570
mov eax, dword [esi + 4]
test eax, eax
je 0x47cfe1
mov ecx, dword [esi]
dec eax
mov dword [esi + 4], eax
jmp 0x47c57f
cmp word [esi + eax*2 - 2], 0x22
jne 0x47c590
dec eax
cmp eax, 5
jae 0x47cfdb
mov byte [esi + 0xb], al
mov ecx, esi
mov word [ecx + eax*2], 0
mov ecx, esi
push 1
push 0
call fcn.0044c672
push str.shell32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov edi, eax
xor eax, eax
dec eax
mov dword [ebp - 0x23c], eax
test edi, edi
je 0x47c5bc
push 0x58239d
push edi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 0x23c], eax
mov dword [ebp - 0x258], edi
xor ebx, ebx
mov edi, dword [ebx*8 + 0x5823d0]
test edi, edi
je 0x47cfcc
push edi
call fcn.00542c14
add esp, 4
movzx edx, byte [esi + 0xb]
mov dword [ebp - 0x230], esi
test dl, dl
jns 0x47c5f2
mov ecx, dword [esi]
mov dword [ebp - 0x230], ecx
test eax, eax
mov dword [ebp - 0x24c], ebx
je 0x47c6b7
mov dword [ebp - 0x22c], edi
test dl, dl
jns 0x47c60d
mov edx, dword [esi + 4]
cmp edx, eax
jl 0x47c8b5
mov edi, dword [ebp - 0x230]
lea ecx, [edi + edx*2]
mov dword [ebp - 0x238], ecx
mov ecx, dword [ebp - 0x22c]
movzx ecx, word [ecx]
lea ebx, [edi + edx*2]
add ebx, 0xfffffffe
mov dword [ebp - 0x244], ebx
mov ebx, edx
sub ebx, eax
inc ebx
je 0x47c8b5
inc edx
xor ebx, ebx
cmp word [edi + ebx], cx
je 0x47c65a
add ebx, 2
dec edx
cmp eax, edx
jne 0x47c647
jmp 0x47c8b5
mov edx, edi
add edx, ebx
je 0x47c8b5
mov word [ebp - 0x248], cx
mov dword [ebp - 0x234], edx
xor edx, edx
mov ecx, dword [ebp - 0x234]
movzx esi, word [ecx + edx*2]
mov ecx, dword [ebp - 0x22c]
cmp si, word [ecx + edx*2]
jne 0x47c693
inc edx
cmp eax, edx
jne 0x47c673
jmp 0x47c7c4
mov edx, dword [ebp - 0x244]
sub edx, edi
add edi, ebx
add edi, 2
sub edx, ebx
sar edx, 1
cmp edx, eax
mov esi, dword [ebp + 8]
movzx ecx, word [ebp - 0x248]
jge 0x47c639
jmp 0x47c8b5
mov dword [ebp - 0x234], 0
push edi
call fcn.00542c14
add esp, 4
mov dword [ebp - 0x22c], eax
push 0x208
push 0xff
lea edi, [ebp - 0x218]
push edi
call fcn.0052c210
add esp, 0xc
mov esi, dword [ebx*8 + 0x5823d4]
mov ecx, dword [ebp - 0x23c]
call dword [section..00cfg]
xor eax, eax
push eax
push esi
mov esi, edi
push edi
push eax
call ecx
test eax, eax
jne 0x47c713
mov word [ebp - 0x218], 0
xor eax, eax
dec eax
mov dword [ebp - 0x224], eax
mov dword [ebp - 0x220], eax
mov dword [ebp - 0x21c], eax
lea ecx, [ebp - 0x224]
push esi
call fcn.0042d4b2
mov cl, byte [ebp - 0x219]
test cl, cl
mov eax, dword [ebp - 0x220]
movzx edx, cl
mov esi, edx
cmovs esi, eax
test esi, esi
je 0x47c7bc
test cl, cl
js 0x47c761
mov esi, edx
lea edi, [ebp - 0x224]
jne 0x47c771
jmp 0x47cfcf
test eax, eax
je 0x47cfcf
mov edi, dword [ebp - 0x224]
mov esi, eax
cmp word [edi + esi*2 - 2], 0x5c
jne 0x47c7bc
mov dword [ebp - 0x230], eax
mov esi, dword [ebp + 8]
movzx eax, byte [esi + 0xb]
test al, al
mov esi, dword [esi + 4]
mov ebx, eax
mov dword [ebp - 0x244], esi
cmovs ebx, esi
mov edi, dword [ebp - 0x234]
mov esi, dword [ebp - 0x22c]
add edi, esi
cmp ebx, edi
jbe 0x47c840
test al, al
js 0x47c801
mov esi, dword [ebp + 8]
cmp edi, eax
jbe 0x47c812
jmp 0x47cfd2
mov esi, dword [ebp + 8]
jmp 0x47c875
mov ecx, dword [ebp - 0x234]
cmp ecx, dword [ebp - 0x238]
mov esi, dword [ebp + 8]
je 0x47c8b5
sub ecx, dword [ebp - 0x230]
cmp ecx, 0xfffffffe
je 0x47c8b5
sar ecx, 1
mov dword [ebp - 0x234], ecx
mov ebx, dword [ebp - 0x24c]
mov edi, dword [ebp - 0x22c]
jmp 0x47c6c1
cmp dword [ebp - 0x244], edi
jb 0x47cfd2
mov eax, dword [ebp + 8]
mov esi, dword [eax]
cmp word [esi + edi*2], 0x5c
jne 0x47c840
test cl, cl
mov esi, dword [ebp + 8]
mov eax, dword [ebp - 0x230]
js 0x47c84b
cmp cl, 6
jae 0x47cfd5
dec edx
mov byte [ebp - 0x219], dl
mov eax, edx
lea ecx, [ebp - 0x224]
jmp 0x47c860
mov esi, dword [ebp + 8]
mov eax, dword [ebp - 0x230]
jmp 0x47c875
test eax, eax
je 0x47cfd8
mov ecx, dword [ebp - 0x224]
dec eax
mov dword [ebp - 0x220], eax
mov word [ecx + eax*2], 0
mov cl, byte [ebp - 0x219]
mov eax, dword [ebp - 0x220]
movzx edx, cl
test cl, cl
cmovs edx, eax
mov eax, dword [ebp - 0x224]
lea ecx, [ebp - 0x224]
cmovns eax, ecx
mov ecx, esi
push edx
push eax
push dword [ebp - 0x22c]
push dword [ebp - 0x234]
call fcn.0044debc
cmp byte [ebp - 0x219], 0
jns 0x47c8b5
push dword [ebp - 0x224]
call fcn.00528424
add esp, 4
mov ebx, dword [ebp - 0x24c]
inc ebx
cmp ebx, 7
jne 0x47c5c4
push str.advapi32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
test eax, eax
mov dword [ebp - 0x24c], eax
je 0x47c8e8
push 0x58240a
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
jmp 0x47c8eb
xor eax, eax
dec eax
mov dword [ebp - 0x23c], eax
mov cl, byte [esi + 0xb]
test cl, cl
mov eax, dword [esi]
mov edx, dword [esi + 4]
mov edi, esi
cmovs edi, eax
mov byte [ebp - 0x234], cl
movzx ecx, cl
mov ebx, ecx
mov dword [ebp - 0x22c], edx
cmovs ebx, edx
cmp ebx, 0xc
jge 0x47c92a
mov edi, dword [ebp - 0x22c]
mov dl, byte [ebp - 0x234]
jmp 0x47c9ca
lea edx, [edi + ebx*2]
mov dword [ebp - 0x238], edx
lea edx, [edi + ebx*2]
add edx, 0xfffffffe
mov dword [ebp - 0x244], edx
mov dword [ebp - 0x248], edi
mov esi, edi
mov edi, dword [ebp - 0x22c]
mov dl, byte [ebp - 0x234]
mov dword [ebp - 0x230], eax
add ebx, 0xfffffff5
je 0x47c9bc
xor eax, eax
cmp word [esi + eax], 0x24
je 0x47c96f
add eax, 2
dec ebx
jne 0x47c960
jmp 0x47c9c1
mov ebx, esi
add ebx, eax
je 0x47c9c1
mov edx, 0xffffffe8
movzx edi, word [ebx + edx + 0x18]
cmp di, word [edx + 0x58244a]
jne 0x47c992
add edx, 2
jne 0x47c97a
jmp 0x47cc68
mov edx, dword [ebp - 0x244]
sub edx, esi
add esi, eax
add esi, 2
sub edx, eax
mov ebx, edx
shr ebx, 1
cmp edx, 0x18
mov eax, dword [ebp - 0x230]
mov dl, byte [ebp - 0x234]
mov edi, dword [ebp - 0x22c]
jge 0x47c959
mov esi, dword [ebp + 8]
jmp 0x47c9ca
mov esi, dword [ebp + 8]
mov eax, dword [ebp - 0x230]
test dl, dl
cmovns eax, esi
cmovs ecx, edi
cmp ecx, 0xf
jge 0x47ca5d
push str.wtsapi32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov esi, eax
xor ebx, ebx
dec ebx
mov eax, ebx
test esi, esi
je 0x47c9fd
push 0x58246e
push esi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 0x230], eax
mov dword [ebp - 0x234], esi
push str.wtsapi32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov edi, eax
test eax, eax
mov esi, dword [ebp + 8]
je 0x47ca2b
push 0x5824a6
push edi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov ebx, eax
mov dword [ebp - 0x244], ebx
mov dword [ebp - 0x22c], edi
mov dl, byte [esi + 0xb]
test dl, dl
mov eax, dword [esi]
mov ebx, dword [esi + 4]
cmovs esi, eax
movzx ecx, dl
mov edi, ecx
cmovs edi, ebx
cmp edi, 0xe
jge 0x47cadf
mov esi, dword [ebp + 8]
jmp 0x47cb7f
lea esi, [eax + ecx*2]
lea edx, [eax + ecx*2]
add edx, 0xfffffffe
mov dword [ebp - 0x234], edx
mov edi, eax
add ecx, 0xfffffff2
je 0x47c9db
xor edx, edx
cmp word [edi + edx], 0x24
je 0x47ca8b
add edx, 2
dec ecx
jne 0x47ca79
jmp 0x47c9db
mov ebx, edi
add ebx, edx
je 0x47c9db
mov dword [ebp - 0x22c], esi
mov esi, eax
mov eax, 0xffffffe2
movzx ecx, word [ebx + eax + 0x1e]
cmp cx, word [eax + 0x58246a]
jne 0x47caba
add eax, 2
jne 0x47caa2
jmp 0x47cd60
mov eax, dword [ebp - 0x234]
sub eax, edi
add edi, edx
add edi, 2
sub eax, edx
mov ecx, eax
shr ecx, 1
cmp eax, 0x1e
mov eax, esi
mov esi, dword [ebp - 0x22c]
jge 0x47ca6e
jmp 0x47c9db
mov dword [ebp - 0x238], ebx
lea ebx, [esi + edi*2]
mov dword [ebp - 0x254], ebx
lea ebx, [esi + edi*2]
add ebx, 0xfffffffe
mov dword [ebp - 0x248], ebx
mov dword [ebp - 0x250], esi
mov ebx, esi
mov esi, dword [ebp + 8]
mov dword [ebp - 0x23c], eax
add edi, 0xfffffff3
je 0x47cb79
xor eax, eax
cmp word [ebx + eax], 0x24
je 0x47cb21
add eax, 2
dec edi
jne 0x47cb12
jmp 0x47cb73
mov edi, ebx
add edi, eax
je 0x47cb73
mov byte [ebp - 0x23d], dl
mov edx, 0xffffffe4
movzx esi, word [edi + edx + 0x1c]
cmp si, word [edx + 0x5824d0]
jne 0x47cb4a
add edx, 2
jne 0x47cb32
jmp 0x47ce1e
mov edx, dword [ebp - 0x248]
sub edx, ebx
add ebx, eax
add ebx, 2
sub edx, eax
mov edi, edx
shr edi, 1
cmp edx, 0x1c
mov esi, dword [ebp + 8]
mov eax, dword [ebp - 0x23c]
mov dl, byte [ebp - 0x23d]
jge 0x47cb0b
jmp 0x47cb79
mov eax, dword [ebp - 0x23c]
mov ebx, dword [ebp - 0x238]
test dl, dl
cmovns eax, esi
cmovs ecx, ebx
cmp ecx, 0xf
jge 0x47cbea
mov eax, dword [ebp - 0x22c]
test eax, eax
je 0x47cb9d
push eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, dword [ebp - 0x234]
test eax, eax
je 0x47cbae
push eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, dword [ebp - 0x24c]
test eax, eax
mov esi, dword [ebp + 8]
je 0x47cbc2
push eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, dword [ebp - 0x258]
test eax, eax
je 0x47cbd3
push eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00528e13
mov eax, esi
add esp, 0x24c
pop esi
pop edi
pop ebx
pop ebp
ret
lea esi, [eax + ecx*2]
lea edx, [eax + ecx*2]
add edx, 0xfffffffe
mov dword [ebp - 0x23c], edx
mov ebx, eax
add ecx, 0xfffffff2
je 0x47cb8c
xor edx, edx
cmp word [ebx + edx], 0x24
je 0x47cc14
add edx, 2
dec ecx
jne 0x47cc02
jmp 0x47cb8c
mov edi, ebx
add edi, edx
je 0x47cb8c
mov dword [ebp - 0x238], esi
mov esi, eax
mov eax, 0xffffffe2
movzx ecx, word [edi + eax + 0x1e]
cmp cx, word [eax + 0x5824f0]
jne 0x47cc43
add eax, 2
jne 0x47cc2b
jmp 0x47ceff
mov eax, dword [ebp - 0x23c]
sub eax, ebx
add ebx, edx
add ebx, 2
sub eax, edx
mov ecx, eax
shr ecx, 1
cmp eax, 0x1e
mov eax, esi
mov esi, dword [ebp - 0x238]
jge 0x47cbfb
jmp 0x47cb8c
cmp ebx, dword [ebp - 0x238]
mov esi, dword [ebp + 8]
mov eax, dword [ebp - 0x230]
mov dl, byte [ebp - 0x234]
je 0x47cfc1
sub ebx, dword [ebp - 0x248]
cmp ebx, 0xfffffffe
mov edi, dword [ebp - 0x22c]
je 0x47c9ca
xor edi, edi
lea esi, [ebp - 0x224]
mov dword [esi], edi
mov ecx, dword [ebp - 0x23c]
call dword [section..00cfg]
push esi
push edi
mov edi, ecx
call ecx
mov eax, dword [esi]
test eax, eax
je 0x47cd4d
sar ebx, 1
lea ecx, [eax + eax]
xor edx, edx
dec edx
test eax, eax
cmovs ecx, edx
push ecx
call fcn.00528453
add esp, 4
mov ecx, edi
mov edi, eax
call dword [section..00cfg]
push esi
push edi
call ecx
xor eax, eax
dec eax
mov dword [ebp - 0x218], eax
mov dword [ebp - 0x214], eax
mov dword [ebp - 0x210], eax
lea esi, [ebp - 0x218]
mov ecx, esi
push edi
call fcn.0042d4b2
movzx eax, byte [ebp - 0x20d]
test al, al
jns 0x47cd1c
mov eax, dword [ebp - 0x214]
mov esi, dword [ebp - 0x218]
mov ecx, dword [ebp + 8]
push eax
push esi
push 0xc
push ebx
call fcn.0044debc
cmp byte [ebp - 0x20d], 0
jns 0x47cd40
push dword [ebp - 0x218]
call fcn.00528424
add esp, 4
test edi, edi
je 0x47cd4d
push edi
call fcn.0052845c
add esp, 4
mov esi, dword [ebp + 8]
mov dl, byte [esi + 0xb]
mov eax, dword [esi]
mov edi, dword [esi + 4]
movzx ecx, dl
jmp 0x47c9ca
cmp ebx, dword [ebp - 0x22c]
je 0x47c9db
sub ebx, esi
cmp ebx, 0xfffffffe
je 0x47c9db
xor eax, eax
lea edi, [ebp - 0x224]
mov dword [edi], eax
push edi
push eax
push 5
call dword [sym.imp.KERNEL32.dll_GetComputerNameExW]
mov eax, dword [edi]
test eax, eax
je 0x47c9db
sar ebx, 1
lea ecx, [eax + eax]
xor edx, edx
dec edx
test eax, eax
cmovs ecx, edx
push ecx
call fcn.00528453
add esp, 4
mov esi, eax
push edi
push eax
push 5
call dword [sym.imp.KERNEL32.dll_GetComputerNameExW]
lea edi, [ebp - 0x218]
xor eax, eax
dec eax
mov dword [edi], eax
mov dword [edi + 4], eax
mov dword [edi + 8], eax
mov ecx, edi
push esi
call fcn.0042d4b2
movzx eax, byte [edi + 0xb]
test al, al
jns 0x47cde4
mov eax, dword [ebp - 0x214]
mov edi, dword [ebp - 0x218]
mov ecx, dword [ebp + 8]
push eax
push edi
push 0xf
push ebx
call fcn.0044debc
cmp byte [ebp - 0x20d], 0
jns 0x47ce08
push dword [ebp - 0x218]
call fcn.00528424
add esp, 4
test esi, esi
je 0x47c9db
push esi
call fcn.0052845c
add esp, 4
jmp 0x47c9db
cmp edi, dword [ebp - 0x254]
mov eax, dword [ebp - 0x23c]
mov dl, byte [ebp - 0x23d]
mov ebx, dword [ebp - 0x238]
je 0x47ca55
sub edi, dword [ebp - 0x250]
cmp edi, 0xfffffffe
mov esi, dword [ebp + 8]
je 0x47cb7f
xor esi, esi
lea eax, [ebp - 0x224]
mov dword [eax], esi
lea ebx, [ebp - 0x228]
mov dword [ebx], esi
mov ecx, dword [ebp - 0x230]
call dword [section..00cfg]
push ebx
lea eax, [ebp - 0x224]
push eax
push 0xa
push 0xffffffffffffffff
push esi
call ecx
test eax, eax
je 0x47ceec
sar edi, 1
xor eax, eax
dec eax
lea esi, [ebp - 0x218]
mov dword [esi], eax
mov dword [esi + 4], eax
mov dword [esi + 8], eax
mov ecx, esi
push dword [ebp - 0x224]
call fcn.0042d4b2
movzx eax, byte [esi + 0xb]
test al, al
jns 0x47ceb3
mov eax, dword [ebp - 0x214]
mov esi, dword [ebp - 0x218]
mov ecx, dword [ebp + 8]
push eax
push esi
push 0xe
push edi
call fcn.0044debc
mov esi, dword [ebp - 0x224]
mov ecx, dword [ebp - 0x244]
call dword [section..00cfg]
push esi
call ecx
cmp byte [ebp - 0x20d], 0
jns 0x47ceec
push dword [ebp - 0x218]
call fcn.00528424
add esp, 4
mov esi, dword [ebp + 8]
mov dl, byte [esi + 0xb]
mov eax, dword [esi]
mov ebx, dword [esi + 4]
movzx ecx, dl
jmp 0x47cb7f
cmp edi, dword [ebp - 0x238]
je 0x47cb8c
sub edi, esi
cmp edi, 0xfffffffe
je 0x47cb8c
xor esi, esi
lea eax, [ebp - 0x224]
mov dword [eax], esi
lea ebx, [ebp - 0x228]
mov dword [ebx], esi
mov ecx, dword [ebp - 0x230]
call dword [section..00cfg]
push ebx
lea eax, [ebp - 0x224]
push eax
push 6
push 0xffffffffffffffff
push esi
call ecx
test eax, eax
je 0x47cb8c
sar edi, 1
xor eax, eax
dec eax
lea esi, [ebp - 0x218]
mov dword [esi], eax
mov dword [esi + 4], eax
mov dword [esi + 8], eax
mov ecx, esi
push dword [ebp - 0x224]
call fcn.0042d4b2
movzx eax, byte [esi + 0xb]
test al, al
jns 0x47cf7f
mov eax, dword [ebp - 0x214]
mov esi, dword [ebp - 0x218]
mov ecx, dword [ebp + 8]
push eax
push esi
push 0xf
push edi
call fcn.0044debc
mov esi, dword [ebp - 0x224]
mov ecx, dword [ebp - 0x244]
call dword [section..00cfg]
push esi
call ecx
cmp byte [ebp - 0x20d], 0
jns 0x47cb8c
push dword [ebp - 0x218]
call fcn.00528424
add esp, 4
jmp 0x47cb8c
mov edi, dword [ebp - 0x22c]
jmp 0x47c9ca
int3
int3
int3
int3
int3
int3
int3
int3