Function at 0x4043fe
Capabilities:
Accept command line arguments
Check os version
Copy file
Delete file
Get common file path
Get file system object information
Set current directory
Set environment variable
Shutdown system
Terminate process

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x2fc
mov dword [esp], 0x8001
call dword [sym.imp.KERNEL32.dll_SetErrorMode]
push esi
call dword [sym.imp.KERNEL32.dll_GetVersion]
and eax, 0xbfffffff
mov dword [0x431de0], eax
cmp ax, 6
je 0x404449
mov dword [esp], 0
call fcn.00408e08
push ebx
test eax, eax
je 0x404449
mov dword [esp], 0xc00
call eax
push ecx
mov ebx, str.UXTHEME
mov dword [esp], ebx
call fcn.00408d78
push edi
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
lea ebx, [ebx + eax + 1]
push edx
cmp byte [ebx], 0
jne 0x40444e
mov dword [esp], 0xb
call fcn.00408e08
push ecx
mov dword [esp], 9
call fcn.00408e08
push ebx
mov dword [0x431de4], eax
mov dword [esp], 7
call fcn.00408e08
push esi
test eax, eax
je 0x4044b2
mov dword [esp], 0x1e
call eax
push edx
test eax, eax
je 0x4044b2
or dword [0x431de0], 0x40000000
call dword [sym.imp.COMCTL32.DLL_InitCommonControls]
mov dword [esp], 0
call dword [sym.imp.ole32.dll_OleInitialize]
push ecx
mov dword [0x431d58], eax
lea eax, [ebp - 0x2cc]
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0x2b4
mov dword [esp + 8], eax
mov dword [esp + 4], 0
mov dword [esp], 0x40c43a
call dword [sym.imp.SHELL32.dll_SHGetFileInfoW]
sub esp, 0x14
mov dword [esp + 4], str.NSIS_Error
mov dword [esp], 0x431e00
call fcn.004082a4
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
mov ecx, dword [0x40c8f4]
add ecx, 0xa000
mov dword [esp + 4], eax
mov dword [esp], ecx
mov dword [ebp - 0x2dc], ecx
call fcn.004082a4
push esi
push esi
mov dword [esp], 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov dword [0x431dec], eax
mov eax, dword [0x40c8f4]
push edi
movzx eax, word [eax + 0xa000]
cmp ax, 0x22
jne 0x40456c
mov ecx, dword [0x40c8f4]
lea edx, [ecx + 0xa002]
jmp 0x404577
mov edx, dword [ebp - 0x2dc]
mov eax, 0x20
mov dword [esp], edx
mov dword [esp + 4], eax
call fcn.00407b31
push edi
push edi
xor edi, edi
mov dword [esp], eax
call dword [sym.imp.USER32.dll_CharNextW]
mov dword [ebp - 0x2e0], eax
push edx
cmp word [eax], 0
je 0x404658
movzx edx, word [eax]
cmp dx, 0x20
jne 0x4045af
add eax, 2
jmp 0x4045a1
cmp dx, 0x22
jne 0x4045ba
add eax, 2
jmp 0x4045bf
mov edx, 0x20
cmp word [eax], 0x2f
jne 0x404638
cmp word [eax + 2], 0x53
lea ebx, [eax + 2]
jne 0x4045e1
test word [eax + 4], 0xffdf
jne 0x4045e1
mov dword [0x431d40], 1
cmp dword [eax + 6], 0x430052
jne 0x404601
cmp dword [eax + 2], 0x43004e
jne 0x404601
test word [eax + 0xa], 0xffdf
mov ecx, 4
cmove edi, ecx
cmp dword [eax + 2], 0x3d0044
jne 0x404636
cmp dword [eax - 2], 0x2f0020
jne 0x404636
mov word [eax - 2], 0
add eax, 6
mov dword [esp + 4], eax
mov eax, dword [0x40c8f4]
add eax, 0xa800
mov dword [esp], eax
call fcn.004082a4
push esi
push esi
jmp 0x404658
mov eax, ebx
mov dword [esp + 4], edx
mov dword [esp], eax
call fcn.00407b31
push ebx
push ebx
cmp word [eax], 0x22
jne 0x404597
add eax, 2
jmp 0x404597
mov eax, dword [0x40c8f4]
mov dword [esp], 0x400
mov esi, dword [sym.imp.KERNEL32.dll_GetTempPathW]
lea ebx, [eax + 0xc800]
mov dword [esp + 4], ebx
call esi
push ecx
push ecx
call fcn.0040435c
test eax, eax
je 0x4046af
mov eax, dword [0x40c8f4]
add eax, 0xc000
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push eax
mov dword [esp], edi
xor edi, edi
call fcn.00404038
mov esi, eax
push edx
test eax, eax
jne 0x40498a
jmp 0x404739
mov dword [esp + 4], 0x3fb
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
push eax
push eax
mov dword [esp + 4], str.Temp
mov dword [esp], ebx
call sub.KERNEL32.dll_lstrcatW
push eax
push eax
call fcn.0040435c
test eax, eax
jne 0x404681
mov dword [esp + 4], ebx
mov dword [esp], 0x3fc
call esi
push esi
push esi
mov dword [esp + 4], 0x40c45e
mov dword [esp], ebx
call sub.KERNEL32.dll_lstrcatW
mov esi, dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
push eax
push eax
mov dword [esp + 4], ebx
mov dword [esp], str.TEMP
call esi
push eax
push eax
mov dword [esp + 4], ebx
mov dword [esp], 0x40c470
call esi
push eax
push eax
call fcn.0040435c
test eax, eax
jne 0x404681
mov esi, str.Error_writing_temporary_file._Make_sure_your_temp_folder_is_valid.
jmp 0x404988
cmp dword [0x431dc8], 0
je 0x404975
mov eax, dword [ebp - 0x2dc]
mov dword [esp + 4], 0
mov dword [esp], eax
call fcn.00407b31
push ecx
push ecx
cmp dword [ebp - 0x2dc], eax
ja 0x4047d0
cmp dword [eax + 4], 0x3d003f
je 0x404774
sub eax, 2
jmp 0x40475e
cmp dword [eax], 0x5f0020
jne 0x40476f
lea ebx, [eax + 8]
mov word [eax], 0
mov dword [esp], ebx
call fcn.00408a3f
push edx
test eax, eax
jne 0x40479b
mov esi, str.Error_launching_installer
jmp 0x404988
mov eax, dword [0x40c8f4]
mov dword [esp + 4], ebx
add eax, 0xa800
mov dword [esp], eax
call fcn.004082a4
mov eax, dword [0x40c8f4]
push edi
push edi
add eax, 0xb000
mov dword [esp + 4], ebx
mov dword [esp], eax
call fcn.004082a4
push eax
push eax
jmp 0x404975
call fcn.00408e54
mov dword [esp + 4], str.nsu
mov dword [esp], ebx
mov edi, eax
call sub.KERNEL32.dll_lstrcatW
push esi
push esi
test edi, edi
je 0x4047ff
mov dword [esp + 4], 0x40c482
mov dword [esp], ebx
call sub.KERNEL32.dll_lstrcatW
push ecx
push ecx
mov dword [esp + 4], str..tmp
mov dword [esp], ebx
call sub.KERNEL32.dll_lstrcatW
push eax
push eax
mov eax, dword [0x40c8f4]
lea esi, [eax + 0xb800]
mov dword [esp + 4], esi
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_lstrcmpiW]
push edx
push edx
test eax, eax
je 0x404791
mov dword [esp], ebx
test edi, edi
je 0x404841
call fcn.00407930
jmp 0x404846
call fcn.004079c4
push eax
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
push eax
mov eax, dword [0x40c8f4]
cmp word [eax + 0xa800], 0
jne 0x404873
add eax, 0xa800
mov dword [esp + 4], esi
mov dword [esp], eax
call fcn.004082a4
push eax
push eax
mov eax, dword [ebp - 0x2e0]
mov edi, 0x1a
mov esi, str.Error_launching_installer
mov dword [esp + 4], eax
mov eax, dword [0x40c8f4]
mov dword [esp], eax
call fcn.004082a4
push eax
push eax
mov eax, dword [0x40c8f4]
mov dword [eax + 0x800], 0x41
mov eax, dword [0x431d60]
mov eax, dword [eax + 0x120]
mov dword [esp], 0x42a940
mov dword [esp + 4], eax
call fcn.0040844a
push ecx
push ecx
mov dword [esp], 0x42a940
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push eax
test esi, esi
je 0x40494e
mov eax, dword [0x40c8f4]
mov dword [esp + 8], 1
mov dword [esp + 4], 0x42a940
add eax, 0xd800
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
sub esp, 0xc
test eax, eax
je 0x40494e
mov dword [esp + 4], 0
mov dword [esp], 0x42a940
call fcn.004089c2
push eax
push eax
mov eax, dword [0x431d60]
mov eax, dword [eax + 0x124]
mov dword [esp], 0x42a940
mov dword [esp + 4], eax
call fcn.0040844a
push eax
push eax
mov dword [esp], 0x42a940
call fcn.004079f2
push edx
test eax, eax
je 0x40494e
mov dword [esp], eax
xor esi, esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push eax
mov eax, dword [0x40c8f4]
inc word [eax + 0x800]
dec edi
jne 0x4048a5
mov dword [esp + 4], 0
mov dword [esp], ebx
call fcn.004089c2
push edi
push edi
jmp 0x404988
mov dword [0x431d4c], 0xffffffff
call fcn.00406312
mov edi, eax
jmp 0x40498a
xor edi, edi
call fcn.004043b7
call dword [sym.imp.ole32.dll_OleUninitialize]
test esi, esi
mov ebx, dword [sym.imp.KERNEL32.dll_ExitProcess]
je 0x4049bd
mov dword [esp], esi
mov dword [esp + 4], 0x200010
call fcn.00407ac5
push esi
push esi
mov dword [esp], 2
jmp 0x404add
cmp dword [0x431d34], 0
je 0x404acf
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea edx, [ebp - 0x2d0]
mov dword [esp + 4], 0x28
mov dword [esp + 8], edx
mov dword [esp], eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
sub esp, 0xc
test eax, eax
je 0x404a64
lea eax, [ebp - 0x2c8]
mov dword [esp + 4], str.SeShutdownPrivilege
lea esi, [ebp - 0x2cc]
mov dword [esp + 8], eax
mov dword [esp], 0
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueW]
mov eax, dword [ebp - 0x2d0]
mov dword [ebp - 0x2cc], 1
mov dword [ebp - 0x2c0], 2
sub esp, 0xc
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0
mov dword [esp + 8], esi
mov dword [esp + 4], 0
mov dword [esp], eax
call dword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
sub esp, 0x18
mov dword [esp], 4
call fcn.00408e08
push ecx
test eax, eax
jne 0x404a92
mov dword [esp + 4], 0x80040002
mov dword [esp], 2
call dword [sym.imp.USER32.dll_ExitWindowsEx]
push edx
push edx
test eax, eax
je 0x404ac2
jmp 0x404acf
mov dword [esp + 0x10], 0x80040002
mov dword [esp + 0xc], 0x25
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov dword [esp], 0
call eax
sub esp, 0x14
test eax, eax
jne 0x404a75
mov dword [esp], 9
call fcn.00403bd9
push eax
mov eax, dword [0x431d4c]
cmp eax, 0xffffffff
cmovne edi, eax
mov dword [esp], edi
call ebx
nop