Function at 0x140005b80
Capabilities:
Get common file path
Get disk information
Get disk size
Set current directory

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 - 0x2a8]
sub rsp, 0x380
mov rax, qword [0x14000e040]
xor rax, rsp
mov qword [rbp + 0x270], rax
xor r13d, r13d
mov r12d, r8d
mov dword [rsp + 0x54], r13d
mov r15d, edx
mov dword [rsp + 0x4c], r13d
mov rsi, rcx
mov r14d, r13d
test edx, edx
jne 0x140005bdc
lea eax, [rdx + 1]
jmp 0x140005ed9
lea rdx, [rsp + 0x60]
mov ecx, 0x104
call qword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
nop dword [rax + rax]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
nop dword [rax + rax]
xor ecx, ecx
test eax, eax
jne 0x140005c36
mov dword [rsp + 0x28], r13d
xor r9d, r9d
xor r8d, r8d
mov dword [rsp + 0x20], FDICopy
mov edx, 0x4bc
call fcn.140006208
call fcn.1400065b0
mov dword [0x14000f5a4], eax
xor eax, eax
jmp 0x140005ed9
lea rax, [rsp + 0x50]
mov dword [rsp + 0x44], r13d
lea r9, [rsp + 0x48]
mov qword [rsp + 0x20], rax
lea r8, [rsp + 0x40]
mov dword [rsp + 0x40], r13d
lea rdx, [rsp + 0x44]
mov dword [rsp + 0x48], r13d
mov dword [rsp + 0x50], r13d
call qword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceA]
nop dword [rax + rax]
test eax, eax
jne 0x140005c78
mov ebx, r13d
jmp 0x140005c9e
mov r14d, dword [rsp + 0x40]
mov r8d, 0x400
imul r14d, dword [rsp + 0x44]
mov edx, dword [rsp + 0x48]
mov ecx, r14d
call qword [sym.imp.KERNEL32.dll_MulDiv]
nop dword [rax + rax]
mov ebx, eax
test ebx, ebx
jne 0x140005d31
mov edi, 0x200
lea rcx, [rbp + 0x70]
mov r8d, edi
xor edx, edx
call sub.msvcrt.dll_memset
call fcn.1400065b0
mov dword [0x14000f5a4], eax
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov qword [rsp + 0x30], r13
xor r9d, r9d
mov r8d, eax
mov dword [rsp + 0x28], edi
lea rax, [rbp + 0x70]
xor edx, edx
mov ecx, 0x1000
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_FormatMessageA]
nop dword [rax + rax]
mov edx, 0x4b0
mov dword [rsp + 0x28], r13d
lea r9, [rbp + 0x70]
mov r8, rsi
mov dword [rsp + 0x20], FDICopy
xor ecx, ecx
call fcn.140006208
lea rcx, [rsp + 0x60]
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
nop dword [rax + rax]
jmp 0x140005c2f
mov dword [rsp + 0x38], r13d
lea rax, [rsp + 0x4c]
mov qword [rsp + 0x30], r13
xor r9d, r9d
mov qword [rsp + 0x28], rax
xor r8d, r8d
lea rax, [rsp + 0x54]
xor edx, edx
xor ecx, ecx
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_GetVolumeInformationA]
nop dword [rax + rax]
test eax, eax
jne 0x140005dc8
mov edi, 0x200
lea rcx, [rbp + 0x70]
mov r8d, edi
xor edx, edx
call sub.msvcrt.dll_memset
call fcn.1400065b0
mov dword [0x14000f5a4], eax
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov qword [rsp + 0x30], r13
xor r9d, r9d
mov r8d, eax
mov dword [rsp + 0x28], edi
lea rax, [rbp + 0x70]
xor edx, edx
mov ecx, 0x1000
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_FormatMessageA]
nop dword [rax + rax]
mov edx, 0x4f9
jmp 0x140005d00
lea rcx, [rsp + 0x60]
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
nop dword [rax + rax]
mov r8d, 6
lea rax, [rsp + 0x58]
lea rdx, [rsp + 0x58]
sub rsi, rax
lea ecx, [r8 - 5]
lea rax, [r8 - 4]
test rax, rax
je 0x140005e0a
mov al, byte [rsi + rdx]
test al, al
je 0x140005e0a
mov byte [rdx], al
add rdx, rcx
sub r8, rcx
jne 0x140005df0
test r8, r8
lea rax, [rdx - 1]
mov edi, 0x200
cmovne rax, rdx
mov byte [rax], r13b
movzx eax, r13w
cmp r14d, edi
je 0x140005e57
add edi, edi
add ax, cx
cmp ax, 8
jb 0x140005e21
jne 0x140005e57
mov dword [rsp + 0x28], r13d
xor r9d, r9d
xor r8d, r8d
mov dword [rsp + 0x20], FDICopy
mov edx, 0x4c5
xor ecx, ecx
call fcn.140006208
jmp 0x140005c2f
test byte [0x14000fec4], 8
je 0x140005e8d
test dword [rsp + 0x4c], 0x8000
je 0x140005e8d
mov r8d, dword [0x14000fec8]
lea rdx, [0x14000ed20]
movzx eax, ax
shr r8d, 2
mov edx, dword [rdx + rax*4]
add edx, edx
add r8d, dword [0x14000fec8]
jmp 0x140005ea1
mov r8d, dword [0x14000fec8]
lea rdx, [0x14000ed20]
movzx eax, ax
mov edx, dword [rdx + rax*4]
mov eax, r15d
and eax, 3
cmp al, 3
jne 0x140005ec2
lea eax, [r8 + rdx]
cmp eax, ebx
jbe 0x140005ed0
lea r9, [rsp + 0x58]
mov ecx, r12d
call fcn.1400028e8
jmp 0x140005ed9
test cl, r15b
je 0x140005ecb
cmp edx, ebx
jmp 0x140005eb1
cmp r8d, ebx
jmp 0x140005eb1
mov dword [0x14000f5a4], r13d
mov eax, ecx
mov rcx, qword [rbp + 0x270]
xor rcx, rsp
call fcn.140008f70
lea r11, [rsp + 0x380]
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