Function at 0x4066e3
Capabilities:
Get common file path

Disassembly:
mov eax, dword [esp + 8]
sub esp, 0x1c
test eax, eax
jns 0x4066ff
mov ecx, dword [0x443000]
lea eax, [eax*4 + 4]
sub ecx, eax
mov eax, dword [ecx]
push ebx
mov ebx, dword [esp + 0x24]
mov edx, 0x43efc0
push ebp
mov ebp, dword [0x447058]
push edi
mov edi, edx
lea ecx, [eax + ebp]
cmp ebx, edx
jb 0x40672d
mov eax, ebx
sub eax, edx
cmp eax, 0x4000
jae 0x40672d
mov edi, ebx
xor ebx, ebx
mov dword [esp + 0x2c], ebx
cmp byte [ecx], 0
je 0x406950
push esi
mov eax, edi
mov ebx, ecx
sub eax, edx
mov dword [esp + 0x18], ebx
cmp eax, 0x2000
jge 0x40694b
mov dl, byte [ecx]
cmp dl, 4
jae 0x406920
movsx ebx, byte [ebx + 2]
movsx ecx, byte [ecx + 1]
mov esi, ebx
and esi, 0x7f
mov dword [esp + 0x34], ebx
mov eax, ecx
shl esi, 7
and eax, 0x7f
mov dword [esp + 0x20], ecx
or esi, eax
mov dword [esp + 0x28], ebx
mov eax, ecx
or eax, 0x8000
mov dword [esp + 0x1c], eax
mov eax, ebx
or eax, 0x8000
mov dword [esp + 0x24], eax
cmp dl, 2
jne 0x4068c7
cmp byte [0x44711c], 0
jne 0x4067be
mov eax, 0x45a
cmp word [0x44711e], ax
jae 0x4067be
cmp ebx, 0x23
je 0x4067be
cmp ebx, 0x2e
je 0x4067be
xor edx, edx
jmp 0x4067c1
xor edx, edx
inc edx
cmp dword [0x4470e4], 0
push 2
pop ebx
push 4
pop eax
cmovne ebx, eax
mov dword [esp + 0x10], edx
test cl, cl
jns 0x40680e
mov eax, ecx
and ecx, 0x3f
and eax, 0x40
add ecx, ebp
push eax
push edi
push ecx
push str.SoftwareMicrosoftWindowsCurrentVersion
push 0x80000002
call fcn.004073cc
cmp byte [edi], 0
mov esi, dword [esp + 0x34]
jne 0x4068b4
push esi
push edi
call fcn.004066e3
jmp 0x4068af
cmp ecx, 0x25
jne 0x406824
push 0x2000
push edi
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
jmp 0x4068ab
cmp ecx, 0x24
jne 0x406837
push 0x2000
push edi
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
jmp 0x4068ab
mov eax, dword [esp + ebx*4 + 0x18]
dec ebx
mov ecx, dword [0x443010]
and eax, 0xffffffbf
mov esi, eax
mov dword [esp + 0x14], eax
and esi, 0x8000
test ecx, ecx
je 0x40686b
test edx, edx
je 0x40686b
push edi
push 0
push 0
push eax
push dword [0x443018]
call ecx
test eax, eax
je 0x4068ab
push 7
call fcn.0040733b
mov ecx, eax
mov eax, dword [esp + 0x14]
push esi
movzx eax, al
push eax
push dword [0x443018]
call ecx
mov ebp, eax
test ebp, ebp
je 0x4068a0
push edi
push ebp
call dword [sym.imp.SHELL32.dll_SHGetPathFromIDListA]
push ebp
mov esi, eax
call dword [sym.imp.ole32.dll_CoTaskMemFree]
test esi, esi
jne 0x4068ab
mov edx, dword [esp + 0x10]
mov byte [edi], 0
test ebx, ebx
jne 0x406837
mov esi, dword [esp + 0x34]
cmp byte [edi], 0
je 0x4068f8
cmp esi, 0x1a
jne 0x4068f8
push str.MicrosoftInternet_ExplorerQuick_Launch
push edi
call dword [sym.imp.KERNEL32.dll_lstrcatA]
jmp 0x4068f8
cmp dl, 3
jne 0x406900
cmp esi, 0x1d
jne 0x4068df
push dword [0x443018]
push edi
call fcn.00406f3f
jmp 0x40690e
mov eax, esi
shl eax, 0xd
add eax, section..ndata
push eax
push edi
call fcn.00407560
lea eax, [esi - 0x15]
cmp eax, 7
jae 0x40690e
push edi
call fcn.00407782
jmp 0x40690e
cmp dl, 1
jne 0x40690e
not esi
push esi
push edi
call fcn.004066e3
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov ebx, dword [esp + 0x18]
add edi, eax
push 3
pop eax
jmp 0x406933
jne 0x40692d
mov al, byte [ecx + 1]
mov byte [edi], al
inc edi
push 2
pop eax
jmp 0x406933
mov byte [edi], dl
xor eax, eax
inc edi
inc eax
lea ecx, [ebx + eax]
mov edx, 0x43efc0
cmp byte [ecx], 0
je 0x40694b
mov ebp, dword [0x447058]
jmp 0x406737
mov ebx, dword [esp + 0x30]
pop esi
mov byte [edi], 0
test ebx, ebx
je 0x406960
push edx
push ebx
call fcn.00407560
jmp 0x406962
mov eax, edx
pop edi
pop ebp
pop ebx
add esp, 0x1c
ret 8