Function at 0x4066a5
Capabilities:
Get common file path

Disassembly:
jo 0x4066c3
lodsd eax, dword [esi]
cmp byte [eax + 0x1c], 0x18
je 0x4066b0
xchg esi, eax
lodsd eax, dword [esi]
mov eax, dword [eax + 8]
push eax
call fcn.004044ec
xchg ebp, eax
push esp
mov dword [0x8bf88b94], eax
inc edi
cmp al, 0x8b
push esp
pop es
js 0x4066ca
xlatb
mov ecx, dword [edx + 0x18]
mov ebx, dword [edx + 0x20]
add ebx, edi
sbb byte [ebx - 0x20fcdfa6], cl
call fcn.004044ec
jecxz 0x4066e7
add edi, dword [ebx - 0x74cb74b7]
dec ecx
mov esi, dword [ebx + ecx*4]
add esi, edi
mov eax, 0x50746547
cmp dword [esi], eax
jne 0x4066d9
int1
mov eax, 0x41636f72
cmp dword [esi + 4], eax
jne 0x4066d9
call fcn.004044ec
and ecx, dword [edi]
xor esi, edx
mov ebx, dword [edx + 0x24]
add ebx, edi
mov cx, word [ebx + ecx*2]
or al, 0x4b
mov ebx, dword [edx + 0x1c]
add ebx, edi
mov eax, dword [ebx + ecx*4]
add eax, edi
push eax
call fcn.004044ec
mov esi, 0xffb0464d
jne 0x406723
push dword [ebp + 4]
push dword [ebp]
call fcn.00404cec
add byte [edx + 0x78a014f], cl
in eax, 0xff
inc dword [eax]
mov cl, byte [edi + 1]
mov al, byte [edi]
mov dl, cl
mov bl, al
and edx, 0x7f
and ebx, 0x7f
shl edx, 7
movzx eax, al
or edx, ebx
mov ebx, eax
mov dword [ebp - 8], edx
mov edx, 0x8000
or ebx, edx
push 2
movzx ecx, cl
mov dword [ebp - 0x18], ebx
pop ebx
mov dword [ebp - 0xc], ecx
or ecx, edx
add edi, ebx
cmp word [ebp + 0xc], bx
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x10], ecx
jne 0x406857
cmp dword [0x4702e4], 0
je 0x406776
push 4
pop ebx
test al, al
jns 0x4067b5
mov ecx, eax
and eax, 0x3f
and ecx, 0x40
push ecx
mov ecx, dword [0x470298]
push esi
lea eax, [ecx + eax*2]
push eax
push str.SoftwareMicrosoftWindowsCurrentVersion
push 0x80000002
call fcn.00406536
cmp word [esi], 0
jne 0x40683e
push dword [ebp - 0xc]
push esi
call fcn.004066a5
jmp 0x406838
cmp eax, 0x25
jne 0x4067c8
push 0x2000
push esi
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
jmp 0x406838
cmp eax, 0x24
jne 0x406834
push 0x2000
push esi
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
xor ebx, ebx
jmp 0x406834
mov eax, dword [0x470264]
dec ebx
test eax, eax
je 0x4067fc
push esi
push 0
push 0
push dword [ebp + ebx*4 - 0x18]
push dword [0x470268]
call eax
test eax, eax
je 0x406838
lea eax, [ebp - 4]
push eax
push dword [ebp + ebx*4 - 0x18]
push dword [0x470268]
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderLocation]
test eax, eax
jne 0x406830
push esi
push dword [ebp - 4]
call dword [sym.imp.SHELL32.dll_SHGetPathFromIDListW]
push dword [ebp - 4]
mov dword [ebp + 0xc], eax
call dword [sym.imp.ole32.dll_CoTaskMemFree]
cmp dword [ebp + 0xc], 0
jne 0x406838
and word [esi], 0
test ebx, ebx
jne 0x4067dd
cmp word [esi], 0
je 0x40684f
cmp dword [ebp - 0xc], 0x1a
jne 0x40684f
push str.MicrosoftInternet_ExplorerQuick_Launch
push esi
call fcn.00406684
push esi
call fcn.004068ef
jmp 0x4068a3
cmp word [ebp + 0xc], 3
jne 0x40688f
mov ebx, dword [ebp - 8]
cmp ebx, 0x1d
jne 0x406874
push dword [0x470268]
push esi
call fcn.004065af
jmp 0x406885
mov eax, ebx
shl eax, 0xe
add eax, section..ndata
push eax
push esi
call fcn.00406668
add ebx, 0xffffffeb
cmp ebx, 7
jae 0x4068a3
jmp 0x40684f
cmp word [ebp + 0xc], 1
jne 0x4068a3
or eax, 0xffffffff
sub eax, dword [ebp - 8]
push eax
push esi
call fcn.004066a5
push esi
call fcn.0040667e
lea esi, [esi + eax*2]
mov eax, 0x460200
jmp 0x4068c6
mov cx, word [edi]
test cx, cx
mov dword [ebp + 0xc], ecx
jne 0x406702
and word [esi], 0
cmp dword [ebp + 8], 0
pop edi
pop esi
pop ebx
je 0x4068eb
push eax
push dword [ebp + 8]
call fcn.00406668
leave
ret 8