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

Disassembly:
jmp 0x404a2b
sub esp, 0x3ec
and dword [esp], 0
push ebx
push ebp
push esi
push edi
push 0x20
pop eax
push 0x8001
mov ebx, str.Error_writing_temporary_file._Make_sure_your_temp_folder_is_valid.
mov dword [esp + 0x18], eax
xor ebp, ebp
mov edi, eax
call dword [sym.imp.KERNEL32.dll_SetErrorMode]
and dword [esp + 0x40], ebp
lea eax, [esp + 0x2c]
mov esi, dword [sym.imp.KERNEL32.dll_GetVersionExW]
xorps xmm0, xmm0
push eax
movlpd qword [esp + 0x144], xmm0
mov dword [esp + 0x30], 0x11c
call esi
test eax, eax
jne 0x404ab4
lea eax, [esp + 0x2c]
mov dword [esp + 0x2c], 0x114
push eax
call esi
push 0x53
pop eax
mov dl, 4
mov byte [esp + 0x146], dl
cmp word [esp + 0x40], ax
jne 0x404ab0
mov eax, dword [esp + 0x5a]
add eax, 0xffffffd0
mov word [esp + 0x140], ax
jmp 0x404abb
xor eax, eax
jmp 0x404aa6
mov dl, byte [esp + 0x146]
cmp dword [esp + 0x30], 0xa
jae 0x404acd
movzx eax, word [esp + 0x38]
mov dword [esp + 0x38], eax
jmp 0x404ad1
mov eax, dword [esp + 0x38]
movzx ecx, byte [esp + 0x30]
shl ecx, 8
mov dword [0x48e558], eax
movzx eax, byte [esp + 0x34]
or ecx, eax
movzx eax, byte [esp + 0x140]
shl ecx, 8
or ecx, eax
movzx eax, dl
shl ecx, 8
or ecx, eax
mov eax, 0x600
mov dword [0x48e55c], ecx
cmp word [0x48e55e], ax
je 0x404b20
push 0
call fcn.00401136
test eax, eax
je 0x404b20
push 0xc00
call eax
mov esi, str.UXTHEME
push esi
call fcn.0040114f
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
inc esi
add esi, eax
cmp byte [esi], 0
jne 0x404b25
push 0xc
call fcn.00401136
push 0xa
call fcn.00401136
push 8
mov dword [0x486410], eax
call fcn.00401136
test eax, eax
je 0x404b67
push 0x1e
call eax
test eax, eax
je 0x404b67
or byte [0x48e55c], 0x80
call dword [sym.imp.COMCTL32.dll_InitCommonControls]
xor esi, esi
push esi
call dword [sym.imp.ole32.dll_OleInitialize]
push esi
push 0x2b4
mov dword [0x48e4a0], eax
lea eax, [esp + 0x150]
push eax
push esi
push 0x40d308
call dword [sym.imp.SHELL32.dll_SHGetFileInfoW]
push str.NSIS_Error
push 0x486420
call fcn.00401078
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
push eax
mov esi, 0x4e1000
push esi
call fcn.00401078
push 0x22
mov eax, esi
mov dword [0x486414], 0x400000
pop esi
cmp word [0x4e1000], si
jne 0x404bd5
mov edi, esi
mov eax, 0x4e1002
push edi
push eax
call fcn.0040104b
push eax
call dword [sym.imp.USER32.dll_CharNextW]
mov edi, eax
jmp 0x404c73
push 0x20
pop edx
cmp cx, dx
jne 0x404bfa
add eax, 2
cmp word [eax], dx
je 0x404bf2
cmp word [eax], si
jne 0x404c04
add eax, 2
mov edx, esi
cmp word [eax], 0x2f
jne 0x404c64
add eax, 2
push 0x53
pop ecx
cmp word [eax], cx
jne 0x404c2f
movzx ecx, word [eax + 2]
cmp cx, word [esp + 0x14]
je 0x404c25
test cx, cx
jne 0x404c2f
mov dword [0x48e540], 1
cmp dword [eax], 0x43004e
jne 0x404c53
cmp dword [eax + 4], 0x430052
jne 0x404c53
movzx ecx, word [eax + 8]
cmp cx, word [esp + 0x14]
je 0x404c50
test cx, cx
jne 0x404c53
or ebp, 4
cmp dword [eax - 4], 0x2f0020
jne 0x404c64
cmp dword [eax], 0x3d0044
je 0x404c81
push edx
push eax
call fcn.0040104b
cmp word [eax], si
jne 0x404c73
add eax, 2
movzx ecx, word [eax]
test cx, cx
jne 0x404bea
jmp 0x404c95
xor ecx, ecx
mov word [eax - 4], cx
add eax, 4
push eax
push 0x4e5000
call fcn.00401078
mov esi, dword [sym.imp.KERNEL32.dll_GetTempPathW]
push 0x4f5000
push 0x2000
call esi
call fcn.0040108c
test eax, eax
jne 0x404d1b
push 0x1ffb
push 0x4f5000
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
push str.Temp
push 0x4f5000
call fcn.00401055
call fcn.0040108c
test eax, eax
jne 0x404d1b
push 0x4f5000
push 0x1ffc
call esi
push 0x40d338
mov esi, 0x4f5000
push esi
call fcn.00401055
push esi
mov esi, dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
push str.TEMP
call esi
push 0x4f5000
push 0x40d350
call esi
call fcn.0040108c
test eax, eax
je 0x404efe
push 0x4f1000
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push ebp
call fcn.00401186
mov ebx, eax
test ebx, ebx
jne 0x404efe
cmp dword [0x48e43c], eax
je 0x404d9d
push eax
mov ebp, 0x4e1000
push ebp
call fcn.0040104b
mov esi, eax
jmp 0x404d62
cmp dword [esi], 0x5f0020
jne 0x404d5f
cmp dword [esi + 4], 0x3d003f
je 0x404d66
sub esi, 2
cmp esi, ebp
jae 0x404d4e
mov ebx, str.Error_launching_installer
cmp esi, ebp
jb 0x404db7
xor eax, eax
mov word [esi], ax
add esi, 8
push esi
call fcn.004010b9
test eax, eax
je 0x404efe
push esi
push 0x4e5000
call fcn.00401078
push esi
push 0x4e9000
call fcn.00401078
xor ebx, ebx
or dword [0x48e54c], 0xffffffff
call fcn.0040105f
push 1
mov ebp, eax
call fcn.004010ff
jmp 0x404f02
call fcn.004010be
push 0x4f5000
mov dword [esp + 0x1c], eax
call fcn.0040107d
push edi
push section..ndata
mov esi, eax
call fcn.00401078
cmp word [0x4e5000], 0
jne 0x404df0
push 0x4ed000
push 0x4e5000
call fcn.00401078
xor edi, edi
lea eax, [esi*2 + 0x4f5000]
inc edi
mov dword [esp + 0x14], eax
xor esi, esi
movzx ebp, di
push ebp
push str.nsu_X.tmp
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
mov eax, dword [0x48e448]
add esp, 0xc
push dword [eax + 0x120]
push 0x4a5000
call fcn.0040111d
cmp dword [esp + 0x18], 0
push 0x4f5000
je 0x404e3b
call fcn.00401082
jmp 0x404e40
call fcn.00401032
test eax, eax
je 0x404e8d
push 0x4a5000
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
test eax, 0x400
jne 0x404f24
push 0x4a5000
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x404f24
push 1
push 0x4f5000
call fcn.004010e1
mov eax, esi
inc esi
test eax, eax
jne 0x404f24
mov eax, dword [esp + 0x14]
jmp 0x404e03
push 0x4f5000
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
push 0
push 0x4f5000
call fcn.00401163
push 1
push 0x4a5000
push 0x4fd000
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
je 0x404efe
push 0
push 0x4a5000
call fcn.00401163
mov eax, dword [0x48e448]
push dword [eax + 0x124]
push 0x4a9000
call fcn.0040111d
push 0x4a9000
call fcn.0040109b
test eax, eax
jne 0x404f34
mov eax, esi
inc esi
test eax, eax
jne 0x404efe
push 0x4a5000
call fcn.0040101e
test eax, eax
je 0x404e84
mov ebp, dword [esp + 0x10]
call fcn.00401087
call dword [sym.imp.ole32.dll_OleUninitialize]
test ebx, ebx
je 0x404f3f
push 0x200010
push ebx
call fcn.00401073
push 2
call dword [sym.imp.KERNEL32.dll_ExitProcess]
mov eax, dword [esp + 0x14]
inc edi
test di, di
jne 0x404dfe
jmp 0x404efe
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor ebx, ebx
jmp 0x404efe
cmp dword [0x48e534], 0
je 0x404fd0
lea eax, [esp + 0x18]
push eax
push 0x28
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x404f9d
lea eax, [esp + 0x20]
push eax
push str.SeShutdownPrivilege
push 0
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueW]
push 0
push 0
push 0
lea eax, [esp + 0x28]
mov dword [esp + 0x28], 1
push eax
push 0
push dword [esp + 0x2c]
mov dword [esp + 0x40], 2
call dword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
push 4
call fcn.00401136
mov esi, 0x80040002
test eax, eax
je 0x404fbc
push esi
push 0x25
push 0
push 0
push 0
call eax
test eax, eax
je 0x404fc9
push esi
push 2
call dword [sym.imp.USER32.dll_ExitWindowsEx]
test eax, eax
jne 0x404fd0
push 9
call fcn.00401145
cmp dword [0x48e54c], 0xffffffff
cmovne ebp, dword [0x48e54c]
push ebp
jmp 0x404f1e