Function at 0x46a950
Capabilities:
Get common file path

Disassembly:
push 0xffffffffffffffff
push 0x6220c5
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x314
mov eax, dword [0x68faac]
push ebx
xor ebx, ebx
push esi
push edi
mov dword [esp + 0x10], ebx
mov dword [esp + 0xc], eax
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x15]
mov byte [esp + 0x14], bl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov dword [esp + 0x328], 1
stosb byte es:[edi], al
call fcn.00476720
test eax, eax
je 0x46aa8e
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x21d]
mov byte [esp + 0x21c], bl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea ecx, [esp + 0x21c]
push 0x104
push ecx
stosb byte es:[edi], al
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
jbe 0x46aa73
lea edx, [esp + 0x14]
test edx, edx
je 0x46aa6c
lea eax, [esp + 0x21c]
test eax, eax
je 0x46aa6c
mov eax, dword [esp + 0x334]
mov esi, 0x7a
cmp eax, ebx
je 0x46aa29
lea ecx, [esp + 0x21c]
push eax
push ecx
push 0x681344
lea edx, [esp + 0x20]
push 0x104
push edx
call fcn.005422a2
add esp, 0x14
xor esi, esi
jmp 0x46aa7b
lea edi, [esp + 0x21c]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp ecx, 0x104
jae 0x46aa7b
lea edi, [esp + 0x21c]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x14]
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
xor esi, esi
jmp 0x46aa7b
mov esi, 0x57
jmp 0x46aa7b
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
cmp esi, ebx
mov dword [0x6b2fb0], esi
je 0x46ab8b
jmp 0x46ab84
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x119]
mov byte [esp + 0x118], bl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea ecx, [esp + 0x118]
push 0x104
push ecx
stosb byte es:[edi], al
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
jbe 0x46ab72
push 0x103
lea edx, [esp + 0x11c]
push 0x6810e4
push edx
call fcn.00435470
lea eax, [esp + 0x20]
add esp, 0xc
test eax, eax
je 0x46ab6b
lea ecx, [esp + 0x118]
test ecx, ecx
je 0x46ab6b
mov eax, dword [esp + 0x334]
mov esi, 0x7a
cmp eax, ebx
je 0x46ab28
lea edx, [esp + 0x118]
push eax
push edx
push 0x681344
lea eax, [esp + 0x20]
push 0x104
push eax
call fcn.005422a2
add esp, 0x14
xor esi, esi
jmp 0x46ab7a
lea edi, [esp + 0x118]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp ecx, 0x104
jae 0x46ab7a
lea edi, [esp + 0x118]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x14]
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
xor esi, esi
jmp 0x46ab7a
mov esi, 0x57
jmp 0x46ab7a
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
cmp esi, ebx
mov dword [0x6b2fb0], esi
je 0x46ab8b
push esi
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
cmp esi, ebx
sete al
cmp eax, ebx
je 0x46aba4
lea ecx, [esp + 0x14]
push ecx
lea ecx, [esp + 0x10]
call fcn.005f01a9
mov esi, dword [esp + 0x330]
lea edx, [esp + 0xc]
push edx
mov ecx, esi
call fcn.005efd95
mov dword [esp + 0x10], 1
lea ecx, [esp + 0xc]
mov byte [esp + 0x328], bl
call fcn.005f0020
mov ecx, dword [esp + 0x320]
mov eax, esi
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
add esp, 0x320
ret