Function at 0x4039b8
Capabilities:
Accept command line arguments
Copy file
Create directory
Delete file
Get common file path
Get file system object information
Set current directory
Shutdown system

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x17c
call sub.COMCTL32.DLL_InitCommonControls
sub esp, 0xc
push 0x8001
call sub.KERNEL32.dll_SetErrorMode
push 0
call sub.OLE32.dll_OleInitialize
mov dword [0x49dc88], eax
push 8
call fcn.0040625f
mov dword [0x49dd38], eax
lea eax, [ebp - 0x170]
push 0
push 0x160
push eax
push 0
push 0x40a2a4
call sub.SHELL32.DLL_SHGetFileInfoA
sub esp, 0xc
push str.NSIS_Error
push 0x49dd68
call fcn.004064b0
add esp, 0x18
call sub.KERNEL32.dll_GetCommandLineA
push edx
push edx
push eax
push 0x55c400
call fcn.004064b0
push edi
push 0
call sub.KERNEL32.dll_GetModuleHandleA
add esp, 0xc
mov dword [0x49dd58], eax
cmp byte [0x55c400], 0x22
je 0x403a51
mov edx, 0x55c400
mov al, 0x20
jmp 0x403a58
mov edx, 0x55c401
mov al, 0x22
movsx eax, al
push esi
push esi
push eax
push edx
call fcn.004062e1
push ebx
push eax
call fcn.00407e7c
xor ebx, ebx
mov edi, eax
mov edx, eax
add esp, 0xc
jmp 0x403af1
inc edx
mov al, byte [edx]
cmp al, 0x20
je 0x403a76
mov cl, 0x20
cmp al, 0x22
jne 0x403a86
inc edx
mov cl, 0x22
cmp byte [edx], 0x2f
jne 0x403ad7
inc edx
cmp byte [edx], 0x53
jne 0x403a9e
mov al, byte [edx + 1]
or eax, 0x20
cmp al, 0x20
jne 0x403a9e
or ebx, 2
cmp dword [edx], 0x4352434e
jne 0x403ab3
mov al, byte [edx + 4]
or eax, 0x20
cmp al, 0x20
jne 0x403ab3
or ebx, 4
cmp dword [edx - 2], 0x3d442f20
jne 0x403ad7
mov dword [edx - 2], 0
lea eax, [edx + 2]
push ecx
push ecx
push eax
push 0x564100
call fcn.004064b0
pop eax
pop edx
jmp 0x403af6
push eax
push eax
movsx eax, cl
push eax
push edx
call fcn.004062e1
mov edx, eax
pop esi
pop eax
xor eax, eax
cmp byte [edx], 0x22
sete al
add edx, eax
cmp byte [edx], 0
jne 0x403a77
push ecx
push ecx
push 0x583500
push 0x7d00
call sub.KERNEL32.dll_GetTempPathA
pop eax
pop edx
call fcn.00403961
test eax, eax
jne 0x403b51
push eax
push eax
push 0x7cfb
push 0x583500
call sub.KERNEL32.dll_GetWindowsDirectoryA
push str.Temp
push 0x583500
call fcn.0040642c
pop esi
pop eax
call fcn.00403961
test eax, eax
jne 0x403b51
mov esi, str.Error_writing_temporary_file._Make_sure_your_temp_folder_is_valid.
mov dword [ebp - 0x180], 0
jmp 0x403d34
sub esp, 0xc
push 0x57b800
call sub.KERNEL32.dll_DeleteFileA
push ebx
call fcn.0040355d
mov dword [ebp - 0x180], 0
add esp, 0xc
mov esi, eax
test eax, eax
jne 0x403d34
cmp dword [0x49dd18], 0
je 0x403d1f
push ebx
push ebx
push 0
push 0x55c400
call fcn.004062e1
pop edx
pop ecx
jmp 0x403b9b
dec eax
cmp eax, 0x55c400
jb 0x403bdf
cmp dword [eax], 0x3d3f5f20
jne 0x403b9a
sub esp, 0xc
mov byte [eax], 0
lea ebx, [eax + 4]
push ebx
call fcn.0040687f
add esp, 0xc
test eax, eax
je 0x403c05
push eax
push eax
push ebx
push 0x564100
call fcn.004064b0
push ebx
push 0x56be00
call fcn.004064b0
pop edi
pop eax
jmp 0x403d1f
push ebx
push ebx
push str.nsu.tmp
push 0x583500
call fcn.0040642c
push 0x573b00
push 0x583500
call sub.KERNEL32.dll_lstrcmpiA
pop edx
test eax, eax
pop ecx
jne 0x403c19
mov esi, str.Error_launching_installer
mov dword [ebp - 0x180], 0
jmp 0x403d34
push eax
push eax
push 0
push 0x583500
call sub.KERNEL32.dll_CreateDirectoryA
push eax
push 0x583500
call sub.KERNEL32.dll_SetCurrentDirectoryA
add esp, 0xc
cmp byte [0x564100], 0
jne 0x403c51
push eax
push eax
push 0x573b00
push 0x564100
call fcn.004064b0
pop ebx
pop esi
push ecx
push ecx
push edi
push section..ndata
call fcn.004064b0
mov esi, str.Error_launching_installer
pop eax
mov word [0x4c7d00], 0x41
xor ebx, ebx
pop edx
push eax
push eax
mov eax, dword [0x49dca8]
push dword [eax + 0x120]
push 0x446a60
call fcn.00406567
push edi
push 0x446a60
call sub.KERNEL32.dll_DeleteFileA
add esp, 0xc
test esi, esi
je 0x403cf3
push ecx
push 1
push 0x446a60
push 0x592f00
call sub.KERNEL32.dll_CopyFileA
pop edx
test eax, eax
je 0x403cf3
push eax
push eax
push 0
push 0x446a60
call fcn.00406a08
mov eax, dword [0x49dca8]
push dword [eax + 0x124]
push 0x446a60
call fcn.00406567
push edi
push 0x446a60
call fcn.00406f0b
add esp, 0xc
test eax, eax
je 0x403cf3
sub esp, 0xc
xor esi, esi
push eax
call sub.KERNEL32.dll_CloseHandle
add esp, 0xc
inc ebx
inc byte [0x4c7d00]
cmp ebx, 0x1a
jne 0x403c70
push ecx
push ecx
push 0
push 0x583500
call fcn.00406a08
mov dword [ebp - 0x180], 0
pop eax
pop edx
jmp 0x403d34
mov dword [0x49dc74], 0xffffffff
call fcn.00405da5
mov dword [ebp - 0x180], eax
call fcn.00403904
call sub.OLE32.dll_OleUninitialize
test esi, esi
je 0x403d57
push edi
push edi
push 0x200010
push esi
call fcn.00406e74
push ebx
push 2
jmp 0x403e18
cmp dword [0x49dc5c], 0
je 0x403dff
sub esp, 0xc
push 3
call fcn.0040625f
mov ebx, eax
push 4
call fcn.0040625f
mov esi, eax
push 5
call fcn.0040625f
add esp, 0xc
mov edi, eax
test ebx, ebx
je 0x403de1
test esi, esi
je 0x403de1
test eax, eax
je 0x403de1
call sub.KERNEL32.dll_GetCurrentProcess
lea edx, [ebp - 0x10]
push ecx
push edx
push 0x28
push eax
call ebx
pop edx
test eax, eax
je 0x403de1
lea eax, [ebp - 0x16c]
push ebx
push eax
push str.SeShutdownPrivilege
push 0
call esi
lea ebx, [ebp - 0x170]
mov dword [ebp - 0x170], 1
push ecx
push 0
push 0
push 0
push ebx
push 0
push dword [ebp - 0x10]
mov dword [ebp - 0x164], 2
call edi
pop eax
pop edx
push edi
push edi
push 0
push 2
call sub.USER32.dll_ExitWindowsEx
pop ebx
test eax, eax
pop esi
jne 0x403dff
sub esp, 0xc
push 9
call fcn.0040310b
add esp, 0xc
mov eax, dword [0x49dc74]
cmp eax, 0xffffffff
je 0x403e0f
mov dword [ebp - 0x180], eax
sub esp, 0xc
push dword [ebp - 0x180]
call sub.KERNEL32.dll_ExitProcess
nop
nop
nop