Function at 0x4228e0
Capabilities:
Create process on windows
Delete file
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4cd48d
mov eax, dword fs:[0]
push eax
sub esp, 0x7c
push esi
push edi
mov eax, dword [0x514080]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x24], edi
mov eax, dword [edi]
cmp dword [eax - 0xc], 0
jne 0x422946
push 0x14
push str.Unable_to_find_file
lea ecx, [edi + 4]
call fcn.004038b0
mov eax, dword [edi]
lea ecx, [edi + 4]
push dword [eax - 0xc]
push eax
call fcn.004025d0
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 4
call fcn.00404710
mov dword [ebp - 0x28], eax
test eax, eax
je 0x422d0e
mov ecx, dword [eax]
mov esi, dword [ecx + 0xc]
mov ecx, esi
call dword [0x4e1514]
mov ecx, dword [ebp - 0x28]
call esi
add eax, 0x10
mov dword [ebp - 0x14], eax
mov dword [ebp - 4], 1
call fcn.00404710
mov dword [ebp - 0x28], eax
test eax, eax
je 0x422d0e
mov ecx, dword [eax]
mov esi, dword [ecx + 0xc]
mov ecx, esi
call dword [0x4e1514]
mov ecx, dword [ebp - 0x28]
call esi
add eax, 0x10
mov dword [ebp - 0x1c], eax
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x1c]
push 0x4ef868
call fcn.00403720
test al, al
jne 0x4229c1
push 3
push 0x4ef868
lea ecx, [ebp - 0x1c]
call fcn.004038b0
mov byte [ebp - 4], 3
lea eax, [ebp - 0x14]
push 0x4ef908
push eax
lea eax, [ebp - 0x1c]
push eax
call fcn.00422d20
mov byte [ebp - 0xd], al
mov byte [ebp - 4], 1
or ecx, 0xffffffff
mov edx, dword [ebp - 0x1c]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], ecx
dec ecx
test ecx, ecx
jg 0x422a0b
mov edi, dword [edx]
push edx
mov eax, dword [edi]
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x4e1514]
mov ecx, edi
call esi
mov edi, dword [ebp - 0x24]
mov al, byte [ebp - 0xd]
test al, al
jne 0x422a36
push 0x38
push str.Unable_to_get_a_temp_file_for_script_output__temp_path:
lea ecx, [edi + 4]
call fcn.004038b0
mov eax, dword [ebp - 0x14]
lea ecx, [edi + 4]
push dword [eax - 0xc]
push eax
call fcn.004025d0
mov byte [ebp - 0xd], 0
jmp 0x422cca
call fcn.00404710
mov dword [ebp - 0x28], eax
test eax, eax
je 0x422d0e
mov ecx, dword [eax]
mov esi, dword [ecx + 0xc]
mov ecx, esi
call dword [0x4e1514]
mov ecx, dword [ebp - 0x28]
call esi
add eax, 0x10
mov dword [ebp - 0x18], eax
mov byte [ebp - 4], 6
push dword [ebp - 0x14]
mov eax, dword [ebp + 8]
push dword [eax]
lea eax, [ebp - 0x18]
push str.powershell.exe__NonInteractive__NoLogo__ExecutionPolicy_Unrestricted__WindowStyle_Hidden__Command___host.UI.RawUI.BufferSize__new_object_System.Management.Automation.Host.Size_1024_50________s____2____s_
push eax
call fcn.00408b70
mov esi, dword [ebp - 0x18]
xorps xmm0, xmm0
xor eax, eax
movlpd qword [ebp - 0x84], xmm0
add esp, 0x10
movlpd qword [ebp - 0x7c], xmm0
movlpd qword [ebp - 0x74], xmm0
movlpd qword [ebp - 0x6c], xmm0
movlpd qword [ebp - 0x64], xmm0
movlpd qword [ebp - 0x56], xmm0
movlpd qword [ebp - 0x4e], xmm0
mov word [ebp - 0x46], ax
mov dword [ebp - 0x88], 0x44
mov dword [ebp - 0x5c], 1
mov word [ebp - 0x58], ax
movups xmmword [ebp - 0x44], xmm0
cmp dword [esi - 4], 1
jle 0x422ada
push dword [esi - 0xc]
lea ecx, [ebp - 0x18]
call fcn.00402410
mov esi, dword [ebp - 0x18]
mov eax, dword [edi]
cmp dword [eax - 4], 1
jle 0x422aec
push dword [eax - 0xc]
mov ecx, edi
call fcn.00402410
lea eax, [ebp - 0x44]
push eax
lea eax, [ebp - 0x88]
push eax
push 0
push 0
push 0
push 0
push 0
push 0
push esi
push dword [edi]
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
jne 0x422b32
push 0x1a
push str.Unable_to_create_process:
lea ecx, [edi + 4]
call fcn.004038b0
mov eax, dword [edi]
lea ecx, [edi + 4]
push dword [eax - 0xc]
push eax
call fcn.004025d0
jmp 0x422c9b
push 0xffffffffffffffff
push dword [ebp - 0x44]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push 0
push 0x80
push 3
push 0
push 0
push SysReAllocString
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x34], 0x4ec614
mov dword [ebp - 0x30], eax
mov byte [ebp - 4], 7
cmp eax, 0xffffffff
jne 0x422b7f
mov byte [ebp - 4], 6
mov dword [ebp - 0x34], 0x4ec614
push eax
jmp 0x422c1d
push 0
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
mov dword [ebp - 0x24], esi
test esi, esi
je 0x422c0a
mov dword [ebp - 0x1c], 0
mov byte [ebp - 4], 8
lea ecx, [ebp - 0x1c]
push esi
call fcn.00408550
push 0
lea eax, [ebp - 0x20]
mov dword [ebp - 0x20], 0
push eax
push esi
mov esi, dword [ebp - 0x1c]
push esi
push dword [ebp - 0x28]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x422bf6
mov edx, dword [ebp - 0x20]
mov ecx, esi
call fcn.0040b8d0
cmp eax, 4
jne 0x422be2
mov eax, dword [ebp - 0x24]
add eax, 0xfffffffe
shr eax, 1
push eax
lea eax, [esi + 2]
push eax
jmp 0x422bee
cmp eax, 5
jne 0x422bf6
mov eax, dword [ebp - 0x24]
shr eax, 1
push eax
push esi
lea ecx, [edi + 4]
call fcn.004038b0
mov byte [ebp - 4], 7
push esi
call fcn.004a0fd2
add esp, 4
mov dword [ebp - 0x1c], 0
mov byte [ebp - 4], 6
mov eax, dword [ebp - 0x28]
mov dword [ebp - 0x34], 0x4ec614
test eax, eax
je 0x422c2a
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x30], 0
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov eax, dword [ebp + 8]
push dword [eax]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x2c], 0
push eax
push dword [ebp - 0x44]
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
test eax, eax
je 0x422c8c
mov eax, dword [ebp - 0x2c]
test eax, eax
sete byte [ebp - 0xd]
test eax, eax
je 0x422c9f
mov eax, dword [edi + 4]
cmp dword [eax - 0xc], 0
jne 0x422c9f
push 0x30
push str.Unable_to_retrieve_PowerShell_output_from_file:
lea ecx, [edi + 4]
call fcn.004038b0
mov eax, dword [ebp - 0x14]
lea ecx, [edi + 4]
push dword [eax - 0xc]
push eax
call fcn.004025d0
jmp 0x422c9f
push 0x2a
lea ecx, [edi + 4]
push str.Unable_to_retrieve_exit_code_from_process.
call fcn.004038b0
mov byte [ebp - 0xd], 0
mov byte [ebp - 4], 1
or eax, 0xffffffff
mov ecx, dword [ebp - 0x18]
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x422cca
mov edi, dword [ecx]
push ecx
mov eax, dword [edi]
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x4e1514]
mov ecx, edi
call esi
mov dword [ebp - 4], 0xffffffff
or eax, 0xffffffff
mov ecx, dword [ebp - 0x14]
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x422cf8
mov edi, dword [ecx]
push ecx
mov edx, dword [edi]
mov esi, dword [edx + 4]
mov ecx, esi
call dword [0x4e1514]
mov ecx, edi
call esi
mov al, byte [ebp - 0xd]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 4
push 0x80004005
call fcn.00402740
int3