Function at 0x40380c
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
push 8
mov dword [0x42f928], eax
call fcn.004060e8
push 0
push 0x160
mov dword [0x42f9d8], eax
lea eax, [ebp - 0x170]
push eax
push 0
push 0x40a24c
call sub.SHELL32.DLL_SHGetFileInfoA
sub esp, 0xc
push str.NSIS_Error
push 0x42fa08
call fcn.00406357
add esp, 0x18
call sub.KERNEL32.dll_GetCommandLineA
push edx
push edx
push eax
push 0x438000
call fcn.00406357
push edi
push 0
call sub.KERNEL32.dll_GetModuleHandleA
add esp, 0xc
cmp byte [0x438000], 0x22
mov dword [0x42f9f8], eax
je 0x4038a5
mov edx, 0x438000
mov al, 0x20
jmp 0x4038ac
mov edx, 0x438001
mov al, 0x22
push esi
movsx eax, al
push esi
push eax
push edx
call fcn.0040616a
push ebx
xor ebx, ebx
push eax
call fcn.004083b4
mov esi, eax
mov edx, eax
add esp, 0xc
jmp 0x403947
inc edx
mov al, byte [edx]
cmp al, 0x20
je 0x4038ca
cmp al, 0x22
mov cl, 0x20
jne 0x4038da
inc edx
mov cl, 0x22
cmp byte [edx], 0x2f
jne 0x40392d
inc edx
cmp byte [edx], 0x53
jne 0x4038f2
mov al, byte [edx + 1]
or eax, 0x20
cmp al, 0x20
jne 0x4038f2
or ebx, 2
cmp dword [edx], 0x4352434e
jne 0x403907
mov al, byte [edx + 4]
or eax, 0x20
cmp al, 0x20
jne 0x403907
or ebx, 4
cmp dword [edx - 2], 0x3d442f20
lea eax, [edx - 2]
jne 0x40392d
mov dword [eax], 0
lea eax, [edx + 2]
push ecx
push ecx
push eax
push 0x438400
call fcn.00406357
pop eax
pop edx
jmp 0x403950
push eax
push eax
movsx eax, cl
push eax
push edx
call fcn.0040616a
pop edi
mov edx, eax
pop eax
xor eax, eax
cmp byte [edx], 0x22
sete al
add edx, eax
cmp byte [edx], 0
jne 0x4038cb
push ecx
push ecx
push 0x439400
push 0x400
call sub.KERNEL32.dll_GetTempPathA
pop eax
pop edx
call fcn.004037b5
test eax, eax
jne 0x4039a3
push eax
push eax
push 0x3fb
push 0x439400
call sub.KERNEL32.dll_GetWindowsDirectoryA
push str.Temp
push 0x439400
call fcn.004062d3
pop edi
pop eax
call fcn.004037b5
test eax, eax
jne 0x4039a3
xor esi, esi
mov ebx, str.Error_writing_temporary_file._Make_sure_your_temp_folder_is_valid.
jmp 0x403b57
sub esp, 0xc
push 0x439000
call sub.KERNEL32.dll_DeleteFileA
push ebx
call fcn.00403439
add esp, 0xc
test eax, eax
je 0x4039c6
mov ebx, eax
xor esi, esi
jmp 0x403b57
cmp dword [0x42f9b8], 0
je 0x403b44
push ebx
push ebx
push 0
push 0x438000
call fcn.0040616a
pop edx
pop ecx
jmp 0x4039e6
dec eax
cmp eax, 0x438000
jb 0x4039fa
cmp dword [eax], 0x3d3f5f20
jne 0x4039e5
jmp 0x403c3f
push eax
push eax
push str.nsu.tmp
push 0x439400
call fcn.004062d3
push 0x438c00
push 0x439400
call sub.KERNEL32.dll_lstrcmpiA
pop ebx
pop edi
test eax, eax
je 0x403c59
jmp 0x403a45
push ecx
push ecx
push ebx
push 0x438400
call fcn.00406357
push ebx
push 0x438800
call fcn.00406357
pop eax
pop edx
jmp 0x403b44
push eax
push eax
push 0
push 0x439400
call sub.KERNEL32.dll_CreateDirectoryA
push eax
push 0x439400
call sub.KERNEL32.dll_SetCurrentDirectoryA
add esp, 0xc
cmp byte [0x438400], 0
jne 0x403a7d
push eax
push eax
push 0x438c00
push 0x438400
call fcn.00406357
pop ebx
pop edi
push ecx
mov ebx, str.Error_launching_installer
push ecx
push esi
xor esi, esi
push section..ndata
call fcn.00406357
mov word [0x433400], 0x41
pop eax
pop edx
push eax
push eax
mov eax, dword [0x42f948]
push dword [eax + 0x120]
push 0x42a850
call fcn.0040640e
push edi
push 0x42a850
call sub.KERNEL32.dll_DeleteFileA
add esp, 0xc
test ebx, ebx
je 0x403b1f
push ecx
push 1
push 0x42a850
push 0x439c00
call sub.KERNEL32.dll_CopyFileA
pop edx
test eax, eax
je 0x403b1f
push eax
push eax
push 0
push 0x42a850
call fcn.004068c5
mov eax, dword [0x42f948]
push dword [eax + 0x124]
push 0x42a850
call fcn.0040640e
push eax
push 0x42a850
call fcn.00406dce
add esp, 0xc
test eax, eax
je 0x403b1f
sub esp, 0xc
xor ebx, ebx
push eax
call sub.KERNEL32.dll_CloseHandle
add esp, 0xc
inc esi
inc byte [0x433400]
cmp esi, 0x1a
jne 0x403a9c
push eax
xor si, si
push eax
push 0
push 0x439400
call fcn.004068c5
pop edi
pop eax
jmp 0x403b57
mov dword [0x42f914], 0xffffffff
xor ebx, ebx
call fcn.00405c36
mov esi, eax
call fcn.00403778
call sub.OLE32.dll_OleUninitialize
test ebx, ebx
je 0x403b7a
push esi
push esi
push 0x200010
push ebx
call fcn.00406d37
push ebx
push 2
jmp 0x403c3a
cmp dword [0x42f8fc], 0
je 0x403c2a
sub esp, 0xc
push 3
call fcn.004060e8
push 4
mov ebx, eax
call fcn.004060e8
push 5
mov edi, eax
call fcn.004060e8
add esp, 0xc
test ebx, ebx
mov dword [ebp - 0x180], eax
je 0x403c0c
test edi, edi
je 0x403c0c
test eax, eax
je 0x403c0c
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 0x403c0c
lea eax, [ebp - 0x16c]
push ebx
push eax
push str.SeShutdownPrivilege
push 0
call edi
lea ebx, [ebp - 0x170]
mov dword [ebp - 0x170], 1
mov dword [ebp - 0x164], 2
push ecx
push 0
push 0
push 0
push ebx
push 0
push dword [ebp - 0x10]
call dword [ebp - 0x180]
pop eax
pop edx
push eax
push eax
push 0
push 2
call sub.USER32.dll_ExitWindowsEx
pop ebx
pop edi
test eax, eax
jne 0x403c2a
sub esp, 0xc
push 9
call fcn.004030d7
add esp, 0xc
mov eax, dword [0x42f914]
cmp eax, 0xffffffff
jne 0x403c36
mov eax, esi
sub esp, 0xc
push eax
call sub.KERNEL32.dll_ExitProcess
sub esp, 0xc
lea ebx, [eax + 4]
mov byte [eax], 0
push ebx
call fcn.00406736
add esp, 0xc
test eax, eax
jne 0x403a26
xor esi, esi
mov ebx, str.Error_launching_installer
jmp 0x403b57