Function at 0x406d70
Capabilities:
Create process on windows
Get comspec environment variable
Query environment variable
Self delete
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x698
push esi
push edi
mov dword [ebp - 0x40], 0
push 0x208
push 0
lea eax, [ebp - 0x288]
push eax
call fcn.00408d30
add esp, 0xc
push 0x208
push 0
lea ecx, [ebp - 0x698]
push ecx
call fcn.00408d30
add esp, 0xc
push 0x208
push 0
lea edx, [ebp - 0x490]
push edx
call fcn.00408d30
add esp, 0xc
push 0x104
lea eax, [ebp - 0x288]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
je 0x406fbe
push 0x104
lea ecx, [ebp - 0x288]
push ecx
lea edx, [ebp - 0x288]
push edx
call dword [sym.imp.KERNEL32.dll_GetShortPathNameW]
test eax, eax
je 0x406fbe
push 0x104
lea eax, [ebp - 0x698]
push eax
push str.COMSPEC
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
je 0x406fbe
mov dword [ebp - 0x24], str._c_del
lea ecx, [ebp - 0x490]
mov dword [ebp - 0x10], ecx
mov edx, dword [ebp - 0x10]
mov dword [ebp - 0x44], edx
mov eax, dword [ebp - 0x24]
mov cx, word [eax]
mov word [ebp - 2], cx
mov edx, dword [ebp - 0x10]
mov ax, word [ebp - 2]
mov word [edx], ax
mov ecx, dword [ebp - 0x24]
add ecx, 2
mov dword [ebp - 0x24], ecx
mov edx, dword [ebp - 0x10]
add edx, 2
mov dword [ebp - 0x10], edx
cmp word [ebp - 2], 0
jne 0x406e36
lea eax, [ebp - 0x288]
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 8]
mov dword [ebp - 0x28], ecx
mov edx, dword [ebp - 8]
mov ax, word [edx]
mov word [ebp - 0x1a], ax
add dword [ebp - 8], 2
cmp word [ebp - 0x1a], 0
jne 0x406e72
mov ecx, dword [ebp - 8]
sub ecx, dword [ebp - 0x28]
mov edx, dword [ebp - 0x28]
mov dword [ebp - 0x30], edx
mov dword [ebp - 0x34], ecx
lea eax, [ebp - 0x490]
add eax, 0xfffffffe
mov dword [ebp - 0x14], eax
mov ecx, dword [ebp - 0x14]
mov dx, word [ecx + 2]
mov word [ebp - 0x1c], dx
add dword [ebp - 0x14], 2
cmp word [ebp - 0x1c], 0
jne 0x406ea2
mov edi, dword [ebp - 0x14]
mov esi, dword [ebp - 0x30]
mov eax, dword [ebp - 0x34]
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov dword [ebp - 0xc], str.___nul
mov ecx, dword [ebp - 0xc]
mov dword [ebp - 0x2c], ecx
mov edx, dword [ebp - 0xc]
mov ax, word [edx]
mov word [ebp - 0x1e], ax
add dword [ebp - 0xc], 2
cmp word [ebp - 0x1e], 0
jne 0x406edc
mov ecx, dword [ebp - 0xc]
sub ecx, dword [ebp - 0x2c]
mov edx, dword [ebp - 0x2c]
mov dword [ebp - 0x38], edx
mov dword [ebp - 0x3c], ecx
lea eax, [ebp - 0x490]
add eax, 0xfffffffe
mov dword [ebp - 0x18], eax
mov ecx, dword [ebp - 0x18]
mov dx, word [ecx + 2]
mov word [ebp - 0x20], dx
add dword [ebp - 0x18], 2
cmp word [ebp - 0x20], 0
jne 0x406f0c
mov edi, dword [ebp - 0x18]
mov esi, dword [ebp - 0x38]
mov eax, dword [ebp - 0x3c]
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov dword [ebp - 0x80], 0x3c
mov dword [ebp - 0x78], 0
mov dword [ebp - 0x74], str.Open
lea ecx, [ebp - 0x698]
mov dword [ebp - 0x70], ecx
lea edx, [ebp - 0x490]
mov dword [ebp - 0x6c], edx
mov dword [ebp - 0x68], 0
mov dword [ebp - 0x64], 0
mov dword [ebp - 0x7c], 0x40
lea eax, [ebp - 0x80]
push eax
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
test eax, eax
je 0x406fbe
push 0x40
mov ecx, dword [ebp - 0x48]
push ecx
call dword [sym.imp.KERNEL32.dll_SetPriorityClass]
push 1
mov edx, dword [ebp - 0x48]
push edx
call dword [sym.imp.KERNEL32.dll_SetProcessPriorityBoost]
push 0
lea eax, [ebp - 0x288]
push eax
push 5
push 4
call dword [sym.imp.SHELL32.dll_SHChangeNotify]
push 0
call dword [sym.imp.KERNEL32.dll_ExitProcess]
xor eax, eax
pop edi
pop esi
mov esp, ebp
pop ebp
ret