Function at 0x405a70
Capabilities:
Get common file path

Disassembly:
push 0x8cc
mov eax, 0x41029d
call fcn.00402b60
push 0x4060b8
call fcn.0040585e
mov eax, dword [0x414594]
mov edi, dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
xor ebx, ebx
pop ecx
xor esi, esi
xor ecx, ecx
inc ebx
mov dword [ebp - 0x63c], esi
mov dword [ebp - 0x650], ecx
test eax, eax
jne 0x405af3
cmp byte [0x414598], cl
jne 0x405aef
push eax
push eax
push 0x40653c
call edi
test eax, eax
je 0x405ad4
push 0x406568
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x414594], eax
jmp 0x405ad9
mov eax, dword [0x414594]
mov byte [0x414598], bl
test eax, eax
jne 0x405af3
mov esi, dword [ebp - 0x63c]
mov ecx, dword [ebp - 0x650]
xor eax, eax
jmp 0x405b14
lea ecx, [ebp - 0x650]
push ecx
lea ecx, [ebp - 0x63c]
push ecx
push ebx
push 0
push 0
call eax
mov esi, dword [ebp - 0x63c]
mov ecx, dword [ebp - 0x650]
test eax, eax
jne 0x405b2f
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x406100
call fcn.0040585e
pop ecx
jmp 0x4060ab
xor eax, eax
test ecx, ecx
je 0x405b52
lea edx, [esi + 8]
cmp dword [edx], 0
je 0x405b47
inc eax
add edx, 0xc
cmp eax, ecx
jae 0x405b52
jmp 0x405b38
imul eax, eax, 0xc
mov eax, dword [eax + esi]
mov dword [0x414174], eax
mov eax, dword [0x4145b4]
test eax, eax
jne 0x405b92
cmp byte [0x41459b], al
jne 0x405b95
push eax
push eax
push 0x40653c
call edi
test eax, eax
je 0x405b83
push 0x406558
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x4145b4], eax
jmp 0x405b88
mov eax, dword [0x4145b4]
mov byte [0x41459b], bl
test eax, eax
je 0x405b95
push esi
call eax
mov eax, dword [0x414174]
xor esi, esi
mov dword [ebp - 0x63c], esi
cmp eax, 0xffffffff
je 0x405baf
push eax
push 0x406178
jmp 0x405c05
push 0x4061b0
call fcn.0040585e
mov eax, dword [0x414038]
pop ecx
mov dword [ebp - 0x64c], eax
mov eax, dword [0x414020]
push 0xffffffffffffffff
mov dword [ebp - 0x648], eax
push esi
lea eax, [ebp - 0x64c]
push eax
push 2
call dword [sym.imp.KERNEL32.dll_WaitForMultipleObjects]
mov ecx, eax
sub ecx, esi
je 0x4060a1
dec ecx
je 0x405bfa
push eax
push 0x406298
jmp 0x405b24
push dword [0x414174]
push 0x406254
call fcn.0040585e
or dword [ebp - 0x658], 0xffffffff
pop ecx
pop ecx
mov dword [ebp - 0x654], esi
mov dword [ebp - 4], 2
lea eax, [ebp - 0x648]
push eax
lea ecx, [ebp - 0x658]
call fcn.0040779b
mov byte [ebp - 4], 3
mov esi, dword [eax]
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov dword [ebp - 0x66c], eax
mov eax, dword [0x4145b0]
test eax, eax
jne 0x405c8a
cmp byte [0x4145b8], al
jne 0x405c84
push eax
push eax
push 0x404038
call edi
test eax, eax
je 0x405c75
push 0x406580
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x4145b0], eax
jmp 0x405c7a
mov eax, dword [0x4145b0]
mov byte [0x4145b8], bl
test eax, eax
jne 0x405c8a
xor esi, esi
mov eax, esi
jmp 0x405c9a
push esi
push 0x2000000
push dword [ebp - 0x66c]
call eax
xor esi, esi
test eax, eax
sete cl
mov byte [ebp - 4], 2
mov eax, dword [ebp - 0x648]
cmp dword [eax], 0xffffffff
je 0x405cb1
mov dword [eax + 4], ebx
test cl, cl
je 0x405ccd
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x406300
call fcn.0040585e
pop ecx
pop ecx
jmp 0x406077
or dword [ebp - 0x644], 0xffffffff
mov dword [ebp - 0x640], esi
mov byte [ebp - 4], 9
lea eax, [ebp - 0x648]
push eax
lea ecx, [ebp - 0x644]
call fcn.0040779b
mov byte [ebp - 4], 0xa
push dword [eax]
push ebx
push ebx
push esi
push 0x2000000
push dword [ebp - 0x658]
call dword [sym.imp.ADVAPI32.dll_DuplicateTokenEx]
mov ecx, eax
neg ecx
sbb cl, cl
inc cl
mov byte [ebp - 4], 9
mov eax, dword [ebp - 0x648]
cmp dword [eax], 0xffffffff
je 0x405d24
mov dword [eax + 4], ebx
test cl, cl
je 0x405d36
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x406360
jmp 0x405d5b
push 4
push 0x414174
push 0xc
push dword [ebp - 0x644]
call dword [sym.imp.ADVAPI32.dll_SetTokenInformation]
test eax, eax
jne 0x405d67
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x4063c8
call fcn.0040585e
pop ecx
pop ecx
jmp 0x40604f
mov edi, 0x104
push edi
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
test eax, eax
je 0x40604f
cmp eax, edi
jae 0x40604f
mov dword [ebp - 0x428], esi
mov dword [ebp - 0x424], esi
mov dword [ebp - 0x420], esi
mov dword [ebp - 0x41c], esi
lea eax, [ebp - 0x418]
mov dword [ebp - 0x41c], eax
mov dword [ebp - 0x424], 0x200
mov byte [ebp - 4], 0x18
mov dword [ebp - 0x428], 2
mov eax, dword [ebp - 0x41c]
xor ecx, ecx
mov word [eax], cx
mov byte [ebp - 4], 0x19
lea eax, [ebp - 0x218]
push eax
lea ecx, [ebp - 0x428]
call fcn.0040b9d7
mov byte [ebp - 4], 0x1a
push 2
pop eax
mov dword [ebp - 0x668], eax
mov dword [ebp - 0x664], eax
mov dword [ebp - 0x660], 0x10
mov dword [ebp - 0x65c], 0x4010c8
mov byte [ebp - 4], 0x1b
push ecx
lea ecx, [ebp - 0x668]
call fcn.0040ba88
mov byte [ebp - 4], 0x1c
lea eax, [ebp - 0x668]
push eax
lea ecx, [ebp - 0x428]
call fcn.0040c15c
neg eax
sbb al, al
inc al
mov dword [ebp - 0x648], eax
mov byte [ebp - 4], 0x1a
test byte [ebp - 0x660], 8
je 0x405e5e
mov ecx, dword [ebp - 0x65c]
call fcn.004010b8
mov eax, dword [ebp - 0x648]
test al, al
je 0x405e6e
push ecx
lea ecx, [ebp - 0x428]
call fcn.004048e1
push 0x406420
lea ecx, [ebp - 0x428]
call fcn.0040481c
lea eax, [ebp - 0x428]
push eax
lea ecx, [ebp - 0x8d8]
call fcn.0040463f
mov byte [ebp - 4], 0x1e
mov ecx, 0x80
lea esi, [ebp - 0x418]
lea edi, [ebp - 0x8c8]
rep movsd dword es:[edi], dword [esi]
mov byte [ebp - 4], 0x1f
push 0x40645c
lea ecx, [ebp - 0x8d8]
call fcn.0040481c
xor eax, eax
mov dword [ebp - 0x638], eax
mov dword [ebp - 0x634], eax
mov dword [ebp - 0x630], eax
mov dword [ebp - 0x62c], eax
lea eax, [ebp - 0x628]
mov dword [ebp - 0x62c], eax
mov dword [ebp - 0x634], 0x200
mov byte [ebp - 4], 0x20
mov dword [ebp - 0x638], 2
mov eax, dword [ebp - 0x62c]
xor ecx, ecx
mov word [eax], cx
mov byte [ebp - 4], 0x22
lea ecx, [ebp - 0x8d8]
call fcn.00404a3f
mov ecx, dword [ebp - 0x8d0]
mov eax, dword [ebp - 0x8d8]
not ecx
and ecx, ebx
shr eax, cl
push eax
push ecx
lea ecx, [ebp - 0x638]
call fcn.004049f7
mov edi, dword [ebp - 0x62c]
lea ecx, [ebp - 0x8d8]
call fcn.0040bb9a
mov esi, dword [ebp - 0x8cc]
lea ecx, [ebp - 0x8d8]
call fcn.00404a3f
mov ecx, dword [ebp - 0x8d0]
push 0xffffffffffffffff
not ecx
push esi
and ecx, ebx
mov eax, dword [ebp - 0x8d8]
shr eax, cl
push eax
push edi
call dword [sym.imp.MSVCR110_CLR0400.dll_wcsncpy_s]
push 0x40
xor esi, esi
lea eax, [ebp - 0x6c4]
push esi
push eax
mov dword [ebp - 0x6c8], 0x44
call sub.MSVCR110_CLR0400.dll_memset
add esp, 0x1c
lea ecx, [ebp - 0x428]
call fcn.0040bb9a
mov edx, dword [ebp - 0x41c]
mov ecx, dword [ebp - 0x644]
lea eax, [ebp - 0x67c]
push eax
lea eax, [ebp - 0x6c8]
push eax
sub esp, 0x18
push edi
call fcn.004079de
test eax, eax
jne 0x405fd6
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x406478
call fcn.0040585e
pop ecx
pop ecx
jmp 0x406007
push dword [ebp - 0x67c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 0x678]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 0x674]
push dword [0x414174]
push 0x4064d0
call fcn.0040585e
add esp, 0xc
mov byte [ebp - 4], 0x1f
test byte [ebp - 0x630], 8
je 0x40601f
mov ecx, dword [ebp - 0x62c]
call fcn.004010b8
mov byte [ebp - 4], 0x1a
test byte [ebp - 0x8d0], 8
je 0x406037
mov ecx, dword [ebp - 0x8cc]
call fcn.004010b8
mov byte [ebp - 4], 9
test byte [ebp - 0x420], 8
je 0x40604f
mov ecx, dword [ebp - 0x41c]
call fcn.004010b8
mov byte [ebp - 4], 2
cmp dword [ebp - 0x640], 0
je 0x406077
cmp dword [ebp - 0x644], 0
je 0x406071
push dword [ebp - 0x644]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x640], esi
or dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x654], 0
je 0x4060ac
cmp dword [ebp - 0x658], 0
je 0x406099
push dword [ebp - 0x658]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x654], esi
jmp 0x4060ac
push 0x406200
call fcn.0040585e
pop ecx
call fcn.00402c20
ret