Function at 0x14012e590
Capabilities:
Get file size
Read file on windows

Disassembly:
push rbp
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x27]
sub rsp, 0xc8
mov rax, qword [0x14026f088]
xor rax, rsp
mov qword [rbp + 7], rax
mov r13, qword [rbp + 0x7f]
mov r14, r9
mov r15, r8
mov r12, rdx
mov rdi, rcx
call qword [sym.imp.KERNEL32.dll_GetFileType]
cmp eax, 1
je 0x14012e5da
mov eax, 0x1000000
jmp 0x14012e7ee
lea rdx, [rbp - 0x51]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetFileInformationByHandle]
test eax, eax
jne 0x14012e5f5
mov eax, 0x200
jmp 0x14012e7ee
mov qword [rsp + 0xc0], rbx
lea rcx, [rbp - 0x19]
mov qword [rsp + 0xb8], rsi
call qword [sym.imp.KERNEL32.dll_GetSystemTime]
lea rcx, [rbp - 9]
call qword [sym.imp.KERNEL32.dll_GetLocalTime]
lea rdx, [rbp - 0x59]
lea rcx, [rbp - 0x19]
call qword [sym.imp.KERNEL32.dll_SystemTimeToFileTime]
lea rdx, [rbp - 0x69]
lea rcx, [rbp - 9]
call qword [sym.imp.KERNEL32.dll_SystemTimeToFileTime]
mov rax, qword [rbp - 0x59]
mov ebx, 0
sub rax, qword [rbp - 0x69]
mov ecx, 1
sub qword [rbp - 0x3d], rax
sub qword [rbp - 0x45], rax
sub qword [rbp - 0x4d], rax
mov eax, dword [rbp - 0x51]
mov edx, eax
and edx, 1
cmovne ebx, ecx
test al, 2
je 0x14012e665
or ebx, 2
test al, 4
je 0x14012e66c
or ebx, 4
mov ecx, eax
and ecx, 0x10
je 0x14012e676
or ebx, 0x10
test al, 0x20
je 0x14012e67d
or ebx, 0x20
mov eax, ebx
bts ebx, 0x1f
bts eax, 0x1e
test ecx, ecx
cmovne ebx, eax
bts ebx, 0x18
test edx, edx
jne 0x14012e698
bts ebx, 0x17
xor edx, edx
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
cmp eax, 0x28
jbe 0x14012e778
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
lea r9, [rbp - 0x61]
mov qword [rsp + 0x20], 0
mov r8d, 2
lea rdx, [rbp - 0x71]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_ReadFile]
xor r9d, r9d
xor r8d, r8d
mov rcx, rdi
lea edx, [r9 + 0x24]
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
lea r9, [rbp - 0x61]
mov qword [rsp + 0x20], 0
mov r8d, 4
lea rdx, [rbp - 0x69]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, 0x54ad
cmp word [rbp - 0x71], ax
jne 0x14012e778
mov edx, dword [rbp - 0x69]
lea eax, [rdx + 0x34]
cmp esi, eax
jbe 0x14012e778
xor r9d, r9d
xor r8d, r8d
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
lea r9, [rbp - 0x61]
mov qword [rsp + 0x20], 0
mov r8d, 4
lea rdx, [rbp - 0x59]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [rbp - 0x59]
cmp eax, 0x5a4d
je 0x14012e774
add eax, 0xffffbab4
cmp eax, 4
ja 0x14012e778
mov ecx, 0x15
bt ecx, eax
jae 0x14012e778
bts ebx, 0x16
test r12, r12
je 0x14012e781
mov dword [r12], ebx
mov rbx, qword [rsp + 0xc0]
test r15, r15
je 0x14012e791
mov dword [r15], esi
mov rsi, qword [rsp + 0xb8]
test r14, r14
je 0x14012e7c4
mov rcx, qword [rbp - 0x45]
call fcn.14012e4c0
mov rcx, qword [rbp - 0x3d]
mov qword [r14], rax
call fcn.14012e4c0
mov rcx, qword [rbp - 0x4d]
mov qword [r14 + 8], rax
call fcn.14012e4c0
mov qword [r14 + 0x10], rax
test r13, r13
je 0x14012e7ec
lea r8, [rbp - 0x69]
lea rdx, [rbp - 0x71]
lea rcx, [rbp - 0x3d]
call qword [sym.imp.KERNEL32.dll_FileTimeToDosDateTime]
movzx ecx, word [rbp - 0x71]
movzx eax, word [rbp - 0x69]
shl ecx, 0x10
or ecx, eax
mov dword [r13], ecx
xor eax, eax
mov rcx, qword [rbp + 7]
xor rcx, rsp
call fcn.140185a60
add rsp, 0xc8
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rbp
ret