Function at 0x140003950
Capabilities:
Copy file
Create directory

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x20], rbp
push rsi
push rdi
push r14
sub rsp, 0x160
mov rax, qword [section..data]
xor rax, rsp
mov qword [rsp + 0x150], rax
mov rdi, r8
mov r14, rdx
mov rsi, qword [r8 + 0x10]
mov rbx, r8
cmp qword [r8 + 0x18], 7
jbe 0x14000398e
mov rbx, qword [r8]
test rsi, rsi
je 0x140003a70
mov ebp, pe_nt_image_headers64
mov r8d, ebp
xor edx, edx
lea rcx, [rsp + 0x50]
call sub.VCRUNTIME140.dll_memset
lea rcx, [0x140006a80]
lea rdx, [0x140006a82]
nop dword [rax]
movzx eax, word [rcx]
cmp ax, bp
jae 0x140003a0b
movzx eax, al
mov byte [rsp + rax + 0x50], 1
add rcx, 2
cmp rcx, rdx
jne 0x1400039c0
lea rcx, [rsi - 1]
mov rax, 0xffffffffffffffff
cmp rcx, rax
cmovb rax, rcx
lea r8, [rbx + rax*2]
nop
movzx eax, word [r8]
cmp ax, bp
jae 0x140003a00
cmp byte [rsp + rax + 0x50], 0
jne 0x140003a68
cmp r8, rbx
je 0x140003a70
sub r8, 2
jmp 0x1400039f0
lea rcx, [rsi - 1]
mov rax, 0xffffffffffffffff
cmp rcx, rax
cmovb rax, rcx
lea r8, [rbx + rax*2]
mov r9d, 0x5c
nop word [rax + rax]
mov eax, 1
movzx edx, word [r8]
lea rcx, [0x140006a80]
cmp r9w, dx
je 0x140003a68
cmp rax, 1
je 0x140003a5d
dec rax
add rcx, 2
cmp word [rcx], dx
jne 0x140003a46
test rcx, rcx
jne 0x140003a68
cmp r8, rbx
je 0x140003a70
sub r8, 2
jmp 0x140003a30
sub r8, rbx
sar r8, 1
jmp 0x140003a77
mov r8, 0xffffffffffffffff
xorps xmm0, xmm0
movups xmmword [rsp + 0x28], xmm0
xorps xmm1, xmm1
movdqu xmmword [rsp + 0x38], xmm1
cmp rsi, r8
cmovb r8, rsi
mov rdx, rdi
cmp qword [rdi + 0x18], 7
jbe 0x140003a9c
mov rdx, qword [rdi]
lea rcx, [rsp + 0x28]
call fcn.140003440
nop
lea rcx, [rsp + 0x28]
cmp qword [rsp + 0x40], 7
cmova rcx, qword [rsp + 0x28]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x140003ada
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
je 0x140003ada
lea rdx, str.Failed_to_create_destination_folder._Error_code:
jmp 0x140003b08
cmp qword [rdi + 0x18], 7
jbe 0x140003ae4
mov rdi, qword [rdi]
cmp qword [r14 + 0x18], 7
jbe 0x140003aee
mov r14, qword [r14]
xor r8d, r8d
mov rdx, rdi
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
jne 0x140003b3c
lea rdx, str.Failed_to_copy_file._Error_code:
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcout]
call fcn.1400031e0
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
mov rcx, rbx
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___unsigned_long_int____ptr64]
lea rdx, [0x140003700]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64____cdecl___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64_____ptr64]
xor bl, bl
jmp 0x140003b3e
mov bl, 1
mov rdx, qword [rsp + 0x40]
cmp rdx, 7
jbe 0x140003b83
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x28]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140003b7e
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140003b7e
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.140004ab4
movzx eax, bl
mov rcx, qword [rsp + 0x150]
xor rcx, rsp
call fcn.140004e70
lea r11, [rsp + 0x160]
mov rbx, qword [r11 + 0x20]
mov rbp, qword [r11 + 0x38]
mov rsp, r11
pop r14
pop rdi
pop rsi
ret