Function at 0x401020
Capabilities:
Get common file path
Identify system language via api

Disassembly:
sub esp, 0x30c
mov al, byte [0x412e64]
push esi
push edi
mov byte [esp + 8], al
mov ecx, 0x7c
xor eax, eax
lea edi, [esp + 9]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
call dword [sym.imp.KERNEL32.dll_GetUserDefaultLangID]
cmp ax, 0x804
lea edx, [esp + 0x1fc]
sete cl
push edx
push str..inf
mov byte [0x40ea68], cl
call fcn.00403dd0
add esp, 8
cmp eax, 0xffffffff
jne 0x401092
or ecx, eax
mov edi, str.No_found_.inf_
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, 0x4118e0
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
jmp 0x4011c4
push str.C:WCH.CNCH341SERCH341SER.INF
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
mov edi, 0x40b068
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edx, ecx
mov edi, str.C:WCH.CNCH341SERCH341SER.INF
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x210]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edx, ecx
mov edi, str.C:WCH.CNCH341SERCH341SER.INF
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea eax, [esp + 8]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
push str.C:WCH.CNCH341SERCH341SER.INF
call fcn.004026f0
lea edi, [esp + 0x10]
or ecx, 0xffffffff
xor eax, eax
add esp, 8
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
mov esi, edi
mov edi, 0x4118e0
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call fcn.00403470
cmp al, 1
jne 0x4011c9
push 0x64
push 0x40eb74
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
or ecx, 0xffffffff
mov edi, 0x40eb74
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, 0x4117dc
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.inf_
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edx, ecx
mov edi, 0x4117dc
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.infdrvidx.bin
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edx, ecx
mov edi, 0x40eb74
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [esp + 0x320]
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
test eax, eax
jle 0x4012cf
mov ax, word [esi]
push 0x40b04c
push 0x412e64
mov word [0x412e64], ax
call fcn.00403d00
add esp, 8
test eax, eax
je 0x4012bb
push 0x40b048
push 0x412e64
call fcn.00403d00
add esp, 8
test eax, eax
je 0x4012bb
push 0x40b044
push 0x412e64
call fcn.00403d00
add esp, 8
test eax, eax
je 0x4012bb
push 0x40b040
push 0x412e64
call fcn.00403d00
add esp, 8
test eax, eax
je 0x4012bb
push 0x40b03c
push 0x412e64
call fcn.00403d00
add esp, 8
test eax, eax
je 0x4012a4
push 0x40b038
push 0x412e64
call fcn.00403d00
add esp, 8
test eax, eax
je 0x4012a4
push 0x40b034
push 0x412e64
call fcn.00403d00
add esp, 8
test eax, eax
je 0x4012a4
push 0x40b030
push 0x412e64
call fcn.00403d00
add esp, 8
test eax, eax
jne 0x4012c2
push 2
call fcn.00401ed0
add esp, 4
xor eax, eax
pop edi
pop esi
add esp, 0x30c
ret 0x10
push 0
call fcn.004019d0
pop edi
xor eax, eax
pop esi
add esp, 0x30c
ret 0x10
mov eax, dword [esp + 0x318]
push 0
push 0x401300
push 0
push 0x81
push eax
mov dword [0x40ea6c], eax
call dword [sym.imp.USER32.dll_DialogBoxParamA]
pop edi
pop esi
add esp, 0x30c
ret 0x10