Function at 0x140004030
Capabilities:
Delete file
Move file

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rsi
push rbp
push rdi
push r13
push r14
push r15
lea rbp, [rsp - 0x190]
sub rsp, 0x290
mov rax, qword [0x140076010]
xor rax, rsp
mov qword [rbp + 0x180], rax
mov rbx, rdx
mov rdi, rcx
mov qword [rsp + 0x30], rcx
mov qword [rsp + 0x38], rdx
xor edx, edx
mov r8d, 0x110
lea rcx, [rsp + 0x60]
call sub.VCRUNTIME140.dll_memset
mov rdx, rdi
cmp qword [rdi + 0x18], 0x10
jb 0x140004091
mov rdx, qword [rdi]
lea rcx, [rsp + 0x60]
call fcn.140009f50
mov rax, qword [rsp + 0x60]
movsxd rcx, dword [rax + 4]
lea r13, vtable.std::basic_ifstream_char__struct_std::char_traits_char__.0
mov qword [rsp + rcx + 0x60], r13
mov rax, qword [rsp + 0x60]
movsxd rcx, dword [rax + 4]
lea edx, [rcx - 0xb0]
mov dword [rsp + rcx + 0x5c], edx
xor edx, edx
mov r8d, pe_nt_image_headers64
lea rcx, [rbp + 0x70]
call sub.VCRUNTIME140.dll_memset
mov r8d, 2
lea rdx, str.temp.txt
lea rcx, [rbp + 0x70]
call fcn.1400091e0
nop
cmp qword [rbp - 0x10], 0
je 0x1400042c9
cmp qword [rbp + 0xf8], 0
je 0x1400042c9
xorps xmm0, xmm0
movups xmmword [rsp + 0x40], xmm0
mov qword [rsp + 0x50], 0
mov qword [rsp + 0x58], 0xf
mov byte [rsp + 0x40], 0
mov rax, qword [rsp + 0x60]
movsxd rcx, dword [rax + 4]
lea rax, [rsp + 0x60]
add rcx, rax
mov dl, 0xa
call qword [sym.imp.MSVCP140.dll_public:_char___cdecl_std::basic_ios_char__struct_std::char_traits_char__::widen_char_const___ptr64]
movzx r8d, al
lea rdx, [rsp + 0x40]
lea rcx, [rsp + 0x60]
call fcn.14000d230
mov rcx, qword [rax]
movsxd rdx, dword [rcx + 4]
test byte [rdx + rax + 0x10], 6
jne 0x140004203
mov rdx, rbx
cmp qword [rbx + 0x18], 0x10
jb 0x14000416e
mov rdx, qword [rbx]
lea rcx, [rsp + 0x40]
cmp qword [rsp + 0x58], 0x10
setae r15b
mov r14, qword [rsp + 0x40]
cmovae rcx, r14
mov rsi, qword [rsp + 0x50]
cmp rsi, qword [rbx + 0x10]
jne 0x14000419d
mov r8, rsi
call sub.VCRUNTIME140.dll_memcmp
test eax, eax
je 0x1400041c5
lea rdx, [rsp + 0x40]
test r15b, r15b
cmovne rdx, r14
mov r8, rsi
lea rcx, [rbp + 0x70]
call fcn.14000d3d0
lea rdx, [0x14000b8c0]
mov rcx, rax
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]
mov rax, qword [rsp + 0x60]
movsxd rcx, dword [rax + 4]
lea rax, [rsp + 0x60]
add rcx, rax
mov dl, 0xa
call qword [sym.imp.MSVCP140.dll_public:_char___cdecl_std::basic_ios_char__struct_std::char_traits_char__::widen_char_const___ptr64]
movzx r8d, al
lea rdx, [rsp + 0x40]
lea rcx, [rsp + 0x60]
call fcn.14000d230
mov rcx, qword [rax]
movsxd rdx, dword [rcx + 4]
test byte [rdx + rax + 0x10], 6
je 0x140004161
lea rcx, [rsp + 0x70]
call fcn.14000af20
test rax, rax
jne 0x140004230
mov rax, qword [rsp + 0x60]
movsxd rcx, dword [rax + 4]
lea rax, [rsp + 0x60]
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]
lea rcx, [rbp + 0x78]
call fcn.14000af20
test rax, rax
jne 0x14000425a
mov rax, qword [rbp + 0x70]
movsxd rcx, dword [rax + 4]
lea rax, [rbp + 0x70]
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, rdi
cmp qword [rdi + 0x18], 0x10
jb 0x140004267
mov rcx, qword [rdi]
call qword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll_remove]
mov rdx, rdi
cmp qword [rdi + 0x18], 0x10
jb 0x14000427a
mov rdx, qword [rdi]
lea rcx, str.temp.txt
call qword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll_rename]
nop
mov rdx, qword [rsp + 0x58]
cmp rdx, 0x10
jb 0x1400042c9
inc rdx
mov rcx, qword [rsp + 0x40]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400042c3
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x1400042c3
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400606f0
nop
mov rax, qword [rbp + 0x70]
movsxd rcx, dword [rax + 4]
lea rax, vtable.std::basic_ofstream_char__struct_std::char_traits_char__.0
mov qword [rbp + rcx + 0x70], rax
mov rax, qword [rbp + 0x70]
movsxd rcx, dword [rax + 4]
lea edx, [rcx - 0xa8]
mov dword [rbp + rcx + 0x6c], edx
lea rcx, [rbp + 0x78]
call fcn.140009ea0
lea rcx, [rbp + 0x80]
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 + 0x118]
call qword [sym.imp.MSVCP140.dll_public_virtual:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::destructor_void____ptr64]
nop
mov rax, qword [rsp + 0x60]
movsxd rcx, dword [rax + 4]
mov qword [rsp + rcx + 0x60], r13
mov rax, qword [rsp + 0x60]
movsxd rcx, dword [rax + 4]
lea edx, [rcx - 0xb0]
mov dword [rsp + rcx + 0x5c], edx
lea rcx, [rsp + 0x70]
call fcn.140009ea0
lea rcx, [rsp + 0x78]
call qword [sym.imp.MSVCP140.dll_public_virtual:_void___cdecl_std::basic_istream_char__struct_std::char_traits_char__::destructor_void____ptr64]
lea rcx, [rbp + 0x10]
call qword [sym.imp.MSVCP140.dll_public_virtual:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::destructor_void____ptr64]
nop
mov rdx, qword [rdi + 0x18]
cmp rdx, 0x10
jb 0x14000438e
mov rcx, qword [rdi]
inc rdx
cmp rdx, 0x1000
jb 0x140004389
add rdx, 0x27
mov r8, qword [rcx - 8]
sub rcx, r8
lea rax, [rcx - 8]
cmp rax, 0x1f
ja 0x140004415
mov rcx, r8
call fcn.1400606f0
mov qword [rdi + 0x10], 0
mov qword [rdi + 0x18], 0xf
mov byte [rdi], 0
mov rdx, qword [rbx + 0x18]
cmp rdx, 0x10
jb 0x1400043d7
inc rdx
mov rcx, qword [rbx]
cmp rdx, 0x1000
jb 0x1400043d2
add rdx, 0x27
mov r8, qword [rcx - 8]
sub rcx, r8
lea rax, [rcx - 8]
cmp rax, 0x1f
ja 0x14000441c
mov rcx, r8
call fcn.1400606f0
mov qword [rbx + 0x10], 0
mov qword [rbx + 0x18], 0xf
mov byte [rbx], 0
mov rcx, qword [rbp + 0x180]
xor rcx, rsp
call fcn.1400606d0
lea r11, [rsp + 0x290]
mov rbx, qword [r11 + 0x40]
mov rsi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop rdi
pop rbp
ret
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
nop
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3