Function at 0x401c90
Capabilities:
Accept command line arguments
Create process on windows
Get common file path
Write and execute a file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x568
mov eax, dword [section..data]
xor eax, ebp
mov dword [ebp - 4], eax
push 0
call dword [sym.imp.KERNEL32.dll_SetLastError]
push 0x208
lea eax, [ebp - 0x494]
push 0
push eax
call sym.AntidetectWindowsAdditions.exe_nocrt_memset
add esp, 0xc
lea eax, [ebp - 0x494]
push eax
push 0x208
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
test eax, eax
je 0x4023b9
cmp eax, 0x208
jae 0x4023b9
push esi
push 0
call dword [sym.imp.KERNEL32.dll_SetLastError]
push 0x208
lea eax, [ebp - 0x28c]
push 0
push eax
call sym.AntidetectWindowsAdditions.exe_nocrt_memset
add esp, 0xc
lea eax, [ebp - 0x28c]
push 0x208
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
mov esi, eax
test esi, esi
je 0x402395
cmp esi, 0x208
jae 0x402395
lea ecx, [esi - 1]
test ecx, ecx
je 0x401d61
jmp 0x401d40
movzx eax, word [ebp + ecx*2 - 0x28c]
cmp eax, 0x2f
je 0x401d61
cmp eax, 0x5c
je 0x401d61
cmp eax, 0x3a
je 0x401d61
cmp eax, 0x2e
je 0x401dc1
sub ecx, 1
jne 0x401d40
push edi
push str.IsWow64Process
push str.kernel32
mov dword [ebp - 0x498], 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov edi, eax
test edi, edi
je 0x401ddd
lea eax, [ebp - 0x498]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
mov ecx, edi
call dword [section..rdata]
call edi
test eax, eax
jne 0x401ddd
push eax
push str.__last_error
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Unable_to_determine_the_process_type_
call fcn.00401740
add esp, 0x10
jmp 0x401deb
lea eax, [ecx + ecx]
cmp eax, 0x208
jae 0x4023dc
xor edx, edx
mov esi, ecx
mov word [ebp + eax - 0x28c], dx
jmp 0x401d61
cmp dword [ebp - 0x498], 0
mov eax, str._amd64.exe
jne 0x401df0
mov eax, str._x86.exe
push eax
mov eax, 0x104
lea edi, [ebp - 0x28c]
sub eax, esi
lea edi, [edi + esi*2]
push eax
push edi
call fcn.00402b80
add esp, 0xc
test eax, eax
jns 0x401e2e
push str.Real_installer_name_is_too_long_
push 0xe
call fcn.00401a40
add esp, 8
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004011c0
mov esp, ebp
pop ebp
ret
push ebx
push edi
call fcn.004029f0
add esp, 4
add esi, eax
xor ebx, ebx
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
mov edi, eax
test edi, edi
je 0x402032
lea esp, [esp]
movzx ecx, word [edi]
mov eax, ecx
cmp eax, 0x20
je 0x401e5f
cmp eax, 9
jne 0x401e64
add edi, 2
jmp 0x401e50
cmp eax, 0x22
jne 0x401e88
movzx eax, word [edi + 2]
add edi, 2
test ax, ax
je 0x401ea7
add edi, 2
cmp ax, 0x22
je 0x401ea7
movzx eax, word [edi]
test ax, ax
jne 0x401e75
jmp 0x401ea7
mov eax, ecx
test ax, ax
je 0x401ea7
nop
add edi, 2
cmp ax, 0x20
je 0x401ea7
cmp ax, 9
je 0x401ea7
movzx eax, word [edi]
test ax, ax
jne 0x401e90
movzx eax, word [edi]
cmp eax, 0x20
je 0x401eb4
cmp eax, 9
jne 0x401eb9
add edi, 2
jmp 0x401ea7
push edi
call fcn.004029f0
add esp, 4
mov dword [ebp - 0x49c], eax
lea ecx, [eax + esi]
lea ebx, [ecx*2 + 8]
push ebx
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov dword [ebp - 0x498], eax
test eax, eax
jne 0x401fd7
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push 0
mov esi, eax
lea eax, [ebp - 0x498]
push eax
push 7
push str.error:
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push 0
lea eax, [ebp - 0x498]
push eax
push str.Out_of_memory__
call sym.AntidetectWindowsAdditions.exe_nocrt_strlen
add esp, 4
push eax
push str.Out_of_memory__
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push 0
push 0
push 0
push 0xa
push 0
push ebx
lea eax, [ebp - 0x84]
push 0x80
push eax
call fcn.004026c0
add esp, 0x20
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov esi, eax
lea eax, [ebp - 0x4ec]
push 0
push eax
lea eax, [ebp - 0x84]
push eax
call sym.AntidetectWindowsAdditions.exe_nocrt_strlen
add esp, 4
push eax
lea eax, [ebp - 0x84]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov esi, eax
lea eax, [ebp - 0x49c]
push 0
push eax
push str._bytes_
call sym.AntidetectWindowsAdditions.exe_nocrt_strlen
add esp, 4
push eax
push str._bytes_
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push 0
lea eax, [ebp - 0x49c]
push eax
push 2
push 0x4060f0
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop ebx
pop edi
mov eax, 0xf
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004011c0
mov esp, ebp
pop ebp
ret
mov ecx, 0x22
lea ebx, [eax + 2]
mov word [eax], cx
add esi, esi
push esi
lea eax, [ebp - 0x28c]
push eax
push ebx
call sym.AntidetectWindowsAdditions.exe_nocrt_memcpy
add ebx, esi
mov eax, 0x22
add esp, 0xc
mov word [ebx], ax
mov eax, dword [ebp - 0x49c]
test eax, eax
je 0x402024
add eax, eax
mov ecx, 0x20
push eax
lea eax, [ebx + 4]
mov word [ebx + 2], cx
push edi
push eax
call sym.AntidetectWindowsAdditions.exe_nocrt_memcpy
add esp, 0xc
jmp 0x40202c
xor eax, eax
xor edi, edi
mov word [ebx + 2], ax
mov ebx, dword [ebp - 0x498]
push 0x40
lea eax, [ebp - 0x548]
mov dword [ebp - 0x54c], 0x44
push 0
push eax
call sym.AntidetectWindowsAdditions.exe_nocrt_memset
add esp, 0xc
xor eax, eax
mov dword [ebp - 0x4ac], eax
mov dword [ebp - 0x4a8], eax
mov dword [ebp - 0x4a4], eax
push 0x2e4
mov dword [ebp - 0x4a0], eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
lea eax, [ebp - 0x4ac]
push eax
lea eax, [ebp - 0x54c]
push eax
push 0
push 0
push 0
push 1
push 0
push 0
push ebx
lea eax, [ebp - 0x28c]
push eax
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
je 0x402153
push dword [ebp - 0x4a8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, dword [ebp - 0x4ac]
push 1
push 0xffffffffffffffff
push esi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObjectEx]
cmp eax, 0xc0
je 0x4020b6
cmp eax, 0x102
je 0x4020b6
test eax, eax
jne 0x40212d
lea eax, [ebp - 0x49c]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
test eax, eax
je 0x4020fc
push dword [ebp - 0x4ac]
mov esi, dword [ebp - 0x49c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x402377
push 0
push str.__last_error
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetExitCodeProcess_failed
call fcn.00401740
add esp, 0x10
mov esi, 0x10
push dword [ebp - 0x4ac]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x402377
push 0
push eax
push str.MsgWaitForMultipleObjects_failed:
call fcn.004018f0
add esp, 0xc
mov esi, 0x10
push dword [ebp - 0x4ac]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x402377
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x2e4
jne 0x40235a
push 0
push 0
push 0
push 0
lea eax, [ebp - 0x568]
push eax
call dword [sym.imp.USER32.dll_PeekMessageA]
push 6
push 0
call dword [sym.imp.ole32.dll_CoInitializeEx]
lea eax, [ebp - 0x28c]
mov dword [ebp - 0x4c8], 0
mov dword [ebp - 0x4d8], eax
lea eax, [ebp - 0x494]
mov dword [ebp - 0x4d0], eax
lea eax, [ebp - 0x4e8]
push eax
mov dword [ebp - 0x4c4], 0
mov dword [ebp - 0x4c0], 0
mov dword [ebp - 0x4bc], 0
mov dword [ebp - 0x4b8], 0
mov dword [ebp - 0x4b4], 0
mov dword [ebp - 0x4e8], 0x3c
mov dword [ebp - 0x4e4], 0x40
mov dword [ebp - 0x4e0], 0
mov dword [ebp - 0x4dc], str.runas
mov dword [ebp - 0x4d4], edi
mov dword [ebp - 0x4cc], 1
mov dword [ebp - 0x4b0], 0xffffffff
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
test eax, eax
je 0x402345
mov eax, dword [ebp - 0x4b0]
cmp eax, 0xffffffff
je 0x402334
mov dword [ebp - 0x498], eax
push 0xbf
push 0x1388
push 0
lea eax, [ebp - 0x498]
push eax
push 1
call dword [sym.imp.USER32.dll_MsgWaitForMultipleObjects]
push 1
push 0
push 0
mov esi, eax
lea eax, [ebp - 0x508]
push 0
push eax
call dword [sym.imp.USER32.dll_PeekMessageW]
test eax, eax
je 0x4022b3
lea esp, [esp]
lea eax, [ebp - 0x508]
push eax
call dword [sym.imp.USER32.dll_TranslateMessage]
lea eax, [ebp - 0x508]
push eax
call dword [sym.imp.USER32.dll_DispatchMessageW]
push 1
push 0
push 0
push 0
lea eax, [ebp - 0x508]
push eax
call dword [sym.imp.USER32.dll_PeekMessageW]
test eax, eax
jne 0x402280
test esi, esi
je 0x4022d8
cmp esi, 0x102
je 0x402243
cmp esi, 1
je 0x402243
push 0
push esi
push str.MsgWaitForMultipleObjects_failed:
call fcn.004018f0
add esp, 0xc
lea eax, [ebp - 0x49c]
push eax
push dword [ebp - 0x498]
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
test eax, eax
je 0x402306
push dword [ebp - 0x4b0]
mov esi, dword [ebp - 0x49c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x402377
push 0
push str.__last_error
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetExitCodeProcess_failed
call fcn.00401740
add esp, 0x10
mov esi, 0x10
push dword [ebp - 0x4b0]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x402377
push str.ShellExecuteExW_did_not_return_a_valid_process_handle_
push 1
call fcn.00401a40
add esp, 8
jmp 0x402375
push str._via_ShellExecuteExW_
lea eax, [ebp - 0x28c]
push eax
push str.Failed_to_execute_
push 9
jmp 0x40236d
push str._via_CreateProcessW_
lea eax, [ebp - 0x28c]
push eax
push str.Failed_to_execute_
push 8
call fcn.00401ab0
add esp, 0x10
mov esi, eax
test ebx, ebx
je 0x402382
push ebx
call dword [sym.imp.KERNEL32.dll_LocalFree]
pop ebx
pop edi
mov eax, esi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004011c0
mov esp, ebp
pop ebp
ret
push 0
push esi
push str.GetModuleFileNameW_failed:
call fcn.004018f0
add esp, 0xc
mov eax, 0xd
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004011c0
mov esp, ebp
pop ebp
ret
push 0
push eax
push str.GetCurrentDirectoryW_failed:
call fcn.004018f0
mov ecx, dword [ebp - 4]
add esp, 0xc
xor ecx, ebp
mov eax, 0xc
call fcn.004011c0
mov esp, ebp
pop ebp
ret
call fcn.004011fb
int3