Function at 0x408494
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x415577
mov eax, dword fs:[0]
push eax
sub esp, 0x378
push ebx
push esi
push edi
lea edi, [ebp - 0x384]
mov ecx, 0xde
mov eax, 0xcccccccc
rep stosd dword es:[edi], eax
mov eax, dword [0x41f01c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
lea ecx, [ebp - 0x2c]
call fcn.004050c9
and dword [ebp - 4], 0
mov dword [ebp - 0x38], 1
xor eax, eax
mov word [ebp - 0x248], ax
push 0x206
push 0
lea eax, [ebp - 0x246]
push eax
call sub.MSVCR120.dll_memset
add esp, 0xc
mov esi, esp
push 0x104
lea eax, [ebp - 0x248]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
cmp esi, esp
call fcn.00414070
test eax, eax
jne 0x408545
and dword [ebp - 0x380], 0
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x2c]
call fcn.00405812
mov eax, dword [ebp - 0x380]
jmp 0x4087b5
mov esi, esp
push 0x4183b8
push 0x104
lea eax, [ebp - 0x248]
push eax
call dword [sym.imp.MSVCR120.dll_wcscat_s]
add esp, 0xc
cmp esi, esp
call fcn.00414070
test eax, eax
je 0x40858a
and dword [ebp - 0x374], 0
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x2c]
call fcn.00405812
mov eax, dword [ebp - 0x374]
jmp 0x4087b5
lea eax, [ebp - 0x248]
push eax
call fcn.00412025
pop ecx
mov dword [ebp - 0x254], eax
cmp dword [ebp - 0x254], 0
jne 0x4085c4
and dword [ebp - 0x368], 0
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x2c]
call fcn.00405812
mov eax, dword [ebp - 0x368]
jmp 0x4087b5
mov esi, esp
push dword [ebp - 0x254]
push 0
push 0x400
call dword [sym.imp.KERNEL32.dll_OpenProcess]
cmp esi, esp
call fcn.00414070
mov dword [ebp - 0x260], eax
cmp dword [ebp - 0x260], 0
je 0x408796
and dword [ebp - 0x26c], 0
mov esi, esp
lea eax, [ebp - 0x26c]
push eax
push 8
push dword [ebp - 0x260]
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
cmp esi, esp
call fcn.00414070
test eax, eax
je 0x40877b
and dword [ebp - 0x278], 0
and dword [ebp - 0x284], 0
mov esi, esp
lea eax, [ebp - 0x284]
push eax
push 0
push dword [ebp - 0x278]
push 1
push dword [ebp - 0x26c]
call dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
cmp esi, esp
call fcn.00414070
test eax, eax
jne 0x408760
mov esi, esp
push dword [ebp - 0x284]
push 8
mov edi, esp
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
cmp edi, esp
call fcn.00414070
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
cmp esi, esp
call fcn.00414070
mov dword [ebp - 0x278], eax
cmp dword [ebp - 0x278], 0
je 0x40875a
mov esi, esp
lea eax, [ebp - 0x284]
push eax
push dword [ebp - 0x284]
push dword [ebp - 0x278]
push 1
push dword [ebp - 0x26c]
call dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
cmp esi, esp
call fcn.00414070
test eax, eax
je 0x40872d
lea eax, [ebp - 0x290]
push eax
mov eax, dword [ebp - 0x278]
push dword [eax]
call sub.ADVAPI32.dll_ConvertSidToStringSidW
test eax, eax
je 0x408712
push dword [ebp - 0x290]
lea ecx, [ebp - 0x2c]
call fcn.0040cae5
push 0x416c18
lea ecx, [ebp - 0x2c]
call fcn.0040cae5
push dword [ebp - 0x290]
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.0040b021
test eax, eax
je 0x408710
and dword [ebp - 0x38], 0
jmp 0x408716
and dword [ebp - 0x38], 0
mov esi, esp
push dword [ebp - 0x290]
call dword [sym.imp.KERNEL32.dll_LocalFree]
cmp esi, esp
call fcn.00414070
jmp 0x408731
and dword [ebp - 0x38], 0
mov esi, esp
push dword [ebp - 0x278]
push 0
mov edi, esp
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
cmp edi, esp
call fcn.00414070
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
cmp esi, esp
call fcn.00414070
jmp 0x40875e
and dword [ebp - 0x38], 0
jmp 0x408764
and dword [ebp - 0x38], 0
mov esi, esp
push dword [ebp - 0x26c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp esi, esp
call fcn.00414070
jmp 0x40877f
and dword [ebp - 0x38], 0
mov esi, esp
push dword [ebp - 0x260]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp esi, esp
call fcn.00414070
jmp 0x40879a
and dword [ebp - 0x38], 0
mov eax, dword [ebp - 0x38]
mov dword [ebp - 0x35c], eax
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x2c]
call fcn.00405812
mov eax, dword [ebp - 0x35c]
push edx
mov ecx, ebp
push eax
lea edx, [0x4087f0]
call fcn.00414018
pop eax
pop edx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00414093
add esp, 0x384
cmp ebp, esp
call fcn.00414070
mov esp, ebp
pop ebp
ret