Function at 0x140004610
Capabilities:
Check if file exists
Get file attributes
Set file attributes

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
push r14
sub rsp, 0xa0
mov rax, qword [section..data]
xor rax, rsp
mov qword [rsp + 0x90], rax
mov rbx, rdx
mov rdi, rcx
xor r14d, r14d
mov rcx, rdx
cmp qword [rdx + 0x18], 0xf
jbe 0x140004650
mov rcx, qword [rdx]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x140004664
lea rdx, str.Failed_to_get_file_attributes.
jmp 0x140004687
and eax, 0xfffffffe
mov rcx, rbx
cmp qword [rbx + 0x18], 0xf
jbe 0x140004674
mov rcx, qword [rbx]
mov edx, eax
call qword [sym.imp.KERNEL32.dll_SetFileAttributesA]
test eax, eax
jne 0x1400046cb
lea rdx, str.Failed_to_remove_file_attributes.
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
call fcn.1400066e0
lea rdx, [0x1400068c0]
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]
lea rdx, str.Failed_to_remove_file_attributes.
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
call fcn.1400066e0
lea rdx, [0x1400068c0]
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]
jmp 0x1400049ea
mov rcx, qword [rbx + 0x10]
mov rax, rbx
cmp qword [rbx + 0x18], 0xf
jbe 0x1400046dc
mov rax, qword [rbx]
mov qword [rsp + 0x80], rax
mov qword [rsp + 0x88], rcx
call fcn.1400083c0
movaps xmm0, xmmword [rsp + 0x80]
movdqa xmmword [rsp + 0x80], xmm0
lea r8, [rsp + 0x80]
mov edx, eax
lea rcx, [rsp + 0x20]
call fcn.140001860
nop
mov r8d, 3
lea rdx, [rsp + 0x20]
lea rcx, [rsp + 0x80]
call fcn.140003500
movsd xmm0, qword [rax]
movsd qword [rsp + 0x40], xmm0
mov ecx, dword [rax + 8]
mov dword [rsp + 0x80], ecx
lea rax, [0x140010088]
mov qword [rsp + 0x88], rax
movaps xmm0, xmmword [rsp + 0x80]
movdqa xmmword [rsp + 0x80], xmm0
mov eax, dword [rsp + 0x40]
test eax, eax
je 0x1400047b2
cmp eax, 1
setne sil
mov rdx, qword [rsp + 0x38]
cmp rdx, 7
jbe 0x1400047c4
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x20]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400047bf
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x1400047bf
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
nop
xor sil, sil
test ecx, ecx
jne 0x140004a16
jmp 0x140004772
call fcn.140009130
test sil, sil
je 0x140004883
mov rcx, qword [rbx + 0x10]
mov rax, rbx
cmp qword [rbx + 0x18], 0xf
jbe 0x1400047de
mov rax, qword [rbx]
mov qword [rsp + 0x80], rax
mov qword [rsp + 0x88], rcx
call fcn.1400083c0
movaps xmm0, xmmword [rsp + 0x80]
movdqa xmmword [rsp + 0x80], xmm0
lea r8, [rsp + 0x80]
mov edx, eax
lea rcx, [rsp + 0x20]
call fcn.140001860
nop
lea rcx, [rsp + 0x20]
cmp qword [rsp + 0x38], 7
cmova rcx, qword [rsp + 0x20]
call fcn.140008df8
mov rdx, rax
shr rax, 0x20
test eax, eax
jne 0x140004a29
mov rdx, qword [rsp + 0x38]
cmp rdx, 7
jbe 0x140004883
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x20]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14000487e
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x14000487e
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.140009130
mov rax, qword [rbx + 0x10]
cmp qword [rbx + 0x18], 0xf
jbe 0x140004891
mov rbx, qword [rbx]
mov qword [rsp + 0x80], rbx
mov qword [rsp + 0x88], rax
call fcn.1400083c0
movaps xmm0, xmmword [rsp + 0x80]
movdqa xmmword [rsp + 0x80], xmm0
lea r8, [rsp + 0x80]
mov edx, eax
lea rcx, [rsp + 0x50]
call fcn.140001860
nop
mov rax, qword [rdi + 0x10]
cmp qword [rdi + 0x18], 0xf
jbe 0x1400048da
mov rdi, qword [rdi]
mov qword [rsp + 0x80], rdi
mov qword [rsp + 0x88], rax
call fcn.1400083c0
movaps xmm0, xmmword [rsp + 0x80]
movdqa xmmword [rsp + 0x80], xmm0
lea r8, [rsp + 0x80]
mov edx, eax
lea rcx, [rsp + 0x20]
call fcn.140001860
nop
lea rdx, [rsp + 0x50]
lea rcx, [rsp + 0x20]
call fcn.140003eb0
nop
mov rdx, qword [rsp + 0x38]
cmp rdx, 7
jbe 0x14000496a
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x20]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140004965
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140004965
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.140009130
movdqa xmm0, xmmword [0x14000bf40]
movdqu xmmword [rsp + 0x30], xmm0
mov word [rsp + 0x20], r14w
mov rdx, qword [rsp + 0x68]
cmp rdx, 7
jbe 0x1400049c3
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x50]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400049be
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x1400049be
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.140009130
lea rdx, str.File_replaced_successfully.
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
call fcn.1400066e0
lea rdx, [0x1400068c0]
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 al, 1
jmp 0x1400049ec
xor al, al
mov rcx, qword [rsp + 0x90]
xor rcx, rsp
call fcn.140009110
lea r11, [rsp + 0xa0]
mov rbx, qword [r11 + 0x10]
mov rsi, qword [r11 + 0x20]
mov rdi, qword [r11 + 0x28]
mov rsp, r11
pop r14
ret
lea r8, [rsp + 0x20]
lea rdx, [rsp + 0x80]
call fcn.140002a60
nop
shr rdx, 0x20
lea r8, [rsp + 0x20]
call fcn.1400029f0
int3