Function at 0x40d9fe
Capabilities:
Get common file path
Get program files directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x7e4
mov eax, dword [0x6ffe74]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x10]
push ebx
push esi
mov esi, dword [ebp + 8]
xor ebx, ebx
push edi
mov edi, dword [ebp + 0xc]
push 0x3e7
mov dword [ebp - 0x7e4], eax
lea eax, [ebp - 0x7d7]
push ebx
push eax
mov dword [ebp - 0x7e0], ecx
mov byte [ebp - 0x7d8], bl
call fcn.006390b0
add esp, 0xc
mov byte [ebp - 0x3f0], bl
lea eax, [ebp - 0x3ef]
push 0x3e7
push ebx
push eax
call fcn.006390b0
add esp, 0xc
push edi
call fcn.00643470
pop ecx
cmp eax, 2
jae 0x40da8b
mov ecx, esi
call fcn.00407120
mov dword [ebp - 0x7dc], eax
test eax, eax
je 0x40daec
mov ecx, eax
call fcn.004055eb
test eax, eax
je 0x40daec
jmp 0x40da91
mov dword [ebp - 0x7dc], edi
lea eax, [ebp - 0x3f0]
mov edx, edi
push eax
call fcn.00407370
neg eax
pop ecx
sbb edi, edi
lea eax, [ebp - 0x3f0]
and edi, eax
jne 0x40dcd6
cmp esi, 0xf
jne 0x40dad0
push dword [ebp - 0x7e4]
push 0x3e8
push eax
call fcn.006494f3
add esp, 0xc
jmp 0x40dcd0
lea eax, [ebp - 0x7d8]
push eax
push ebx
push ebx
push 0x2a
push ebx
call dword [sym.imp.SHELL32.dll_SHGetFolderPathA]
test eax, eax
jns 0x40daf3
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor eax, eax
jmp 0x40dd5d
cmp esi, 3
jne 0x40db0e
push str.Mozilla_Firefox
lea eax, [ebp - 0x7d8]
push eax
push 0x6c643c
jmp 0x40dca9
cmp esi, 0xfd
jne 0x40db1d
push str.Mozilla_Thunderbird
jmp 0x40dafd
cmp esi, 8
jne 0x40db29
push str.SeaMonkey
jmp 0x40dafd
cmp esi, 0x1b
jne 0x40db35
push str.ComodoIceDragon
jmp 0x40dafd
cmp esi, 0x20
jne 0x40db41
push str.Pale_Moon
jmp 0x40dafd
cmp esi, 0x28
jne 0x40db4d
push str.NETGATEBlack_Hawk
jmp 0x40dafd
cmp esi, 0x29
jne 0x40db59
push str.Cyberfox
jmp 0x40dafd
cmp esi, 0x2a
jne 0x40db65
push 0x6c7a28
jmp 0x40dafd
cmp esi, 0x2b
jne 0x40db71
push str.IceCat
jmp 0x40dafd
cmp esi, 0x3c
jne 0x40db7d
push str.SlimBrowser
jmp 0x40dafd
cmp esi, 0x44
jne 0x40db8c
push str.Basilisk
jmp 0x40dafd
cmp esi, 0x4a
jne 0x40db9b
push str.Cliqz
jmp 0x40dafd
cmp esi, 0x4c
jne 0x40dbaa
push str.BitTube_Browser
jmp 0x40dafd
cmp esi, 0x104
jne 0x40dbbc
push str.Postbox
jmp 0x40dafd
cmp esi, 0x10b
jne 0x40dbce
push str.FossaMail
jmp 0x40dafd
cmp esi, 0x74
jne 0x40dbdd
push str.Instantbird
jmp 0x40dafd
cmp esi, 0x5c
jne 0x40dbec
push str.Ablaze_Floorp
jmp 0x40dafd
cmp esi, 0x5e
jne 0x40dbfb
push str.ArtistScope_Web_Browser
jmp 0x40dafd
cmp esi, 0x5f
jne 0x40dc0a
push str.LibreWolf
jmp 0x40dafd
cmp esi, 0x10e
jne 0x40dc1c
push str.Epyrus
jmp 0x40dafd
cmp esi, 0x10f
jne 0x40dc2e
push str.Interlink
jmp 0x40dafd
cmp esi, 0x17
jne 0x40dcbd
push str.Waterfox
lea eax, [ebp - 0x7d8]
mov edi, 0x6c643c
push eax
push edi
lea eax, [ebp - 0x3f0]
push 0x3e8
push eax
call fcn.00402e0a
add esp, 0x14
lea ecx, [ebp - 0x3f0]
call fcn.004055eb
test eax, eax
jne 0x40dcbd
push str.Waterfox_Classic
lea eax, [ebp - 0x7d8]
push eax
push edi
lea eax, [ebp - 0x3f0]
push 0x3e8
push eax
call fcn.00402e0a
add esp, 0x14
lea ecx, [ebp - 0x3f0]
call fcn.004055eb
test eax, eax
jne 0x40dcbd
push str.Waterfox_Current
lea eax, [ebp - 0x7d8]
push eax
push edi
lea eax, [ebp - 0x3f0]
push 0x3e8
push eax
call fcn.00402e0a
add esp, 0x14
lea ecx, [ebp - 0x3f0]
call fcn.004055eb
test eax, eax
je 0x40daec
lea edi, [ebp - 0x3f0]
mov ecx, edi
call fcn.00448565
test eax, eax
je 0x40daec
push edi
mov edi, dword [sym.imp.KERNEL32.dll_SetDllDirectoryA]
mov dword [0x73d944], ebx
call edi
push dword [ebp - 0x7dc]
call dword [0x73d948]
pop ecx
test eax, eax
je 0x40dd0c
call fcn.00447b36
jmp 0x40dd56
push ebx
call edi
mov ecx, 0x6c5bb9
mov dword [0x73d944], 1
call fcn.004486f3
mov edi, dword [ebp - 0x7e0]
test eax, eax
jne 0x40dd40
lea ecx, [edi + 0x1d4]
cmp byte [ecx], bl
je 0x40dd56
call fcn.004486f3
test eax, eax
je 0x40dd56
push dword [ebp + 0x14]
mov ecx, dword [ebp - 0x7dc]
push edi
push esi
call fcn.00448415
xor ebx, ebx
add esp, 0xc
inc ebx
call fcn.00447b36
mov eax, ebx
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.006122f0
leave
ret 0x10