Function at 0x4081e2
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x5c
mov esi, dword [ebp + 0xc]
test esi, esi
jns 0x4081fe
inc esi
imul esi, esi, 0xfffffffc
add esi, dword [0x42cce4]
mov esi, dword [esi]
add esi, dword [0x42c458]
mov ebx, 0x42cd00
cmp dword [ebp + 8], ebx
jb 0x408258
mov eax, dword [ebp + 8]
sub eax, ebx
cmp eax, 0x7ff
ja 0x408258
mov ebx, dword [ebp + 8]
mov dword [ebp + 8], 0
jmp 0x408258
mov eax, edi
mov dword [esp], ebx
sub edi, 0x15
shl eax, 0xa
add eax, section..ndata
mov dword [esp + 4], eax
call fcn.004080a0
push eax
push eax
cmp edi, 6
jbe 0x408468
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push ecx
add eax, ebx
mov ebx, eax
mov dl, byte [esi]
test dl, dl
je 0x4084b0
mov eax, ebx
sub eax, 0x42cd00
cmp eax, 0x3ff
jg 0x4084b0
cmp dl, 3
ja 0x408493
movsx eax, byte [esi + 2]
movsx ecx, byte [esi + 1]
add esi, 3
mov dword [ebp - 0x3c], eax
mov edi, dword [ebp - 0x3c]
mov eax, ecx
mov dword [ebp - 0x40], ecx
and ecx, 0x7f
shl edi, 7
and edi, 0x3f80
or edi, ecx
movsx ecx, al
or ch, 0x80
mov dword [ebp - 0x28], ecx
movsx ecx, al
mov dword [ebp - 0x24], ecx
mov ecx, dword [ebp - 0x3c]
or ch, 0x80
mov dword [ebp - 0x20], ecx
mov ecx, dword [ebp - 0x3c]
mov dword [ebp - 0x1c], ecx
cmp dl, 2
jne 0x408447
mov edx, dword [0x42c4a0]
mov dword [ebp - 0x44], 1
test edx, edx
jns 0x4082f4
cmp dx, 0x5a04
je 0x4082f4
cmp ecx, 0x23
sete dl
cmp ecx, 0x2e
sete cl
or edx, ecx
movzx ecx, dl
mov dword [ebp - 0x44], ecx
cmp dword [0x42c3e4], 1
sbb edi, edi
and edi, 0xfffffffe
add edi, 4
test al, al
jns 0x408355
mov edx, eax
and eax, 0x3f
mov dword [esp + 0xc], ebx
xor edi, edi
and edx, 0x40
add eax, dword [0x42c458]
mov dword [esp + 4], str.SoftwareMicrosoftWindowsCurrentVersion
movsx edx, dl
mov dword [esp + 8], eax
mov dword [esp + 0x10], edx
mov dword [esp], 0x80000002
call fcn.00407f1b
sub esp, 0x14
cmp byte [ebx], 0
jne 0x4083bb
mov eax, dword [ebp - 0x3c]
mov dword [esp], ebx
mov dword [esp + 4], eax
call fcn.004081e2
push eax
push eax
jmp 0x4083bb
cmp dword [ebp - 0x40], 0x25
jne 0x40836e
mov dword [esp], ebx
mov dword [esp + 4], 0x400
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
jmp 0x408385
cmp dword [ebp - 0x40], 0x24
jne 0x4083bb
mov dword [esp + 4], 0x400
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
push edi
push edi
xor edi, edi
jmp 0x4083bb
mov eax, dword [0x42c4a4]
mov edx, dword [ebp + edi*4 - 0x28]
test eax, eax
jne 0x4083c3
lea eax, [ebp - 0x2c]
mov dword [esp + 4], edx
mov dword [esp + 8], eax
mov eax, dword [0x42c4a8]
mov dword [esp], eax
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderLocation]
sub esp, 0xc
test eax, eax
je 0x408418
mov byte [ebx], 0
dec edi
cmp edi, 0xffffffff
jne 0x40838b
jmp 0x4083f9
cmp dword [ebp - 0x44], 0
je 0x408398
mov ecx, dword [0x42c4a8]
mov dword [esp + 4], edx
mov dword [ebp - 0x40], edx
mov dword [esp + 0x10], ebx
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp], ecx
call eax
mov edx, dword [ebp - 0x40]
sub esp, 0x14
test eax, eax
jne 0x408398
cmp byte [ebx], 0
je 0x408468
cmp dword [ebp - 0x3c], 0x1a
jne 0x408468
mov dword [esp + 4], str.MicrosoftInternet_ExplorerQuick_Launch
mov dword [esp], ebx
call sub.KERNEL32.dll_lstrcatA
push eax
push eax
jmp 0x408468
mov eax, dword [ebp - 0x2c]
mov dword [esp + 4], ebx
mov dword [esp], eax
call dword [sym.imp.SHELL32.dll_SHGetPathFromIDListA]
push edx
push edx
mov edx, dword [ebp - 0x2c]
mov dword [ebp - 0x40], eax
mov dword [esp], edx
call dword [sym.imp.ole32.dll_CoTaskMemFree]
mov eax, dword [ebp - 0x40]
push ecx
test eax, eax
je 0x4083b8
jmp 0x4083f9
cmp dl, 3
jne 0x408476
cmp edi, 0x1d
jne 0x408226
mov eax, dword [0x42c4a8]
mov dword [esp], ebx
mov dword [esp + 4], eax
call fcn.00407fc3
jmp 0x40848c
mov dword [esp], ebx
call fcn.00408119
push eax
jmp 0x40824a
dec dl
jne 0x40824a
not edi
mov dword [esp], ebx
mov dword [esp + 4], edi
call fcn.004081e2
push edi
push edi
jmp 0x40824a
lea eax, [ebx + 1]
cmp dl, 4
jne 0x4084a8
mov dl, byte [esi + 1]
add esi, 2
mov byte [ebx], dl
jmp 0x408256
mov byte [ebx], dl
inc esi
jmp 0x408256
cmp dword [ebp + 8], 0
mov byte [ebx], 0
mov eax, 0x42cd00
je 0x4084cf
mov dword [esp + 4], eax
mov eax, dword [ebp + 8]
mov dword [esp], eax
call fcn.004080a0
push edx
push edx
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret 8