Function at 0x140001300
Capabilities:
Check if file exists
Enumerate processes
Execute command
Get file attributes

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rdi
push rbp
lea rbp, [rsp - 0x2d0]
sub rsp, 0x3d0
mov rax, qword [0x140008010]
xor rax, rsp
mov qword [rbp + 0x2c0], rax
xor edi, edi
xor edx, edx
lea ecx, [rdi + 2]
call qword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
mov rbx, rax
cmp rax, 0xffffffffffffffff
jne 0x140001356
lea rdx, str.Couldnt_get_running_processes._n
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
call fcn.1400028a0
jmp 0x1400013d4
mov dword [rbp + 0x80], 0x238
lea rdx, [rbp + 0x80]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_Process32FirstW]
test eax, eax
jne 0x140001392
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rdx, str.Couldnt_get_info_of_processes._n
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
call fcn.1400028a0
jmp 0x1400013d4
lea rdx, str.Notepad.exe
lea rcx, [rbp + 0xac]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsicmp]
test eax, eax
je 0x1400013c0
lea rdx, [rbp + 0x80]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_Process32NextW]
test eax, eax
je 0x1400013c6
jmp 0x140001392
mov edi, dword [rbp + 0x88]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test rdi, rdi
jne 0x140001416
lea rcx, str.stub_process_not_found_n
call fcn.140001020
lea rcx, str.pause
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_system]
mov eax, 0xffffffff
mov rcx, qword [rbp + 0x2c0]
xor rcx, rsp
call fcn.140003750
lea r11, [rsp + 0x3d0]
mov rbx, qword [r11 + 0x10]
mov rdi, qword [r11 + 0x18]
mov rsp, r11
pop rbp
ret
mov r8d, edi
xor edx, edx
mov ecx, 0x1fffff
call qword [sym.imp.KERNEL32.dll_OpenProcess]
mov rbx, rax
test rax, rax
jne 0x140001454
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
lea rcx, str.OpenProcess_failed:_0x_X_n
call fcn.140001020
lea rcx, str.PAUSE
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_system]
lea eax, [rbx - 2]
jmp 0x1400013f2
lea rcx, str.External.dll
call qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x140001492
lea rcx, str.Dll_file_doesnt_exist_n
call fcn.140001020
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rcx, str.PAUSE
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_system]
mov eax, 0xfffffffc
jmp 0x1400013f2
xor edx, edx
mov r8d, 0x110
lea rcx, [rsp + 0x50]
call sub.VCRUNTIME140.dll_memset
lea rcx, [rsp + 0x50]
call fcn.140002340
nop
mov rax, qword [rsp + 0x50]
movsxd rcx, dword [rax + 4]
mov edx, dword [rsp + rcx + 0x60]
test dl, 6
je 0x14000151a
lea rcx, str.Opening_the_file_failed:__X_n
call fcn.140001020
lea rcx, [rsp + 0x60]
call fcn.140002770
test rax, rax
jne 0x1400014fa
mov rax, qword [rsp + 0x50]
movsxd rcx, dword [rax + 4]
lea rax, [rsp + 0x50]
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]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rcx, str.PAUSE
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_system]
mov ebx, 0xfffffffb
jmp 0x140001624
lea rdx, [rbp + 0x60]
lea rcx, [rsp + 0x50]
call qword [sym.imp.MSVCP140.dll_public:_class_std::fpos_struct__Mbstatet____cdecl_std::basic_istream_char__struct_std::char_traits_char__::tellg_void____ptr64]
mov rcx, qword [rbp + 0x60]
add rcx, qword [rbp + 0x68]
cmp rcx, 0x1000
jge 0x140001593
lea rcx, str.Filesize_invalid._n
call fcn.140001020
lea rcx, [rsp + 0x60]
call fcn.140002770
test rax, rax
jne 0x140001573
mov rax, qword [rsp + 0x50]
movsxd rcx, dword [rax + 4]
lea rax, [rsp + 0x50]
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]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rcx, str.PAUSE
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_system]
mov ebx, 0xfffffffa
jmp 0x140001624
call fcn.1400037bc
mov rdi, rax
xor r8d, r8d
xor edx, edx
lea rcx, [rsp + 0x50]
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_istream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_istream_char__struct_std::char_traits_char__::seekg_long_long___int64___int____ptr64]
mov r8, qword [rbp + 0x68]
add r8, qword [rbp + 0x60]
mov rdx, rdi
lea rcx, [rsp + 0x50]
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_istream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_istream_char__struct_std::char_traits_char__::read_char____ptr64__long_long___int64_____ptr64]
lea rcx, [rsp + 0x60]
call fcn.140002770
test rax, rax
jne 0x1400015ee
mov rax, qword [rsp + 0x50]
movsxd rcx, dword [rax + 4]
lea rax, [rsp + 0x50]
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]
mov rdx, rdi
mov rcx, rbx
call fcn.140002d10
test al, al
jne 0x140001635
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rcx, str.Error_while_loading._n
call fcn.140001020
lea rcx, str.PAUSE
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_system]
mov ebx, 0xfffffff8
lea rcx, [rsp + 0x50]
call fcn.140001650
mov eax, ebx
jmp 0x1400013f2
lea rcx, str.we_got_bread_on_deck_n
call fcn.140001020
mov ecx, 1
call qword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x140001641