Function at 0x403bbb
Capabilities:
Accept command line arguments
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:
push ebp
push ebx
push edi
push esi
sub esp, 0x3ec
push 0x8001
call dword [sym.imp.KERNEL32.dll_SetErrorMode]
xor esi, esi
lea edi, [esp + 0x1c]
mov dword [edi + 0x14], esi
mov dword [edi + 0x118], esi
mov dword [edi + 0x114], esi
mov dword [edi], 0x11c
push edi
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
test eax, eax
jne 0x403c26
mov dword [esp + 0x1c], 0x114
push edi
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
mov byte [esp + 0x136], 4
movzx eax, word [esp + 0x4a]
add eax, 0xffffffd0
cmp word [esp + 0x30], 0x53
cmove esi, eax
mov word [esp + 0x130], si
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x28]
cmp eax, 9
ja 0x403c3a
movzx ecx, cx
mov dword [esp + 0x28], ecx
mov edi, dword [0x40a474]
mov dword [edi + 0x38], ecx
movzx edx, byte [esp + 0x136]
mov ecx, dword [esp + 0x24]
mov esi, dword [esp + 0x130]
shl esi, 8
movzx esi, si
or esi, edx
shl eax, 0x18
movzx ecx, cl
shl ecx, 0x10
or ecx, eax
or esi, ecx
mov dword [edi + 0x3c], esi
cmp ecx, 0x6000000
je 0x403c88
push 0
call fcn.004068d4
test eax, eax
je 0x403c88
push 0xc00
call eax
mov esi, str.UXTHEME
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenA]
push esi
call fcn.0040794e
push esi
call edi
add esi, eax
inc esi
cmp byte [esi], 0
jne 0x403c93
push 0xc
call fcn.004068d4
push 0xa
call fcn.004068d4
mov dword [0x42da90], eax
push 8
call fcn.004068d4
test eax, eax
je 0x403cd3
push 0x1e
call eax
test eax, eax
je 0x403cd3
mov eax, dword [0x40a474]
or byte [eax + 0x3c], 0x80
call dword [sym.imp.COMCTL32.dll_InitCommonControls]
xor ebx, ebx
push ebx
call dword [sym.imp.ole32.dll_OleInitialize]
mov ecx, dword [0x40a620]
mov dword [ecx], eax
lea eax, [esp + 0x138]
push ebx
push 0x2b4
push eax
push ebx
push 0x40a568
call dword [sym.imp.SHELL32.dll_SHGetFileInfoW]
push str.NSIS_Error
push 0x42da94
call fcn.00406d67
mov eax, dword [0x40a174]
mov esi, dword [eax]
lea edi, [esi + 0xa000]
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
push eax
push edi
call fcn.00406d67
mov dword [esp + 4], 0
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov dword [0x42ea94], eax
xor eax, eax
cmp word [esi + 0xa000], 0x22
mov dword [esp + 8], esi
lea ecx, [esi + 0xa002]
sete al
mov dword [esp + 0xc], edi
cmovne ecx, edi
lea eax, [eax + eax + 0x20]
push eax
push ecx
call fcn.00406e40
push eax
call dword [sym.imp.USER32.dll_CharNextW]
mov dword [esp], eax
movzx edx, word [eax]
test dx, dx
je 0x403e5a
mov dword [esp + 4], 0
mov edi, 0x2f0020
mov eax, dword [esp]
mov ebp, 0x43004e
add eax, 2
cmp dx, 0x20
jne 0x403da3
movzx edx, word [eax]
jmp 0x403d95
movzx ecx, dx
cmp ecx, 0x22
jne 0x403db4
movzx edx, word [eax]
mov cx, 0x22
jmp 0x403dbb
add eax, 0xfffffffe
mov cx, 0x20
cmp dx, 0x2f
jne 0x403e1c
lea edx, [eax + 2]
cmp word [eax + 2], 0x53
jne 0x403de4
movzx esi, word [eax + 4]
test esi, 0xffdf
jne 0x403de4
mov esi, dword [0x40a474]
mov dword [esi + 0x20], 1
mov esi, dword [edx + 4]
mov ebx, 0x430052
xor esi, ebx
mov ebx, dword [edx]
xor ebx, ebp
or ebx, esi
jne 0x403e07
movzx esi, word [eax + 0xa]
test esi, 0xffdf
jne 0x403e07
or dword [esp + 4], 4
mov esi, dword [eax + 2]
mov ebx, 0x3d0044
xor esi, ebx
mov ebx, dword [eax - 2]
xor ebx, edi
or ebx, esi
je 0x403e40
mov eax, edx
movzx ecx, cx
push ecx
push eax
call fcn.00406e40
xor ecx, ecx
cmp word [eax], 0x22
sete cl
lea eax, [eax + ecx*2]
movzx edx, word [eax]
test dx, dx
jne 0x403d95
jmp 0x403e5a
mov word [eax - 2], 0
mov ecx, dword [esp + 8]
add ecx, 0xa800
add eax, 6
push eax
push ecx
call fcn.00406d67
mov edi, dword [esp + 8]
lea ebx, [edi + 0xc800]
push ebx
push 0x400
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
call fcn.00403b7c
test eax, eax
jne 0x403edd
push 0x3fb
push ebx
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
push str.Temp
push ebx
call sub.KERNEL32.dll_lstrcatW
call fcn.00403b7c
test eax, eax
jne 0x403edd
push ebx
push 0x3fc
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
push 0x40a58c
push ebx
call sub.KERNEL32.dll_lstrcatW
mov esi, dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
push ebx
push str.TEMP
call esi
push ebx
push 0x40a59e
call esi
call fcn.00403b7c
test eax, eax
jne 0x403edd
xor ebx, ebx
mov dword [esp], 0x40a490
jmp 0x40412c
mov dword [esp + 0x10], ebx
lea eax, [edi + 0xc000]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push dword [esp + 4]
call fcn.00403549
xor ebx, ebx
test eax, eax
jne 0x403f26
mov eax, dword [0x40a624]
cmp dword [eax], 0
jne 0x403f2e
mov eax, dword [0x40a474]
mov dword [eax + 0x2c], 0xffffffff
mov dword [esp], 0
call fcn.00404330
mov ebx, eax
jmp 0x40412c
mov dword [esp], eax
jmp 0x40412c
push 0
mov esi, dword [esp + 0x10]
push esi
call fcn.00406e40
cmp eax, esi
mov ebp, dword [esp + 0x10]
jb 0x403f68
mov edi, eax
mov eax, 0x3d003f
mov ecx, 0x5f0020
mov edx, dword [edi + 4]
xor edx, eax
mov esi, dword [edi]
xor esi, ecx
or esi, edx
je 0x4040db
add edi, 0xfffffffe
cmp edi, dword [esp + 0xc]
jae 0x403f4e
call fcn.004068ba
mov dword [esp + 0xc], eax
push ebp
call sub.KERNEL32.dll_lstrlenW
mov ebx, eax
push dword [esp]
mov esi, dword [esp + 0xc]
push esi
call fcn.00406d67
cmp word [esi + 0xa800], 0
jne 0x403fa3
lea eax, [esi + 0xa800]
lea ecx, [esi + 0xb800]
push ecx
push eax
call fcn.00406d67
lea edi, [esi + 0x2800]
lea eax, [esi + 0x3000]
mov dword [esp + 0x14], eax
lea eax, [ebx*2]
add eax, ebp
add esi, 0xd800
mov dword [esp + 8], esi
mov esi, eax
xor eax, eax
inc eax
mov dword [esp + 4], eax
mov bl, 1
push dword [esp + 4]
push str.nsu_X.tmp
push esi
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
mov eax, dword [0x40a004]
mov eax, dword [eax]
push dword [eax + 0x120]
push edi
call fcn.00407437
cmp dword [esp + 0xc], 0
je 0x40400a
mov ebp, dword [esp + 0x10]
push ebp
call fcn.00406848
jmp 0x404014
mov ebp, dword [esp + 0x10]
push ebp
call fcn.0040689c
test eax, eax
je 0x40404f
push edi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
bt eax, 0xa
jb 0x4040be
push edi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x4040be
push 1
push dword [esp + 0x14]
call fcn.00406a9b
test bl, 1
mov ebx, 0
jne 0x403fd1
jmp 0x4040be
push ebp
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
push 0
push ebp
call fcn.00406dba
push 1
push edi
push dword [esp + 0x10]
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
je 0x4040d2
mov dword [esp], str.Error_launching_installer
mov ebp, esi
push 0
push edi
call fcn.00406dba
mov eax, dword [0x40a004]
mov eax, dword [eax]
push dword [eax + 0x124]
mov esi, dword [esp + 0x18]
push esi
call fcn.00407437
push esi
call fcn.0040690d
test eax, eax
jne 0x40411c
test bl, 1
je 0x40412a
push edi
call fcn.00406de9
xor ebx, ebx
test eax, eax
mov esi, ebp
je 0x403fd1
jmp 0x40412c
mov eax, dword [esp + 4]
inc eax
mov dword [esp + 4], eax
cmp eax, 0x10000
jne 0x403fcf
mov dword [esp], str.Error_launching_installer
jmp 0x40412a
mov word [edi], 0
add edi, 8
push edi
call fcn.00406ccc
mov dword [esp], str.Error_launching_installer
mov ebx, 0
test eax, eax
je 0x40412c
mov esi, dword [esp + 8]
lea eax, [esi + 0xa800]
push edi
push eax
call fcn.00406d67
add esi, 0xb000
push edi
push esi
call fcn.00406d67
jmp 0x403f07
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esp], 0
xor ebx, ebx
call fcn.0040420a
call dword [sym.imp.ole32.dll_OleUninitialize]
mov eax, dword [esp]
test eax, eax
jne 0x4041f7
mov eax, dword [0x40a474]
cmp dword [eax + 0x14], 0
je 0x4041e2
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea ecx, [esp + 0x18]
push ecx
push 0x28
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x4041a3
lea edi, [esp + 0x13c]
xor esi, esi
push edi
push str.SeShutdownPrivilege
push esi
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueW]
mov dword [edi - 4], 1
mov dword [edi + 8], 2
push esi
push esi
push esi
lea eax, [esp + 0x144]
push eax
push esi
push dword [esp + 0x2c]
call dword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
push 4
call fcn.004068d4
test eax, eax
je 0x4041ca
sub esp, 0x14
movaps xmm0, xmmword [0x40a480]
movups xmmword [esp], xmm0
mov dword [esp + 0x10], 0x80040002
call eax
test eax, eax
je 0x4041db
push 0x80040002
push 2
call dword [sym.imp.USER32.dll_ExitWindowsEx]
test eax, eax
jne 0x4041e2
push 9
call fcn.0040318e
mov eax, dword [0x40a474]
mov eax, dword [eax + 0x2c]
cmp eax, 0xffffffff
cmovne ebx, eax
push ebx
call dword [sym.imp.KERNEL32.dll_ExitProcess]
push 0x200010
push eax
call fcn.004069b0
push 2
call dword [sym.imp.KERNEL32.dll_ExitProcess]