Function at 0x140077778
Capabilities:
Copy file
Delete file

Disassembly:
mov rax, rsp
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rax - 0x5f]
sub rsp, 0xa0
mov rax, qword [0x14016d608]
xor rax, rsp
mov qword [rbp + 0x2f], rax
mov r13, rcx
mov rcx, qword [0x14016d090]
lea rax, [0x14016d090]
cmp rcx, rax
je 0x1400777e0
test byte [rcx + 0x1c], 1
je 0x1400777e0
cmp byte [rcx + 0x19], 4
jb 0x1400777e0
mov rcx, qword [rcx + 0x10]
lea r8, [0x140149c60]
mov edx, 0x3e
call fcn.140004968
xor eax, eax
lea rcx, [0x140147168]
mov qword [rbp + 0xf], rax
mov qword [rbp + 0x17], rax
call qword [sym.imp.OLEAUT32.dll_SysReAllocString]
xor r8d, r8d
mov qword [rbp - 0x39], rax
mov rbx, rax
test rax, rax
je 0x140077e3d
movups xmm0, xmmword [0x140156cf8]
mov ecx, dword [r13 + 0x14c]
xor eax, eax
or r12, 0xffffffffffffffff
mov qword [rbp - 0x29], r8
mov qword [rbp - 0x19], r8
mov edi, r8d
mov qword [rbp - 0x11], rax
mov esi, r8d
mov qword [rbp - 9], rax
mov r15d, r8d
mov qword [rbp - 1], rax
mov qword [rbp + 7], rax
mov qword [rbp - 0x21], r8
movdqu xmmword [rbp + 0x1f], xmm0
test ecx, ecx
je 0x1400778bd
mov eax, r15d
lea r14, [rax + rax*2]
shl r14, 6
add r14, qword [r13 + 0x108]
test byte [r14 + 0x4c], 1
je 0x14007786c
cmp dword [r14 + 0x14], 9
je 0x140077876
inc r15d
cmp r15d, ecx
jae 0x1400778bd
jmp 0x14007784c
cmp qword [r14 + 0x70], r8
jne 0x140077897
lea r8, str.pVolCtxt__m_wszRestoreTargetPath
mov edx, 0x38d
lea rcx, str.base_stor_blbengine_service_bmr.cpp
call fcn.140081b60
xor r8d, r8d
mov rdx, qword [r14 + 0x70]
test rdx, rdx
je 0x1400778bd
mov rax, r12
inc rax
cmp word [rdx + rax*2], r8w
jne 0x1400778a3
mov r8d, eax
lea rcx, [rbp - 0x39]
call fcn.140069304
mov rbx, qword [rbp - 0x39]
mov r8d, 4
lea rcx, str.__
mov rdx, rbx
call qword [sym.imp.msvcrt.dll__wcsnicmp]
test eax, eax
jne 0x140077cf5
lea edx, [rax + 0x3f]
mov word [rbx + 2], dx
cmp r15d, dword [r13 + 0x14c]
jne 0x140077947
mov rcx, qword [0x14016d090]
lea r12, [0x14016d090]
cmp rcx, r12
je 0x14007791d
test byte [rcx + 0x1c], 1
je 0x14007791d
cmp byte [rcx + 0x19], 2
jb 0x14007791d
mov rcx, qword [rcx + 0x10]
lea edx, [rax + 0x40]
lea r8, [0x140149c60]
call fcn.140004968
lea r8, [0x1401450ac]
mov edx, 0x3a2
lea rcx, str.base_stor_blbengine_service_bmr.cpp
call fcn.140081b60
mov rcx, qword [0x14016d090]
mov r14d, 0x8000ffff
jmp 0x140077d39
lea rdx, [rbp - 0x19]
mov rcx, rbx
call fcn.1400827b0
xor r13d, r13d
mov r14d, eax
test eax, eax
js 0x140077a26
mov rcx, rbx
call qword [sym.imp.OLEAUT32.dll_VariantInit]
mov eax, eax
test rax, rax
jne 0x14007798b
lea r8, str.length___0
mov edx, 0x3ae
lea rcx, str.base_stor_blbengine_service_bmr.cpp
call fcn.140081b60
jmp 0x1400779ac
mov ecx, 0x5c
cmp word [rbx + rax*2 - 2], cx
je 0x1400779ac
mov word [rbp - 0x31], cx
lea r8d, [rcx - 0x5b]
lea rcx, [rbp - 0x39]
lea rdx, [rbp - 0x31]
call fcn.140069304
lea rdx, str.EFIMicrosoftBootBCD
mov rax, r12
inc rax
cmp word [rdx + rax*2], r13w
jne 0x1400779b6
mov r8d, eax
lea rcx, [rbp - 0x39]
call fcn.140069304
mov rbx, qword [rbp - 0x39]
mov rcx, rbx
call qword [sym.imp.OLEAUT32.dll_VariantInit]
test eax, eax
je 0x140077a04
lea r8, [rbp - 0x39]
mov qword [rbp - 0x39], r13
mov rdx, rbx
xor ecx, ecx
call qword [sym.imp.OLEAUT32.dll_VarBstrCmp]
test eax, eax
js 0x140077a04
xor ecx, ecx
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
mov rdi, qword [rbp - 0x39]
mov qword [rbp - 0x29], rdi
lea rcx, [rbp + 0x1f]
call qword [sym.imp.RPCRT4.dll_UuidCreate]
lea rdx, [rbp - 0x21]
lea rcx, [rbp + 0x1f]
call qword [sym.imp.RPCRT4.dll_UuidToStringW]
test eax, eax
je 0x140077a39
mov r14d, 0x8000ffff
mov rcx, qword [0x14016d090]
lea r12, [0x14016d090]
jmp 0x140077d3c
mov rdx, qword [rbp - 0x21]
test rdx, rdx
je 0x140077a5f
mov rax, r12
inc rax
cmp word [rdx + rax*2], r13w
jne 0x140077a45
mov r8d, eax
lea rcx, [rbp - 0x29]
call fcn.140069304
mov rdi, qword [rbp - 0x29]
mov r8d, 1
mov rdx, rdi
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
jne 0x140077ae5
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx r14d, ax
or r14d, 0x80070000
test eax, eax
cmovle r14d, eax
mov rcx, qword [0x14016d090]
lea r12, [0x14016d090]
cmp rcx, r12
je 0x140077d3c
test byte [rcx + 0x1c], 1
je 0x140077d3c
cmp byte [rcx + 0x19], 2
jb 0x140077d3c
mov rcx, qword [rcx + 0x10]
lea r8, [0x140149c60]
mov edx, 0x41
mov dword [rsp + 0x28], r14d
mov r9, rbx
mov qword [rsp + 0x20], rdi
call fcn.1400059f4
mov rcx, qword [0x14016d090]
jmp 0x140077d3c
xor ecx, ecx
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
mov rcx, rbx
mov qword [rbp - 0x29], r13
call qword [sym.imp.OLEAUT32.dll_VariantInit]
test eax, eax
je 0x140077b25
lea r8, [rbp - 0x39]
mov qword [rbp - 0x39], r13
mov rdx, rbx
xor ecx, ecx
call qword [sym.imp.OLEAUT32.dll_VarBstrCmp]
test eax, eax
js 0x140077b25
xor ecx, ecx
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
mov rsi, qword [rbp - 0x39]
mov qword [rbp - 0x29], rsi
mov rdx, qword [rbp - 0x21]
test rdx, rdx
je 0x140077b48
inc r12
cmp word [rdx + r12*2], r13w
jne 0x140077b2e
mov r8d, r12d
lea rcx, [rbp - 0x29]
call fcn.140069304
mov rsi, qword [rbp - 0x29]
mov rcx, rsi
mov qword [rbp - 9], rsi
call qword [sym.imp.OLEAUT32.dll_VariantInit]
mov rdx, qword [rbp - 0x19]
mov r15w, 2
movzx ecx, ax
shl ax, 2
add cx, cx
add ax, r15w
mov word [rbp - 0x11], cx
lea rcx, [rbp - 1]
mov word [rbp - 0xf], ax
call qword [sym.imp.ntdll.dll_RtlInitUnicodeString]
lea rcx, [rbp - 1]
call qword [sym.imp.bcd.dll_BcdSetSystemStoreDevice]
test eax, eax
je 0x140077c16
cmp eax, 0x80390003
jne 0x140077bd3
mov rcx, qword [0x14016d090]
lea r12, [0x14016d090]
cmp rcx, r12
je 0x140077c1d
test byte [rcx + 0x1c], 1
je 0x140077c1d
cmp byte [rcx + 0x19], 3
jb 0x140077c1d
mov rcx, qword [rcx + 0x10]
lea r8, [0x140149c60]
mov edx, 0x42
mov r9d, 0x80390003
call fcn.140004988
jmp 0x140077c1d
mov ecx, eax
call fcn.1400399fc
mov r14d, eax
mov rcx, qword [0x14016d090]
lea r12, [0x14016d090]
cmp rcx, r12
je 0x140077ce7
test byte [rcx + 0x1c], 1
je 0x140077ce7
cmp byte [rcx + 0x19], r15b
jb 0x140077ce7
mov r9, qword [rbp + 7]
mov edx, 0x43
jmp 0x140077cd3
lea r12, [0x14016d090]
lea r8, [rbp + 0xf]
lea rcx, str.SeSystemEnvironmentPrivilege
call fcn.14008f594
mov r14d, eax
test eax, eax
jns 0x140077c6f
mov rcx, qword [0x14016d090]
cmp rcx, r12
je 0x140077ce7
test byte [rcx + 0x1c], 1
je 0x140077ce7
cmp byte [rcx + 0x19], r15b
jb 0x140077ce7
mov edx, 0x44
mov rcx, qword [rcx + 0x10]
lea r8, [0x140149c60]
call fcn.140004968
jmp 0x140077ce7
mov edx, 1
lea rcx, [rbp - 0x11]
call qword [sym.imp.bcd.dll_BcdImportStoreWithFlags]
test eax, eax
je 0x140077ce7
cmp eax, 0x80390001
jne 0x140077ca8
mov rcx, qword [0x14016d090]
cmp rcx, r12
je 0x140077ce7
test byte [rcx + 0x1c], 1
je 0x140077ce7
cmp byte [rcx + 0x19], 3
jb 0x140077ce7
mov edx, 0x45
jmp 0x140077c5d
mov ecx, eax
call fcn.1400399fc
mov r14d, eax
mov rcx, qword [0x14016d090]
cmp rcx, r12
je 0x140077ce7
test byte [rcx + 0x1c], 1
je 0x140077ce7
cmp byte [rcx + 0x19], r15b
jb 0x140077ce7
mov r9, qword [rbp - 9]
mov edx, 0x46
mov rcx, qword [rcx + 0x10]
lea r8, [0x140149c60]
mov dword [rsp + 0x20], eax
call fcn.1400058c8
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
jmp 0x140077ad9
mov rcx, qword [0x14016d090]
lea r12, [0x14016d090]
cmp rcx, r12
je 0x140077d33
test byte [rcx + 0x1c], 1
je 0x140077d33
cmp byte [rcx + 0x19], 2
jb 0x140077d33
mov rcx, qword [rcx + 0x10]
lea r8, [0x140149c60]
mov edx, 0x3f
mov r9, rbx
call fcn.140005868
mov rcx, qword [0x14016d090]
mov r14d, 0x80070057
xor r13d, r13d
cmp qword [rbp - 0x21], r13
je 0x140077d53
lea rcx, [rbp - 0x21]
call qword [sym.imp.RPCRT4.dll_RpcStringFreeW]
mov rcx, qword [0x14016d090]
mov rax, qword [rbp - 0x19]
test rax, rax
je 0x140077d6c
mov rcx, rax
call qword [sym.imp.ole32.dll_CoTaskMemFree]
mov rcx, qword [0x14016d090]
cmp dword [rbp + 0xf], r13d
je 0x140077dcc
lea rcx, [rbp + 0xf]
call fcn.14008f648
mov r15d, eax
test eax, eax
jns 0x140077dc5
mov rcx, qword [0x14016d090]
cmp rcx, r12
je 0x140077db2
test byte [rcx + 0x1c], 1
je 0x140077db2
cmp byte [rcx + 0x19], 2
jb 0x140077db2
mov rcx, qword [rcx + 0x10]
lea r8, [0x140149c60]
mov edx, 0x47
mov r9d, eax
call fcn.140004988
xor r9d, r9d
xor r8d, r8d
mov ecx, r15d
lea edx, [r9 + 1]
call qword [sym.imp.KERNEL32.dll_RaiseException]
mov rcx, qword [0x14016d090]
cmp rcx, r12
je 0x140077df2
test byte [rcx + 0x1c], 1
je 0x140077df2
cmp byte [rcx + 0x19], 4
jb 0x140077df2
mov rcx, qword [rcx + 0x10]
lea r8, [0x140149c60]
mov edx, 0x48
call fcn.140004968
mov rcx, rsi
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
mov rcx, rdi
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
mov rcx, rbx
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
mov eax, r14d
mov rcx, qword [rbp + 0x2f]
xor rcx, rsp
call fcn.14013cc00
lea r11, [rsp + 0xa0]
mov rbx, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rdi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret
mov ecx, 0x8007000e
call fcn.140001ae4
int3