Function at 0x403520
Capabilities:
Accept command line arguments
Check if file exists
Check os version
Enumerate gui resources
Get file attributes
Identify system language via api

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x158
push ebx
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x40da38], eax
call dword [sym.imp.KERNEL32.dll_GetVersion]
push 0x40d8f0
mov dword [0x40d9d8], eax
mov dword [0x40d8f0], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
xor ebx, ebx
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov esi, dword [sym.imp.KERNEL32.dll_SetErrorMode]
push ebx
mov dword [0x40da3c], eax
call esi
or eax, 0x8001
push eax
call esi
call dword [sym.imp.KERNEL32.dll_GetUserDefaultLangID]
and eax, 0xff
cmp eax, 5
je 0x403590
cmp eax, 0x15
je 0x403590
cmp eax, 0x1b
jne 0x40359a
mov dword [0x40da9c], 1
mov esi, dword [sym.imp.USER32.dll_GetSystemMetrics]
push 0x10
call esi
push 0x11
mov dword [0x40d984], eax
call esi
mov dword [0x40d988], eax
call fcn.0040aee0
test eax, eax
je 0x403be8
mov eax, dword [0x40d900]
cmp eax, 1
jne 0x4035d6
cmp word [0x40d8fc], 0x3e8
ja 0x4035db
jmp 0x4035fb
cmp eax, 2
jne 0x4035fb
push str.KERNEL32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
cmp eax, ebx
je 0x4035fb
push str.GetDiskFreeSpaceExA
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x40da98], eax
wait
fnstcw word [ebp - 0xa]
wait
mov ax, word [ebp - 0xa]
and ah, 0xf3
or ah, 3
mov word [ebp - 0xa], ax
fldcw word [ebp - 0xa]
call fcn.00401160
test al, al
je 0x403be8
push 0x40c070
push section..data
call fcn.00403390
add esp, 8
push ebx
push 0x4034a0
call dword [sym.imp.USER32.dll_EnumWindows]
cmp dword [0x40db5c], ebx
je 0x403649
call fcn.00403d30
push ecx
mov ecx, esp
push str.SetupLang
call fcn.00401780
push ecx
mov ecx, esp
push 0x40d9e8
call fcn.00401730
lea eax, [ebp - 8]
push eax
call fcn.00405260
add esp, 0xc
mov edx, 0x40c514
lea ecx, [ebp - 8]
call fcn.00402370
test eax, eax
jne 0x4036a2
mov edx, 0x40c510
lea ecx, [ebp - 8]
call fcn.00402370
test eax, eax
jne 0x4036a2
mov edx, 0x40c50c
lea ecx, [ebp - 8]
call fcn.00402370
test eax, eax
je 0x4036ac
mov dword [0x40da9c], 1
mov edx, 0x40c508
lea ecx, [ebp - 8]
call fcn.00402370
test eax, eax
jne 0x4036df
mov edx, 0x40c504
lea ecx, [ebp - 8]
call fcn.00402370
test eax, eax
jne 0x4036df
mov edx, 0x40c500
lea ecx, [ebp - 8]
call fcn.00402370
test eax, eax
je 0x4036e5
mov dword [0x40da9c], ebx
push str.RICHED32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov ecx, 0x39000
call fcn.0040a890
lea ecx, [ebp - 0x38]
mov dword [0x40da5c], eax
call fcn.00402550
push 2
push 0x257
lea ecx, [ebp - 0x38]
call fcn.004025b0
mov ecx, 0x428
call fcn.0040a890
mov esi, dword [ebp - 0x38]
mov ecx, 0x10a
mov edi, eax
mov dword [0x40d9c0], eax
rep movsd dword es:[edi], dword [esi]
mov ecx, dword [0x40d9c0]
xor eax, eax
xor edx, edx
mov dword [ecx + 0x10], ebx
mov ecx, dword [0x40d9c0]
mov al, byte [ecx + 0x3c4]
mov dl, byte [ecx + 0x3c5]
shl eax, 8
add eax, edx
xor edx, edx
mov dl, byte [ecx + 0x3c6]
shl eax, 8
add eax, edx
push eax
mov dword [0x40da4c], eax
call dword [sym.imp.GDI32.dll_CreateSolidBrush]
mov ecx, 0x404
mov dword [0x40da50], eax
call fcn.0040a890
mov edx, eax
mov ecx, 0x101
xor eax, eax
mov edi, edx
rep stosd dword es:[edi], eax
mov word [edx], 0x300
mov word [edx + 2], 0xfa
mov ecx, dword [0x40d9c0]
lea eax, [edx + 4]
mov edi, 0x100
lea esi, [ecx + 0x28]
mov cl, byte [esi + 2]
add esi, 4
mov byte [eax], cl
mov cl, byte [esi - 3]
mov byte [eax + 1], cl
mov cl, byte [esi - 4]
mov byte [eax + 2], cl
mov byte [eax + 3], 0
add eax, 4
dec edi
jne 0x4037a6
push edx
call dword [sym.imp.GDI32.dll_CreatePalette]
mov edx, dword [0x40da3c]
mov esi, dword [sym.imp.USER32.dll_LoadCursorA]
push 0x22b
push edx
mov dword [0x40da48], eax
call esi
push 0x7f00
push ebx
mov dword [0x40d9e0], eax
call esi
push 0x7f02
push ebx
mov dword [0x40d9b8], eax
call esi
mov dword [0x40d998], eax
call dword [sym.imp.COMCTL32.dll_InitCommonControls]
mov eax, dword [0x40da3c]
push ebx
push ebx
push 0xffffffffffffffff
push 0xa
push 0x14
push 0x239
push eax
call dword [sym.imp.COMCTL32.dll_ImageList_LoadImageA]
mov dword [0x40daa0], eax
call fcn.0040a790
test al, al
jne 0x403864
push 0x10
push str.System_Error
push str.Chyba_syst
call fcn.00402be0
add esp, 8
push eax
push str.Insufficient_system_resources_to_run_installator.
push str.Nedostatek_syst
call fcn.00402be0
add esp, 8
push eax
push ebx
call dword [sym.imp.USER32.dll_MessageBoxA]
call fcn.00403d30
push ecx
mov ecx, esp
push str.Path
call fcn.00401780
push ecx
mov ecx, esp
push 0x40d9e8
call fcn.00401730
lea ecx, [ebp - 0x20]
push ecx
call fcn.00405260
add esp, 0xc
mov edx, eax
mov ecx, 0x40d99c
call fcn.00401f10
lea ecx, [ebp - 0x20]
call fcn.00401ad0
mov edx, dword [0x40d99c]
cmp dword [edx + 4], ebx
je 0x403974
lea ecx, [ebp - 0x10]
mov dword [0x40c128], ebx
call fcn.00401710
lea ecx, [ebp - 0x14]
call fcn.00401710
xor edi, edi
xor esi, esi
push edi
lea ecx, [ebp - 0x10]
call fcn.00402250
push ecx
lea eax, [ebp - 0x10]
mov ecx, esp
push eax
mov edx, str.Group
call fcn.00403d10
push ecx
mov ecx, esp
push 0x40d9e8
call fcn.00401730
lea ecx, [ebp - 0x24]
push ecx
call fcn.00405260
add esp, 0xc
mov ecx, eax
mov dl, 0x31
call fcn.004023b0
test eax, eax
lea ecx, [ebp - 0x24]
setne bl
call fcn.00401ad0
mov byte [esi + 0x40c0dd], bl
mov byte [esi + 0x40c105], bl
mov byte [esi + 0x40c0de], bl
mov byte [esi + 0x40c106], bl
add esi, 0xc
inc edi
cmp esi, 0x24
jl 0x4038c7
push ecx
mov ecx, esp
push 0x40d99c
call fcn.00401730
push ecx
mov ecx, esp
push str.LastPath
call fcn.00401780
push ecx
mov ecx, esp
push 0x40d9d0
call fcn.00401730
call fcn.00405360
add esp, 0xc
lea ecx, [ebp - 0x14]
call fcn.00401ad0
lea ecx, [ebp - 0x10]
call fcn.00401ad0
xor ebx, ebx
jmp 0x4039d6
lea edx, [ebp - 0x28]
push edx
call fcn.004033c0
add esp, 4
mov edx, eax
mov ecx, 0x40d99c
call fcn.00401f10
lea ecx, [ebp - 0x28]
call fcn.00401ad0
mov eax, dword [0x40d99c]
cmp dword [eax + 4], ebx
jne 0x4039ad
mov edx, str.C:Program_Files_
mov ecx, 0x40d99c
call fcn.00401f30
mov ecx, 0x40d99c
call fcn.00402090
cmp al, 0x5c
je 0x4039c7
mov dl, 0x5c
mov ecx, 0x40d99c
call fcn.00401ee0
mov edx, str.PetrLite
mov ecx, 0x40d99c
call fcn.00401e90
push 0x24b
mov ecx, 0x40d9e4
call fcn.004014b0
push 0x24c
mov ecx, 0x40d9c8
call fcn.004014b0
push 0x28
mov edx, 0xe10
mov ecx, 0x40d9d4
call fcn.00401230
push ebx
push ebx
push 0x273
mov ecx, 0x40d9d4
call fcn.00401330
push ebx
push 0x2d0
push 0x270
mov ecx, 0x40d9d4
call fcn.00401330
push ebx
push 0x5a0
push 0x271
mov ecx, 0x40d9d4
call fcn.00401330
push ebx
push 0x870
push 0x272
mov ecx, 0x40d9d4
call fcn.00401330
push ebx
push 0xb40
push 0x26f
mov ecx, 0x40d9d4
call fcn.00401330
call fcn.00402c40
mov edx, dword [0x40da3c]
lea ecx, [ebp - 0x158]
push 0x104
push ecx
push edx
mov byte [ebp - 0x158], 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea edx, [ebp - 0x158]
mov ecx, 0x40d9c4
call fcn.00401f30
mov eax, dword [0x40d9c4]
add eax, 8
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x403ac2
mov edx, str.Setup.exe
mov ecx, 0x40d9c4
call fcn.00401f30
lea ecx, [ebp - 4]
mov dword [0x40db2c], ebx
call fcn.00401710
push 0xa
lea edx, [ebp - 0x18]
mov ecx, 0x40d9c4
call fcn.00401c40
mov edx, eax
lea ecx, [ebp - 4]
call fcn.00401f10
lea ecx, [ebp - 0x18]
call fcn.00401ad0
lea ecx, [ebp - 4]
call fcn.00401bf0
mov edx, str.UNINST.EXE
lea ecx, [ebp - 4]
call fcn.00402370
test eax, eax
mov esi, 1
je 0x403b15
mov dword [0x40db2c], esi
mov edx, str.DEINST.EXE
lea ecx, [ebp - 4]
call fcn.00402370
test eax, eax
je 0x403b2c
mov dword [0x40db2c], esi
mov edx, str.REMOVE.EXE
lea ecx, [ebp - 4]
call fcn.00402370
test eax, eax
je 0x403b43
mov dword [0x40db2c], esi
push 0xc
lea edx, [ebp - 0x1c]
mov ecx, 0x40d9c4
call fcn.00401c40
mov edx, eax
lea ecx, [ebp - 4]
call fcn.00401f10
lea ecx, [ebp - 0x1c]
call fcn.00401ad0
lea ecx, [ebp - 4]
call fcn.00401bf0
mov edx, str.UNINSTAL.EXE
lea ecx, [ebp - 4]
call fcn.00402370
test eax, eax
je 0x403b83
mov dword [0x40db2c], esi
mov edx, str.DEINSTAL.EXE
lea ecx, [ebp - 4]
call fcn.00402370
test eax, eax
je 0x403b9a
mov dword [0x40db2c], esi
mov edx, str.DINSTALL.EXE
lea ecx, [ebp - 4]
call fcn.00402370
test eax, eax
je 0x403bb1
mov dword [0x40db2c], esi
mov edx, str.UINSTALL.EXE
lea ecx, [ebp - 4]
call fcn.00402370
test eax, eax
je 0x403bc8
mov dword [0x40db2c], esi
cmp dword [0x40db68], ebx
je 0x403c21
lea ecx, [ebp - 4]
call fcn.00401ad0
lea ecx, [ebp - 0x38]
call fcn.00402570
lea ecx, [ebp - 8]
call fcn.00401ad0
push 0x10
push str.Memory_Error
push str.Chyba_pam
call fcn.00402be0
add esp, 8
push eax
push str.Insufficient_memory_to_run_installator.
push str.Nedostatek_pam
call fcn.00402be0
add esp, 8
push eax
push ebx
call dword [sym.imp.USER32.dll_MessageBoxA]
call fcn.00403d30
jmp 0x4035bf
mov ecx, dword [0x40da54]
push ebx
push 0x37
push 0x4d2
push ecx
call dword [sym.imp.USER32.dll_SetTimer]
mov dword [0x40da6c], eax
mov eax, dword [0x40db2c]
cmp eax, ebx
mov eax, dword [0x40c128]
je 0x403c6b
cmp eax, ebx
je 0x403c51
push 7
jmp 0x403c73
push 8
call fcn.004095a0
add esp, 4
call fcn.004042f0
test eax, eax
jne 0x403c7b
call fcn.00403d30
jmp 0x403c7b
cmp eax, ebx
je 0x403c72
push ebx
jmp 0x403c73
push esi
call fcn.004095a0
add esp, 4
mov esi, dword [sym.imp.USER32.dll_GetMessageA]
push ebx
push ebx
lea edx, [ebp - 0x54]
push ebx
push edx
call esi
test eax, eax
je 0x403cd0
mov edi, dword [sym.imp.USER32.dll_TranslateMessage]
mov ebx, dword [sym.imp.USER32.dll_DispatchMessageA]
lea eax, [ebp - 0x54]
mov dword [0x40db68], 0
push eax
call fcn.00404610
add esp, 4
test eax, eax
jne 0x403cc0
lea ecx, [ebp - 0x54]
push ecx
call edi
lea edx, [ebp - 0x54]
push edx
call ebx
push 0
push 0
lea eax, [ebp - 0x54]
push 0
push eax
call esi
test eax, eax
jne 0x403c9a
mov ecx, dword [0x40da6c]
mov edx, dword [0x40da54]
push ecx
push edx
call dword [sym.imp.USER32.dll_KillTimer]
call fcn.00403d30
lea ecx, [ebp - 4]
call fcn.00401ad0
lea ecx, [ebp - 0x38]
call fcn.00402570
lea ecx, [ebp - 8]
call fcn.00401ad0
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret