Function at 0x4062f1
Capabilities:
Get common file path

Disassembly:
sub esp, 0x24
mov eax, dword [0x40b0cc]
xor eax, esp
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x2c]
push ebx
mov ebx, dword [esp + 0x2c]
mov dword [esp + 4], ebx
test eax, eax
jns 0x406321
mov ecx, dword [0x465040]
lea eax, [eax*4 + 4]
sub ecx, eax
mov eax, dword [ecx]
mov ecx, dword [0x46d098]
mov edx, 0x45d000
push ebp
push edi
mov edi, edx
lea ebp, [ecx + eax*2]
xor ecx, ecx
cmp ebx, edx
jb 0x40634e
mov eax, ebx
sub eax, edx
sar eax, 1
cmp eax, 0x4000
jae 0x40634e
mov edi, ebx
mov dword [esp + 0xc], ecx
mov ebx, ecx
movzx ecx, word [ebp]
test cx, cx
je 0x406576
push esi
push 2
pop esi
mov eax, edi
mov ebx, ebp
sub eax, edx
and eax, 0xfffffffe
cmp eax, 0x4000
jge 0x406571
push 4
movzx edx, cx
add ebp, esi
pop eax
cmp dx, ax
jae 0x40654a
movsx esi, byte [ebx + 3]
movsx eax, byte [ebp]
and esi, 0x7f
movzx ecx, byte [ebp]
and eax, 0x7f
shl esi, 7
or esi, eax
mov dword [esp + 0x24], ecx
mov eax, ecx
or eax, 0x8000
mov dword [esp + 0x20], eax
movzx eax, byte [ebp + 1]
lea ebp, [ebx + 4]
mov dword [esp + 0x2c], eax
or eax, 0x8000
push 2
mov dword [esp + 0x2c], eax
pop eax
mov dword [esp + 0x1c], ebp
cmp dx, ax
jne 0x4064f5
cmp dword [0x46d124], 0
push 4
pop ebx
cmovne eax, ebx
test cl, cl
jns 0x40641d
mov ebx, dword [0x46d098]
mov eax, ecx
and eax, 0x40
and ecx, 0x3f
push eax
push edi
lea eax, [ebx + ecx*2]
push eax
push str.SoftwareMicrosoftWindowsCurrentVersion
push 0x80000002
call fcn.00406e60
xor esi, esi
cmp word [edi], si
mov esi, dword [esp + 0x2c]
jne 0x4064db
push esi
push edi
call fcn.004062f1
jmp 0x4064db
cmp ecx, 0x25
jne 0x406433
push 0x2000
push edi
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
jmp 0x4064d7
cmp ecx, 0x24
jne 0x406449
push 0x2000
push edi
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
jmp 0x4064d7
xor ebp, ebp
mov esi, dword [0x465050]
dec eax
mov dword [esp + 0x18], eax
mov eax, dword [esp + eax*4 + 0x20]
and eax, 0xffffffbf
mov ebx, eax
mov dword [esp + 0x14], eax
and ebx, 0x8000
test esi, esi
je 0x406485
push edi
push ebp
push ebp
push eax
push dword [0x465058]
mov ecx, esi
call dword [0x4092c8]
call esi
test eax, eax
je 0x4064d3
push 7
call fcn.00406dcf
mov esi, eax
mov eax, dword [esp + 0x14]
push ebx
movzx eax, al
mov ecx, esi
push eax
push dword [0x465058]
call dword [0x4092c8]
call esi
mov ebx, eax
test ebx, ebx
je 0x4064c2
push edi
push ebx
call dword [sym.imp.SHELL32.dll_SHGetPathFromIDListW]
push ebx
mov esi, eax
call dword [sym.imp.ole32.dll_CoTaskMemFree]
test esi, esi
jne 0x4064d3
xor eax, eax
mov word [edi], ax
mov eax, dword [esp + 0x18]
test eax, eax
jne 0x40644b
mov ebp, dword [esp + 0x1c]
mov esi, dword [esp + 0x2c]
xor eax, eax
cmp word [edi], ax
je 0x406526
cmp esi, 0x1a
jne 0x406526
push str.MicrosoftInternet_ExplorerQuick_Launch
push edi
call dword [sym.imp.KERNEL32.dll_lstrcatW]
jmp 0x406526
cmp edx, 3
jne 0x40652e
cmp esi, 0x1d
jne 0x40650d
push dword [0x465058]
push edi
call fcn.00406ae0
jmp 0x40653c
mov eax, esi
shl eax, 0xe
add eax, section..ndata
push eax
push edi
call fcn.0040701f
lea eax, [esi - 0x15]
cmp eax, 7
jae 0x40653c
push edi
call fcn.00407230
jmp 0x40653c
cmp edx, 1
jne 0x40653c
not esi
push esi
push edi
call fcn.004062f1
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push 2
add eax, eax
pop esi
jmp 0x40655d
jne 0x406558
mov ax, word [ebp]
lea ebp, [ebx + 4]
mov word [edi], ax
jmp 0x40655b
mov word [edi], dx
mov eax, esi
movzx ecx, word [ebp]
add edi, eax
mov edx, 0x45d000
test cx, cx
jne 0x40635f
mov ebx, dword [esp + 0x10]
pop esi
xor eax, eax
mov word [edi], ax
pop edi
pop ebp
test ebx, ebx
je 0x40658a
push edx
push ebx
call fcn.0040701f
jmp 0x40658c
mov eax, edx
mov ecx, dword [esp + 0x24]
pop ebx
xor ecx, esp
call fcn.0040818f
add esp, 0x24
ret 8