Function at 0x4034e0
Capabilities:
Check if file exists
Get common file path
Get file attributes
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
xor ebx, ebx
mov dword [ebp - 8], ebx
cmp dword [0x43c3e0], ebx
jne 0x403757
push esi
push 0x1000
push ebx
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
mov dword [ebp - 4], esi
test esi, esi
je 0x403748
push edi
push 0
lea eax, [esi + 0x400]
mov byte [esi], 0
push 0x435f14
push 0x80000002
mov dword [ebp - 0x10], eax
lea ebx, [eax + 0x400]
call fcn.00413e50
mov edi, eax
test edi, edi
je 0x40355b
push 0x104
push esi
push str.DirProductBase
push edi
call fcn.004141c0
push edi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push str.K7OemCfg.dat
push esi
push 0x436114
lea edi, [esi + 0x400]
push edi
call dword [sym.imp.USER32.dll_wsprintfA]
xor eax, eax
push 0x224
mov dword [ebp - 0xc], eax
call fcn.00415a0d
mov esi, eax
add esp, 0x14
mov ecx, esi
mov dword [ebp - 0x1c], esi
mov dword [esi], 0x43772c
mov dword [esi + 4], 0
mov byte [esi + 0xc], 0
mov eax, dword [esi]
push 0
push edi
call dword [eax]
cmp eax, 1
je 0x4035de
mov eax, dword [esi + 4]
mov edi, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov dword [esi], 0x43772c
test eax, eax
je 0x4035c8
push eax
push 0
call edi
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
push 0x224
push esi
call fcn.004157ab
mov esi, dword [ebp - 4]
add esp, 8
jmp 0x40372b
push 0x400
push ebx
mov byte [ebx], 0
mov ecx, esi
mov eax, dword [esi]
push str.FontMapPreVista
push str.FontSubstitutes
mov dword [ebp - 0xc], esi
call dword [eax + 0x10]
cmp byte [ebx], 0
je 0x403722
push 0x2c
push ebx
call fcn.00416a00
add esp, 8
test eax, eax
je 0x403722
mov byte [eax], 0
inc eax
push 0x2c
push eax
mov dword [ebp - 0x18], eax
call fcn.00416a00
add esp, 8
test eax, eax
je 0x403722
mov byte [eax], 0
inc eax
push 0x400
push edi
mov dword [ebp - 0x1c], eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
lea ecx, [edi - 1]
mov al, byte [ecx + 1]
lea ecx, [ecx + 1]
test al, al
jne 0x403647
mov eax, dword [str.Fonts_]
mov esi, ebx
mov dword [ecx], eax
mov eax, dword [0x43660c]
mov dword [ecx + 4], eax
mov al, byte [ebx]
inc ebx
test al, al
jne 0x403662
sub ebx, esi
dec edi
nop dword [eax]
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x403670
mov eax, dword [ebp - 0x10]
mov ecx, ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x403722
lea eax, [ebp - 8]
push eax
push 0xf003f
push 0
push str.SOFTWAREMicrosoftWindows_NTCurrentVersionFontSubstitutes
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov esi, dword [ebp - 4]
test eax, eax
jne 0x403725
mov edi, dword [ebp - 0x18]
lea eax, [ebp - 0x14]
push eax
push esi
lea eax, [ebp - 0x20]
mov dword [ebp - 0x14], 0x104
push eax
push 0
push edi
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
je 0x403725
mov edx, dword [ebp - 0x1c]
mov ecx, edx
lea ebx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4036e6
sub ecx, ebx
lea eax, [ecx + 1]
push eax
push edx
push 1
push 0
push edi
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
jne 0x40375e
push eax
push eax
push 0x1d
push 0xffff
call dword [sym.imp.USER32.dll_PostMessageA]
mov edi, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov ebx, 1
jmp 0x40372d
mov esi, dword [ebp - 4]
mov edi, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
xor ebx, ebx
push esi
push 0
call edi
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, dword [ebp - 0xc]
pop edi
test eax, eax
je 0x403748
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0x40]
mov ecx, dword [ebp - 8]
pop esi
test ecx, ecx
je 0x403757
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, ebx
pop ebx
mov esp, ebp
pop ebp
ret
mov edi, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
xor ebx, ebx
jmp 0x40372d