Function at 0x40149a
Capabilities:
Accept command line arguments
Create process on windows
Get common file path
Query environment variable
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x264
push ebx
push esi
xor esi, esi
push edi
mov dword [ebp - 4], esi
mov dword [ebp - 0x18], esi
mov dword [ebp - 0xc], esi
mov dword [ebp - 0x14], esi
mov dword [ebp - 0x10], esi
xor edi, edi
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
mov ebx, eax
cmp ebx, esi
mov dword [ebp - 8], ebx
je 0x4017db
mov ax, word [ebx]
cmp ax, 0x20
ja 0x4014de
cmp ax, si
je 0x401500
cmp edi, esi
je 0x4014f8
cmp ax, 0x22
jne 0x4014e6
not edi
inc ebx
inc ebx
mov dword [ebp - 8], ebx
jmp 0x4014cc
cmp ax, 0x20
ja 0x401500
inc ebx
inc ebx
mov dword [ebp - 8], ebx
mov ax, word [ebx]
cmp ax, si
jne 0x4014ed
mov ax, word [ebx]
push 2
pop edi
or ax, di
cmp ax, 0x2f
jne 0x4015a3
mov ax, word [ebx + 2]
cmp ax, si
je 0x4015a3
lea edx, [ebx + 4]
cmp word [edx], 0x20
ja 0x4015a3
cmp dword [ebp - 4], esi
jne 0x40154d
mov ecx, eax
or ecx, 0x20
cmp cx, 0x63
jne 0x401542
mov dword [ebp - 4], 1
jmp 0x40159c
cmp cx, 0x6b
jne 0x40154d
mov dword [ebp - 4], edi
jmp 0x40159c
cmp dword [ebp - 0xc], esi
jne 0x401566
mov ecx, eax
or ecx, 0x20
cmp cx, 0x6e
jne 0x401566
mov dword [ebp - 0xc], 1
jmp 0x40159c
cmp dword [ebp - 0x14], esi
jne 0x40157f
mov ecx, eax
or ecx, 0x20
cmp cx, 0x75
jne 0x40157f
mov dword [ebp - 0x14], 1
jmp 0x40159c
cmp dword [ebp - 0x18], esi
jne 0x401595
or al, 0x20
cmp ax, 0x77
jne 0x401595
mov dword [ebp - 0x18], 1
jmp 0x40159c
mov dword [ebp - 0x10], 1
mov ebx, edx
jmp 0x4014f5
cmp dword [ebp - 0x10], esi
jne 0x401789
cmp dword [ebp - 0xc], esi
jne 0x4015b6
cmp dword [ebp - 0x14], esi
je 0x4015bf
cmp dword [ebp - 4], esi
je 0x401789
cmp word [ebx], si
jne 0x4015cd
cmp dword [ebp - 4], edi
jne 0x401789
push 0xf
xor eax, eax
cmp dword [ebp - 4], esi
pop ecx
lea edi, [ebp - 0x5c]
rep stosd dword es:[edi], eax
mov dword [ebp - 0x5c], 0x3c
mov dword [ebp - 0x58], 0x540
mov dword [ebp - 0x50], 0x401414
mov dword [ebp - 0x40], 1
jne 0x401643
mov dword [ebp - 0x4c], ebx
xor ecx, ecx
mov ax, word [ebx]
cmp ax, 0x20
ja 0x40160f
cmp ax, si
je 0x401633
cmp ecx, esi
je 0x401633
cmp ax, 0x22
jne 0x401624
not ecx
cmp ecx, esi
je 0x401621
add dword [ebp - 0x4c], 2
jmp 0x401624
mov word [ebx], si
inc ebx
inc ebx
jmp 0x4015fd
cmp word [ebx], 0x20
ja 0x401638
mov word [ebx], si
inc ebx
inc ebx
cmp word [ebx], si
jne 0x401628
mov dword [ebp - 0x48], ebx
mov ebx, dword [ebp - 0x10]
jmp 0x401747
mov edi, 0x104
push edi
lea eax, [ebp - 0x264]
push eax
push 0x401404
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
cmp eax, esi
je 0x40166e
cmp eax, edi
jae 0x40166e
lea eax, [ebp - 0x264]
mov dword [ebp - 0x4c], eax
jmp 0x401675
mov dword [ebp - 0x4c], 0x4013f4
cmp dword [ebp - 0xc], esi
jne 0x40170d
xor eax, eax
mov edi, dword [ebp - 8]
or ecx, 0xffffffff
repne scasw ax, word es:[edi]
not ecx
dec ecx
xchg ecx, eax
push esi
mov edi, eax
push esi
mov dword [ebp - 0x1c], edi
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
cmp eax, esi
mov dword [ebp - 8], eax
je 0x401784
add eax, edi
lea eax, [eax + eax + 0x28]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
cmp eax, esi
je 0x401784
mov dword [ebp - 0x10], eax
add eax, 0xc
mov edi, eax
mov esi, 0x4013e4
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
add eax, 0xe
movsd dword es:[edi], dword [esi]
push eax
push dword [ebp - 8]
movsw word es:[edi], word [esi]
mov dword [ebp - 0x20], eax
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
mov ecx, dword [ebp - 0x20]
lea eax, [ecx + eax*2]
mov ecx, dword [ebp - 0x1c]
mov edi, eax
mov esi, 0x4013d8
movsd dword es:[edi], dword [esi]
lea ecx, [ecx + ecx + 2]
movsd dword es:[edi], dword [esi]
lea edi, [eax + 8]
mov eax, ecx
shr ecx, 2
mov esi, ebx
mov ebx, dword [ebp - 0x10]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
xor esi, esi
jmp 0x401710
add ebx, 0xfffffff4
cmp dword [ebp - 0x14], esi
mov dword [ebx + 4], 0x2f0020
je 0x401724
mov dword [ebx], 0x75002f
jmp 0x40172a
mov dword [ebx], 0x200020
xor eax, eax
cmp dword [ebp - 4], 1
mov word [ebx + 0xa], 0x20
setne al
lea eax, [eax*8 + 0x63]
mov word [ebx + 8], ax
mov dword [ebp - 0x48], ebx
lea eax, [ebp - 0x5c]
push eax
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
cmp dword [ebp - 0xc], esi
mov edi, eax
jne 0x40175f
push ebx
call dword [sym.imp.KERNEL32.dll_LocalFree]
cmp edi, esi
je 0x401784
cmp dword [ebp - 0x24], esi
je 0x401781
cmp dword [ebp - 0x18], esi
je 0x401778
push 0xffffffffffffffff
push dword [ebp - 0x24]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push dword [ebp - 0x24]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push esi
jmp 0x4017dd
jmp fcn.00401420
mov esi, dword [sym.imp.msvcrt.dll_wprintf]
push 0x401370
call esi
mov dword [esp], 0x40135c
call esi
mov dword [esp], 0x4012c8
push 0x63
mov edi, 0x401048
push edi
call esi
push 0x401238
push 0x6b
push edi
call esi
push 0x4011a0
push 0x6e
push edi
call esi
push 0x401128
push 0x75
push edi
call esi
push 0x4010b0
push 0x77
push edi
call esi
add esp, 0x3c
push 0xfffffffffffffffe
call dword [sym.imp.KERNEL32.dll_ExitProcess]