Function at 0x41a7d0
Capabilities:
Check if file exists
Get common file path
Get file attributes
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x450c51
mov eax, dword fs:[0]
push eax
sub esp, 0x378
mov eax, dword [0x468738]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
mov ebx, edx
mov dword [ebp - 0x2d0], ecx
xor ecx, ecx
mov dword [ebp - 0x2d8], ecx
mov esi, 7
xor edx, edx
mov dword [ebx + 0x14], esi
mov dword [ebx + 0x10], ecx
mov dword [ebp - 0x2d4], eax
mov dword [ebp - 0x2cc], ebx
mov word [ebx], dx
mov edx, 1
xor edi, edi
mov dword [ebp - 0x2d8], edx
mov dword [ebp - 0x224], esi
mov dword [ebp - 0x228], ecx
mov word [ebp - 0x238], di
mov dword [ebp - 4], edx
xor edx, edx
mov dword [ebp - 0x240], esi
mov dword [ebp - 0x244], ecx
mov word [ebp - 0x254], dx
mov byte [ebp - 4], 2
mov eax, dword [eax + 0x10]
mov edi, dword [eax]
cmp edi, eax
je 0x41a97a
cmp dword [edi + 0x20], 8
lea esi, [edi + 0xc]
jb 0x41a883
mov eax, dword [esi]
jmp 0x41a885
mov eax, esi
push 0x4585e8
push eax
call fcn.00439375
add esp, 8
test eax, eax
jne 0x41a8dd
push 0x4585e4
call fcn.00402130
test eax, eax
je 0x41a8dd
mov eax, dword [ebp - 0x2d0]
push 0x4585e8
push eax
call fcn.00439375
add esp, 8
test eax, eax
jne 0x41a8dd
mov ecx, 0x4585e4
call fcn.00402200
mov ecx, eax
lea esi, [ecx + 2]
lea esp, [esp]
mov dx, word [ecx]
add ecx, 2
test dx, dx
jne 0x41a8d0
jmp 0x41a91b
cmp dword [esi + 0x14], 8
jb 0x41a8e5
mov esi, dword [esi]
mov ecx, dword [ebp - 0x2d0]
push esi
push ecx
call fcn.00439375
add esp, 8
test eax, eax
jne 0x41a927
cmp dword [edi + 0x3c], 8
lea eax, [edi + 0x28]
jb 0x41a904
mov eax, dword [eax]
mov ecx, eax
lea esi, [ecx + 2]
lea esp, [esp]
mov dx, word [ecx]
add ecx, 2
test dx, dx
jne 0x41a910
sub ecx, esi
sar ecx, 1
push ecx
mov esi, ebx
call fcn.004065a0
cmp byte [edi + 0x45], 0
jne 0x41a969
mov ecx, dword [edi + 8]
cmp byte [ecx + 0x45], 0
jne 0x41a94e
mov eax, dword [ecx]
cmp byte [eax + 0x45], 0
jne 0x41a94a
mov edi, edi
mov ecx, eax
mov eax, dword [ecx]
cmp byte [eax + 0x45], 0
je 0x41a940
mov edi, ecx
jmp 0x41a969
mov eax, dword [edi + 4]
cmp byte [eax + 0x45], 0
jne 0x41a967
cmp edi, dword [eax + 8]
jne 0x41a967
mov edi, eax
mov eax, dword [eax + 4]
cmp byte [eax + 0x45], 0
je 0x41a957
mov edi, eax
mov edx, dword [ebp - 0x2d4]
cmp edi, dword [edx + 0x10]
jne 0x41a876
xor ecx, ecx
cmp dword [ebx + 0x10], ecx
jne 0x41ac99
mov edi, dword [ebp - 0x2d0]
cmp word [edi], 0
mov byte [ebp - 0x2c5], 0
je 0x41a9d7
movzx eax, word [edi]
cmp eax, 0x29
je 0x41a9d7
cmp eax, 0x28
jne 0x41a9ac
mov byte [ebp - 0x2c5], 1
jmp 0x41a9ce
cmp byte [ebp - 0x2c5], 0
mov ebx, eax
lea esi, [ebp - 0x254]
jne 0x41a9c3
lea esi, [ebp - 0x238]
call fcn.00420c20
mov ebx, dword [ebp - 0x2cc]
add edi, 2
cmp word [edi], 0
jne 0x41a996
lea eax, [ebp - 0x238]
call fcn.00436710
mov eax, dword [ebp - 0x228]
push str.source
mov edi, 6
lea ecx, [ebp - 0x238]
call fcn.00404ab0
test eax, eax
jne 0x41aa3c
mov eax, dword [0x46adb8]
add eax, 0xcd0
cmp dword [eax + 0x14], 8
jb 0x41aa13
mov eax, dword [eax]
mov ecx, eax
lea esi, [ecx + 2]
jmp 0x41aa20
mov dx, word [ecx]
add ecx, 2
test dx, dx
jne 0x41aa20
sub ecx, esi
sar ecx, 1
push ecx
mov esi, ebx
call fcn.004065a0
jmp 0x41ac99
mov eax, dword [ebp - 0x228]
push str.setup
mov edi, 5
lea ecx, [ebp - 0x238]
call fcn.00404ab0
test eax, eax
jne 0x41ad09
mov eax, 7
xor edi, edi
xor ecx, ecx
mov dword [ebp - 0x294], eax
mov dword [ebp - 0x298], edi
mov word [ebp - 0x2a8], cx
xor edx, edx
mov dword [ebp - 0x278], eax
mov dword [ebp - 0x27c], edi
mov word [ebp - 0x28c], dx
mov byte [ebp - 4], 4
mov eax, dword [0x46adb8]
add eax, 0xcd0
cmp dword [eax + 0x14], 8
jb 0x41aaa6
mov eax, dword [eax]
mov ecx, eax
lea esi, [ecx + 2]
jmp 0x41aab0
mov dx, word [ecx]
add ecx, 2
cmp dx, di
jne 0x41aab0
sub ecx, esi
sar ecx, 1
push ecx
lea esi, [ebp - 0x2a8]
call fcn.004065a0
push 0x104
push 0x46b3d0
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push 0x46b3d0
call dword [sym.imp.SHLWAPI.dll_PathStripPathW]
mov eax, 0x46b3d0
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x41aaf0
sub eax, edx
sar eax, 1
push eax
mov eax, 0x46b3d0
lea esi, [ebp - 0x28c]
call fcn.004065a0
lea eax, [ebp - 0x2a8]
push eax
lea ecx, [ebp - 0x270]
push ecx
call fcn.00421d90
add esp, 8
mov ecx, eax
mov eax, esi
lea ebx, [ebp - 0x2c4]
mov byte [ebp - 4], 5
call fcn.00421c70
mov byte [ebp - 4], 6
mov ebx, dword [ebp - 0x2cc]
mov edi, eax
mov esi, ebx
call fcn.00404060
cmp dword [ebp - 0x2b0], 8
jb 0x41ab64
mov edx, dword [ebp - 0x2c4]
push edx
call fcn.00438b4b
add esp, 4
xor eax, eax
mov esi, 8
mov byte [ebp - 4], 4
mov dword [ebp - 0x2b0], 7
mov dword [ebp - 0x2b4], 0
mov word [ebp - 0x2c4], ax
cmp dword [ebp - 0x25c], esi
jb 0x41aba1
mov ecx, dword [ebp - 0x270]
push ecx
call fcn.00438b4b
add esp, 4
cmp dword [ebx + 0x14], esi
jb 0x41abaa
mov eax, dword [ebx]
jmp 0x41abac
mov eax, ebx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x41ac43
lea edx, [ebp - 0x2a8]
push edx
lea eax, [ebp - 0x2c4]
push eax
call fcn.00421d90
push eax
mov eax, str.setup.exe
lea ecx, [ebp - 0x270]
mov byte [ebp - 4], 7
call fcn.00421d40
add esp, 0xc
mov edi, eax
mov esi, ebx
mov byte [ebp - 4], 8
call fcn.00404060
lea esi, [ebp - 0x270]
call fcn.0040ff10
lea esi, [ebp - 0x2c4]
mov byte [ebp - 4], 4
call fcn.0040ff10
cmp dword [ebx + 0x14], 8
jb 0x41ac18
mov eax, dword [ebx]
jmp 0x41ac1a
mov eax, ebx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x41ac43
push 0x104
push 0x46b3d0
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push ebx
mov eax, 0x46b3d0
call fcn.00402560
mov esi, 8
cmp dword [ebp - 0x278], esi
jb 0x41ac5f
mov ecx, dword [ebp - 0x28c]
push ecx
call fcn.00438b4b
add esp, 4
xor edx, edx
mov dword [ebp - 0x278], 7
mov dword [ebp - 0x27c], 0
mov word [ebp - 0x28c], dx
cmp dword [ebp - 0x294], esi
jb 0x41ac93
mov eax, dword [ebp - 0x2a8]
push eax
call fcn.00438b4b
add esp, 4
mov ebx, dword [ebp - 0x2cc]
mov esi, 8
cmp dword [ebp - 0x240], esi
jb 0x41acb5
mov edx, dword [ebp - 0x254]
push edx
call fcn.00438b4b
add esp, 4
xor eax, eax
mov dword [ebp - 0x240], 7
mov dword [ebp - 0x244], 0
mov word [ebp - 0x254], ax
cmp dword [ebp - 0x224], esi
jb 0x41ace9
mov ecx, dword [ebp - 0x238]
push ecx
call fcn.00438b4b
add esp, 4
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.004377c1
mov esp, ebp
pop ebp
ret 4
mov eax, dword [ebp - 0x228]
push str.system
mov edi, 6
lea ecx, [ebp - 0x238]
call fcn.00404ab0
test eax, eax
jne 0x41ad82
push 0x104
lea ecx, [ebp - 0x21c]
push ecx
call dword [sym.imp.KERNEL32.dll_GetSystemWow64DirectoryW]
test eax, eax
jne 0x41ad50
push 0x104
lea edx, [ebp - 0x21c]
push edx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
lea eax, [ebp - 0x21c]
lea edx, [eax + 2]
lea esp, [esp]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x41ad60
sub eax, edx
sar eax, 1
push eax
lea eax, [ebp - 0x21c]
mov esi, ebx
call fcn.004065a0
jmp 0x41ac99
mov eax, dword [ebp - 0x228]
push str.system64
mov edi, 8
lea ecx, [ebp - 0x238]
call fcn.00404ab0
test eax, eax
je 0x41b43b
mov esi, str.systemcuros
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
jne 0x41b43b
mov esi, str.windir
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41adf4
push 0x104
lea eax, [ebp - 0x21c]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
push ebx
lea eax, [ebp - 0x21c]
call fcn.00402560
jmp 0x41ac99
mov esi, str.progfilescuros
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41ae4b
call fcn.00430aa0
test al, al
je 0x41ae39
push 0x104
lea ecx, [ebp - 0x21c]
push ecx
push str.ProgramW6432
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
push ebx
lea eax, [ebp - 0x21c]
call fcn.00402560
jmp 0x41ac99
lea edx, [ebp - 0x21c]
push edx
push 0
push 0
push 0x26
jmp 0x41b08c
mov esi, str.progfilesdir
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41ae71
lea eax, [ebp - 0x21c]
push eax
push 0
push 0
push 0x26
jmp 0x41b08c
mov esi, str.progfilesdir64
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41aead
push 0x104
lea ecx, [ebp - 0x21c]
push ecx
push str.ProgramW6432
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
push ebx
lea eax, [ebp - 0x21c]
call fcn.00402560
jmp 0x41ac99
mov esi, str.progdata
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41aed3
lea edx, [ebp - 0x21c]
push edx
push 0
push 0
push 0x23
jmp 0x41b08c
mov esi, str.userdata
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41aef9
lea eax, [ebp - 0x21c]
push eax
push 0
push 0
push 0x1a
jmp 0x41b08c
mov esi, str.langid
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41af6e
lea ecx, [ebp - 0x384]
push ecx
call fcn.00402710
mov byte [ebp - 4], 9
movzx edx, word [0x46aeb8]
push edx
lea eax, [ebp - 0x374]
push eax
call fcn.0041f950
lea ecx, [ebp - 0x270]
lea eax, [ebp - 0x384]
call fcn.004027b0
mov edi, eax
mov esi, ebx
mov byte [ebp - 4], 0xa
call fcn.00404060
lea esi, [ebp - 0x270]
call fcn.0040ff10
lea ecx, [ebp - 0x384]
mov byte [ebp - 4], 2
call fcn.00401bf0
jmp 0x41ac99
mov esi, str.startmenu
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
jne 0x41b429
mov esi, str.programstartmenu
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
jne 0x41b429
mov esi, str.CommonStartMenu
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41afc4
lea ecx, [ebp - 0x21c]
push ecx
push 0
push 0
push 0x16
jmp 0x41b08c
mov esi, str.commonappsdir
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41afea
lea edx, [ebp - 0x21c]
push edx
push 0
push 0
push 0x2b
jmp 0x41b08c
mov esi, str.commonappsdir64
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41b026
push 0x104
lea eax, [ebp - 0x21c]
push eax
push str.CommonProgramW6432
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
push ebx
lea eax, [ebp - 0x21c]
call fcn.00402560
jmp 0x41ac99
mov esi, str.commonappsdircuros
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41b06b
call fcn.00430aa0
test al, al
je 0x41afd8
push 0x104
lea ecx, [ebp - 0x21c]
push ecx
push str.CommonProgramW6432
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
push ebx
lea eax, [ebp - 0x21c]
call fcn.00402560
jmp 0x41ac99
mov esi, str.commondesktop
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41b0a5
lea eax, [ebp - 0x21c]
push eax
push 0
push 0
push 0x19
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
push ebx
lea eax, [ebp - 0x21c]
call fcn.00402560
jmp 0x41ac99
mov esi, 0x45a15c
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41b0c9
push ebx
mov eax, 0x46aeba
call fcn.00402560
jmp 0x41ac99
mov esi, str.getstring
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41b123
mov eax, dword [ebp - 0x254]
cmp dword [ebp - 0x240], edi
jae 0x41b0f1
lea eax, [ebp - 0x254]
push 0x104
lea ecx, [ebp - 0x21c]
push ecx
push eax
call fcn.0043977b
add esp, 4
mov ecx, eax
mov edx, 0x46aea8
call fcn.0042d4b0
push ebx
lea eax, [ebp - 0x21c]
call fcn.00402560
jmp 0x41ac99
mov esi, str.resource
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41b147
call fcn.00410e00
push ebx
call fcn.00402560
jmp 0x41ac99
mov esi, str.getswitch
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41b1a1
mov eax, dword [ebp - 0x254]
cmp dword [ebp - 0x240], edi
jae 0x41b16f
lea eax, [ebp - 0x254]
push eax
call fcn.00402130
test eax, eax
je 0x41ac99
mov ecx, dword [ebp - 0x254]
cmp dword [ebp - 0x240], edi
jae 0x41b191
lea ecx, [ebp - 0x254]
call fcn.00402200
push ebx
call fcn.00402560
jmp 0x41ac99
mov esi, str.getdriverversion
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41b1f4
mov esi, dword [ebp - 0x240]
cmp esi, edi
mov edi, dword [ebp - 0x254]
mov eax, edi
jae 0x41b1cd
lea eax, [ebp - 0x254]
push eax
call fcn.00406830
cmp eax, 0xffffffff
jne 0x41b27b
mov eax, edi
cmp esi, 8
jae 0x41b1e9
lea eax, [ebp - 0x254]
push eax
push str.Driver__s_not_found__ignoring
jmp 0x41b412
mov eax, dword [ebp - 0x238]
cmp dword [ebp - 0x224], edi
jae 0x41b208
lea eax, [ebp - 0x238]
push str.getpackageversion
push eax
call fcn.00439375
add esp, 8
test eax, eax
jne 0x41b28b
mov ecx, ebx
call fcn.0042c130
test al, al
jne 0x41ac99
push str.Version.ini_not_found_falling_back_to_driver_versioning
push 0x4699dc
mov eax, 1
call fcn.0042c820
mov esi, dword [ebp - 0x240]
add esp, 8
cmp esi, edi
mov edi, dword [ebp - 0x254]
mov eax, edi
jae 0x41b258
lea eax, [ebp - 0x254]
push eax
call fcn.00406830
cmp eax, 0xffffffff
jne 0x41b27b
mov eax, edi
cmp esi, 8
jae 0x41b270
lea eax, [ebp - 0x254]
push eax
push str.Driver__s_not_found_for_versioning__ignoring
jmp 0x41b412
call fcn.0040a320
push ebx
call fcn.00402560
jmp 0x41ac99
mov esi, str.installeddir
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41b2bb
mov eax, dword [0x46adb8]
add eax, 0xa1c
cmp dword [eax + 0x14], edi
jb 0x41b2b0
mov eax, dword [eax]
push ebx
call fcn.00402560
jmp 0x41ac99
mov esi, 0x45a310
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41b2df
call fcn.00430710
push ebx
call fcn.00402560
jmp 0x41ac99
mov esi, 0x45a318
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41b303
call fcn.004307a0
push ebx
call fcn.00402560
jmp 0x41ac99
mov esi, str._logpath
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41b34a
push str.report
call fcn.00402130
test eax, eax
je 0x41b33a
mov ecx, str.report
call fcn.00402200
push ebx
call fcn.00402560
jmp 0x41ac99
call fcn.00430350
push ebx
call fcn.00402560
jmp 0x41ac99
mov esi, str.netframework
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41b36e
call fcn.00432400
push ebx
call fcn.00402560
jmp 0x41ac99
mov esi, str.installutil
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41b399
lea edx, [ebp - 0x270]
push 0
push edx
call fcn.00432900
add esp, 8
mov byte [ebp - 4], 0xb
jmp 0x41b3ed
mov esi, str.installutil32
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41b3c4
lea eax, [ebp - 0x270]
push 1
push eax
call fcn.00432900
add esp, 8
mov byte [ebp - 4], 0xc
jmp 0x41b3ed
mov esi, str.installutil64
lea ecx, [ebp - 0x238]
call fcn.0040eb20
test al, al
je 0x41b406
lea ecx, [ebp - 0x270]
push 2
push ecx
call fcn.00432900
add esp, 8
mov byte [ebp - 4], 0xd
mov edi, eax
mov esi, ebx
call fcn.00404060
lea esi, [ebp - 0x270]
call fcn.0040ff10
jmp 0x41ac99
mov edx, dword [ebp - 0x2d0]
push edx
push str.Unknown_variable___s___ignoring
push 0x4699dc
mov eax, 1
call fcn.0042c820
add esp, 0xc
jmp 0x41ac99
lea eax, [ebp - 0x21c]
push eax
push 0
push 0
push 0x17
jmp 0x41b08c
push 0x104
lea ecx, [ebp - 0x21c]
push ecx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
push ebx
lea eax, [ebp - 0x21c]
call fcn.00402560
jmp 0x41ac99