Function at 0x418a88
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x27c
mov edi, dword [ebp + 0xc]
mov dword [ebp - 0x10], 0xf
mov dword [ebp - 0x14], 0
mov byte [ebp - 0x24], 0
sub esp, 4
lea eax, [ebp - 0x280]
push 0x208
push 0
push eax
call fcn.0044c927
add esp, 0x10
mov ebx, dword [edi + 0x14]
cmp ebx, 2
mov dword [ebp - 0x2c], ebx
jb 0x418ad2
mov ebx, 2
lea esi, [edi + 4]
mov dword [ebp - 0x5c], 0x45d7f8
mov dword [ebp - 0x58], 0x463d84
mov dword [ebp - 0x54], ebp
mov dword [ebp - 0x4c], esp
mov dword [ebp - 0x54], 0x418fb8
lea eax, [ebp - 0x78]
call fcn.0045e461
test ebx, ebx
je 0x418b06
cmp dword [edi + 0x18], 0xf
ja 0x418b0d
mov eax, esi
jmp 0x418b10
xor edx, edx
mov edi, dword [ebp - 0x2c]
jmp 0x418b39
mov eax, dword [edi + 4]
mov edi, dword [ebp - 0x2c]
xor ecx, ecx
nop dword [eax]
movzx edx, byte [ecx + 0x463b5e]
cmp byte [eax + ecx], dl
jne 0x418b2d
inc ecx
cmp ebx, ecx
jne 0x418b18
xor edx, edx
jmp 0x418b39
mov edx, 0xffffffff
jl 0x418b39
mov edx, 1
cmp edx, 1
sbb ecx, ecx
or ecx, edx
xor eax, eax
cmp edi, 2
setne al
test edx, edx
mov edx, ecx
jne 0x418c0e
mov edx, eax
cmp edi, 2
jae 0x418c17
test ecx, ecx
je 0x418c21
test ebx, ebx
je 0x418b8d
mov ecx, dword [ebp + 0xc]
cmp dword [ecx + 0x18], 0xf
jbe 0x418b75
mov esi, dword [ecx + 4]
xor ecx, ecx
nop
movzx edx, byte [ecx + 0x463b61]
cmp byte [esi + ecx], dl
jne 0x418d9a
inc ecx
cmp ebx, ecx
jne 0x418b78
xor ecx, ecx
mov esi, dword [ebp + 8]
cmp ecx, 1
sbb edx, edx
or edx, ecx
test ecx, ecx
mov ecx, edx
jne 0x418cd6
mov ecx, eax
cmp edi, 2
jae 0x418cdf
test edx, edx
je 0x418ce9
mov dword [esi + 0x18], 0xf
mov dword [esi + 0x14], 0
mov byte [esi + 4], 0
mov dword [ebp - 0x70], 1
push 0xffffffffffffffff
push 0
push dword [ebp + 0xc]
push esi
call fcn.0040ea5c
add esp, 0x10
mov ecx, dword [ebp - 0x10]
cmp ecx, 0x10
mov ebx, dword [ebp + 8]
jb 0x418f39
mov eax, dword [ebp - 0x24]
inc ecx
cmp ecx, 0x1000
jb 0x418bfd
mov eax, dword [eax - 4]
sub esp, 0xc
push eax
call fcn.004406b8
add esp, 0x10
jmp 0x418f39
cmp edi, 2
jb 0x418b5d
mov ecx, edx
test ecx, ecx
jne 0x418b65
mov dword [ebp - 0x70], 2
sub esp, 0xc
lea eax, [ebp - 0x280]
push eax
push 0
push 0
push 0x1a
push 0
call sub.SHELL32.DLL_SHGetFolderPathW
add esp, 0xc
test eax, eax
js 0x418ed0
mov dword [ebp - 0x70], 3
push 0
push 0
push 0
push 0
push 0xffffffffffffffff
lea eax, [ebp - 0x280]
push eax
push 0
push 0xfde9
call sub.KERNEL32.DLL_WideCharToMultiByte
mov esi, eax
test esi, esi
jle 0x418ed0
mov eax, dword [ebp - 0x14]
mov ecx, esi
sub ecx, eax
jbe 0x418db2
not eax
cmp ecx, eax
jae 0x418f8a
test ecx, ecx
je 0x418ded
mov dword [ebp - 0x30], ecx
mov dword [ebp - 0x70], 5
sub esp, 4
lea eax, [ebp - 0x28]
push 0
push esi
push eax
mov dword [ebp - 0x2c], esi
call fcn.00402750
mov esi, dword [ebp - 0x2c]
add esp, 0x10
test al, al
mov ecx, dword [ebp - 0x30]
je 0x418ded
cmp dword [ebp - 0x10], 0xf
ja 0x418dcf
lea eax, [ebp - 0x24]
jmp 0x418dd2
cmp edi, 2
jb 0x418bae
mov edx, ecx
test edx, edx
jne 0x418bb6
mov dword [ebp - 0x70], 8
sub esp, 0xc
lea eax, [ebp - 0x280]
push eax
push 0
push 0
push 0
push 0
call sub.SHELL32.DLL_SHGetFolderPathW
add esp, 0xc
test eax, eax
js 0x418ed0
mov dword [ebp - 0x70], 9
push 0
push 0
push 0
push 0
push 0xffffffffffffffff
lea eax, [ebp - 0x280]
push eax
push 0
push 0xfde9
call sub.KERNEL32.DLL_WideCharToMultiByte
mov esi, eax
test esi, esi
jle 0x418ed0
mov eax, dword [ebp - 0x14]
mov ecx, esi
sub ecx, eax
jbe 0x418dbd
not eax
cmp ecx, eax
jae 0x418fa1
test ecx, ecx
je 0x418e7f
mov dword [ebp - 0x30], ecx
mov dword [ebp - 0x70], 0xb
sub esp, 4
lea eax, [ebp - 0x28]
push 0
push esi
push eax
mov dword [ebp - 0x2c], esi
call fcn.00402750
mov esi, dword [ebp - 0x2c]
add esp, 0x10
test al, al
mov ecx, dword [ebp - 0x30]
je 0x418e7f
cmp dword [ebp - 0x10], 0xf
ja 0x418e59
lea eax, [ebp - 0x24]
jmp 0x418e5c
mov ecx, 0xffffffff
mov esi, dword [ebp + 8]
jl 0x418b92
mov ecx, 1
jmp 0x418b92
cmp dword [ebp - 0x10], 0xf
ja 0x418de3
lea eax, [ebp - 0x24]
jmp 0x418de6
cmp dword [ebp - 0x10], 0xf
ja 0x418e75
lea eax, [ebp - 0x24]
jmp 0x418e78
mov eax, dword [ebp - 0x24]
add eax, dword [ebp - 0x14]
cmp ecx, 1
jne 0x418e3f
mov byte [eax], 0
cmp dword [ebp - 0x10], 0xf
jbe 0x418db8
mov eax, dword [ebp - 0x24]
mov dword [ebp - 0x14], esi
mov byte [eax + esi], 0
cmp dword [ebp - 0x10], 0xf
ja 0x418df8
lea eax, [ebp - 0x24]
jmp 0x418dfb
mov eax, dword [ebp - 0x24]
mov dword [ebp - 0x70], 6
push 0
push 0
push esi
push eax
push 0xffffffffffffffff
lea eax, [ebp - 0x280]
push eax
push 0
push 0xfde9
call sub.KERNEL32.DLL_WideCharToMultiByte
mov eax, dword [ebp - 0x14]
test eax, eax
jne 0x418eba
mov dword [ebp - 0x70], 7
sub esp, 0xc
push 0x463b7c
call fcn.00446084
add esp, 0xc
sub esp, 4
push ecx
push 0
push eax
call fcn.0044c927
add esp, 0x10
cmp dword [ebp - 0x10], 0xf
ja 0x418de3
jmp 0x418db8
mov eax, dword [ebp - 0x24]
add eax, dword [ebp - 0x14]
cmp ecx, 1
jne 0x418f55
mov byte [eax], 0
cmp dword [ebp - 0x10], 0xf
jbe 0x418dc7
mov eax, dword [ebp - 0x24]
mov dword [ebp - 0x14], esi
mov byte [eax + esi], 0
cmp dword [ebp - 0x10], 0xf
ja 0x418e8a
lea eax, [ebp - 0x24]
jmp 0x418e8d
mov eax, dword [ebp - 0x24]
mov dword [ebp - 0x70], 0xc
push 0
push 0
push esi
push eax
push 0xffffffffffffffff
lea eax, [ebp - 0x280]
push eax
push 0
push 0xfde9
call sub.KERNEL32.DLL_WideCharToMultiByte
mov eax, dword [ebp - 0x14]
test eax, eax
je 0x418f73
dec eax
cmp dword [ebp - 0x10], 0xf
ja 0x418ec6
lea ecx, [ebp - 0x24]
jmp 0x418ec9
mov ecx, dword [ebp - 0x24]
mov dword [ebp - 0x14], eax
mov byte [ecx + eax], 0
mov ebx, dword [ebp + 8]
mov dword [ebx + 0x18], 0xf
lea eax, [ebx + 4]
mov dword [ebx + 0x14], 0
mov byte [ebx + 4], 0
mov esi, dword [ebp - 0x10]
cmp esi, 0xf
ja 0x418f0b
mov edi, dword [ebp - 0x14]
mov ecx, edi
inc ecx
je 0x418f1c
sub esp, 4
push ecx
lea ecx, [ebp - 0x24]
push ecx
push eax
call fcn.0044c75c
add esp, 0x10
jmp 0x418f21
mov ecx, dword [ebp - 0x24]
mov dword [eax], ecx
mov dword [ebp - 0x24], 0
mov edi, dword [ebp - 0x14]
jmp 0x418f21
mov edi, 0xffffffff
mov dword [ebx + 0x14], edi
mov dword [ebx + 0x18], esi
mov dword [ebp - 0x10], 0xf
mov dword [ebp - 0x14], 0
mov byte [ebp - 0x24], 0
sub esp, 0xc
lea eax, [ebp - 0x78]
push eax
call fcn.0045e482
add esp, 0x10
mov eax, ebx
add esp, 0x27c
pop esi
pop edi
pop ebx
pop ebp
ret
sub esp, 4
push ecx
push 0
push eax
call fcn.0044c927
add esp, 0x10
cmp dword [ebp - 0x10], 0xf
ja 0x418e75
jmp 0x418dc7
mov dword [ebp - 0x70], 0xd
sub esp, 0xc
push 0x463b7c
call fcn.00446084
add esp, 0xc
mov dword [ebp - 0x70], 4
sub esp, 0xc
push 0x463b7c
call fcn.00446084
add esp, 0xc
mov dword [ebp - 0x70], 0xa
sub esp, 0xc
push 0x463b7c
call fcn.00446084
add esp, 0xc
mov eax, dword [ebp - 0x74]
cmp eax, 0xd
jbe 0x418fc4
ud2
sub eax, 1
jmp dword [eax*4 + 0x419030]
jmp case.0x418fc9.8
jmp case.0x418fc9.8
mov eax, dword [ebp - 0x6c]
mov ecx, dword [ebp - 0x68]
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x3c], ecx
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 0x34]
cmp eax, 0x10
jb 0x419014
mov eax, dword [ebp - 0x24]
mov dword [ebp - 0x38], eax
mov eax, dword [ebp - 0x34]
inc eax
cmp eax, 0x1000
mov eax, dword [ebp - 0x38]
jb 0x419008
mov eax, dword [ebp - 0x38]
mov eax, dword [eax - 4]
sub esp, 0xc
push eax
call fcn.004406b8
add esp, 0x10
mov eax, dword [ebp - 0x40]
mov ecx, dword [ebp - 0x3c]
mov dword [ebp - 0x70], 0xffffffff
sub esp, 0xc
push eax
call fcn.0045e400
add esp, 0xc
nop dword [eax]
ror byte [edi - 0x702fffbf], 1
inc ecx
add dl, dl
pop dword [ecx]
ror byte [edi - 0x702dffbf], cl
inc ecx
add dl, dl
pop dword [ecx]
ror byte [edi - 0x702fffbf], cl
inc ecx
add ah, dl
pop dword [ecx]
aam 0x8f
inc ecx
add ah, dl
pop dword [ecx]
aam 0x8f
inc ecx
add ah, dl
pop dword [ecx]