Function at 0x140030e48
Capabilities:
Check if file exists
Create directory
Delete file
Get file attributes
Get file size

Disassembly:
mov r11, rsp
mov qword [r11 + 0x18], r8
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x68
xor ebx, ebx
xor ebp, ebp
and dword [rsp + 0xb0], ebx
xor r12d, r12d
and qword [r11 + 0x10], rbx
mov r14, r9
mov qword [r11 + 0x20], rbp
mov rax, r8
lea r13d, [rbx + 1]
mov r15, rdx
mov rsi, rcx
test rdx, rdx
je 0x140030e8f
mov rdi, qword [rdx]
jmp 0x140030e93
or rdi, 0xffffffffffffffff
test rsi, rsi
je 0x140030eb0
cmp qword [rcx + 0x40], rbx
mov rax, rsi
cmovne rax, qword [rcx + 0x40]
mov r12d, dword [rax + 0x24]
mov rax, qword [rsp + 0xc0]
test byte [r9 + 0x1c], 0x10
je 0x140031023
mov rcx, rax
mov r13d, 3
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
nop dword [rax + rax]
cmp eax, 0xffffffff
jne 0x140031023
mov rcx, qword [rsp + 0xc0]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
nop dword [rax + rax]
test eax, eax
jne 0x140031023
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov ecx, eax
movzx eax, ax
or eax, 0x80070000
test ecx, ecx
cmovle eax, ecx
test eax, eax
jns 0x140030f32
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
jmp 0x140030f37
mov ebx, 0x80004005
test ebx, ebx
jns 0x140031023
mov r9d, ebx
lea rcx, str.RestoreEncryptedFile
mov r8d, 0x682
call fcn.1400064e0
mov r14d, 0x80070000
test ebx, ebx
js 0x140031153
xor edx, edx
mov rcx, rsi
call fcn.140019974
mov rsi, qword [rsp + 0xc0]
bt eax, 0x11
jae 0x14003115b
lea r8, [rsp + 0xb8]
mov edx, r13d
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_OpenEncryptedFileRawW]
nop dword [rax + rax]
test eax, eax
jne 0x14003112d
xorps xmm0, xmm0
mov qword [rsp + 0x40], rdi
lea rdx, [rsp + 0x48]
mov rcx, rdi
movdqu xmmword [rsp + 0x48], xmm0
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
nop dword [rax + rax]
mov r8, qword [rsp + 0xb8]
lea rdx, [rsp + 0x40]
lea rcx, [0x140030d90]
call qword [sym.imp.ADVAPI32.dll_WriteEncryptedFileRaw]
nop dword [rax + rax]
test eax, eax
je 0x14003100a
movzx ebx, ax
or ebx, r14d
test eax, eax
cmovle ebx, eax
test ebx, ebx
jns 0x14003100a
mov r9d, ebx
lea rcx, str.RestoreEncryptedFile
mov r8d, 0x6dd
call fcn.1400064e0
mov rcx, qword [rsp + 0xb8]
call qword [sym.imp.ADVAPI32.dll_CloseEncryptedFileRaw]
nop dword [rax + rax]
jmp 0x14003115b
cmp rdi, 0xffffffffffffffff
jne 0x140030f54
lea r8, [rsp + 0xc8]
xor edx, edx
mov rcx, rsi
call fcn.1400230c4
mov rbp, qword [rsp + 0xc8]
mov rdi, rax
test rbp, rbp
je 0x1400310dc
lea rdx, [r14 + 0x20]
mov r9, rbp
mov r8, rax
mov rcx, rsi
call fcn.14002c2f0
test eax, eax
je 0x140031079
mov dword [rsp + 0xb0], 1
jmp 0x140030f54
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov ecx, eax
mov r14d, 0x80070000
movzx eax, ax
or eax, r14d
test ecx, ecx
cmovle eax, ecx
test eax, eax
jns 0x1400310b5
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
movzx ebx, ax
or ebx, r14d
test eax, eax
cmovle ebx, eax
jmp 0x1400310ba
mov ebx, 0x80004005
test ebx, ebx
jns 0x140030f62
mov r8d, 0x6a0
mov r9d, ebx
lea rcx, str.RestoreEncryptedFile
call fcn.1400064e0
jmp 0x140030f5a
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov ecx, eax
mov r14d, 0x80070000
movzx eax, ax
or eax, r14d
test ecx, ecx
cmovle eax, ecx
test eax, eax
jns 0x140031118
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
movzx ebx, ax
or ebx, r14d
test eax, eax
cmovle ebx, eax
jmp 0x14003111d
mov ebx, 0x80004005
test ebx, ebx
jns 0x140030f62
mov r8d, 0x6aa
jmp 0x1400310c8
movzx ebx, ax
or ebx, r14d
test eax, eax
cmovle ebx, eax
test ebx, ebx
jns 0x14003115b
mov r9d, ebx
lea rcx, str.RestoreEncryptedFile
mov r8d, 0x6f2
call fcn.1400064e0
jmp 0x14003115b
mov rsi, qword [rsp + 0xc0]
cmp rdi, 0xffffffffffffffff
je 0x14003117a
cmp dword [rsp + 0xb0], 0
je 0x14003117a
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
nop dword [rax + rax]
test rbp, rbp
je 0x1400311ae
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
nop dword [rax + rax]
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
nop dword [rax + rax]
mov r8, rbp
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
nop dword [rax + rax]
test ebx, ebx
js 0x140031275
test r15, r15
je 0x140031275
cmp qword [r15], 0xffffffffffffffff
je 0x1400311d4
mov rcx, qword [r15]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
nop dword [rax + rax]
and r12d, 0x10000
mov rcx, rsi
neg r12d
sbb edx, edx
and qword [rsp + 0x30], 0
xor r9d, r9d
mov dword [rsp + 0x28], 0x2200000
and edx, 0x10c0000
mov dword [rsp + 0x20], 3
add edx, 0x120100
lea r8d, [r9 + 7]
call qword [sym.imp.KERNEL32.dll_CreateFileW]
nop dword [rax + rax]
mov qword [r15], rax
cmp rax, 0xffffffffffffffff
jne 0x140031275
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov ecx, eax
movzx eax, ax
or eax, r14d
test ecx, ecx
cmovle eax, ecx
test eax, eax
jns 0x140031257
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
movzx ebx, ax
or ebx, r14d
test eax, eax
cmovle ebx, eax
jmp 0x14003125c
mov ebx, 0x80004005
test ebx, ebx
jns 0x140031275
mov r9d, ebx
lea rcx, str.RestoreEncryptedFile
mov r8d, 0x733
call fcn.1400064e0
mov eax, ebx
add rsp, 0x68
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret