Function at 0x1000336ec
Capabilities:
Get file size
Read file via mapping

Disassembly:
mov qword [rsp + 0x10], rdx
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
mov rax, rsp
sub rsp, 0xa0
mov qword [rsp + 0x90], 0xfffffffffffffffe
xor r12d, r12d
mov dword [rax - 0x60], r12d
lea rsi, [r12 - 1]
mov qword [rax - 0x48], rsi
mov qword [rax - 0x30], rsi
xor r13d, r13d
mov qword [rax - 0x40], r13
xor r15d, r15d
mov qword [rax - 0x28], r15
xor edi, edi
mov qword [rax - 0x50], rdi
xor r14d, r14d
mov qword [rax - 0x58], r14
mov qword [rax - 0x70], r14
mov dword [rax - 0x78], 0x8000080
mov dword [rax - 0x80], 3
xor r9d, r9d
mov edx, 0x80000000
lea r8d, [r12 + 7]
mov rcx, qword [rcx]
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rbx, rax
mov qword [rsp + 0x70], rax
cmp rax, rsi
je 0x1000339c2
mov qword [rsp + 0x30], r14
mov dword [rsp + 0x28], 0x8000080
mov dword [rsp + 0x20], 3
xor r9d, r9d
mov edx, 0x80000000
lea r8d, [r12 + 7]
mov rcx, qword [rsp + 0xe8]
mov rcx, qword [rcx]
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rsi, rax
mov qword [rsp + 0x58], rax
cmp rax, 0xffffffffffffffff
je 0x1000339c2
lea rdx, [rsp + 0xf4]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [rsp + 0xf0], eax
cmp eax, 0xffffffff
jne 0x1000337ea
call qword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x1000339c2
lea rdx, [rsp + 0x84]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [rsp + 0x80], eax
cmp eax, 0xffffffff
jne 0x100033815
call qword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x1000339c2
mov rax, qword [rsp + 0xf0]
cmp rax, qword [rsp + 0x80]
jne 0x1000339c2
test rax, rax
jne 0x10003383e
lea r12d, [rax + 1]
mov dword [rsp + 0x40], r12d
jmp 0x1000339c2
mov qword [rsp + 0x28], 0
mov eax, dword [rsp + 0xf0]
mov dword [rsp + 0x20], eax
mov r9d, dword [rsp + 0xf4]
xor edx, edx
lea r8d, [rdx + 2]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov r15, rax
mov qword [rsp + 0x78], rax
test rax, rax
je 0x1000339c2
mov qword [rsp + 0x28], 0
mov eax, dword [rsp + 0xf0]
mov dword [rsp + 0x20], eax
mov r9d, dword [rsp + 0xf4]
xor edx, edx
lea r8d, [rdx + 2]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov r13, rax
mov qword [rsp + 0x60], rax
test rax, rax
je 0x1000339c2
mov rax, qword [rsp + 0xf0]
mov rcx, rax
mov edx, 0x1000000
cmp rax, rdx
cmova rcx, rdx
mov qword [rsp + 0x88], rcx
xor ebx, ebx
mov qword [rsp + 0x68], rbx
sub rax, rbx
mov rdx, rcx
cmp rax, rcx
cmovb rdx, rax
mov qword [rsp + 0xf8], rdx
mov r8, rbx
shr r8, 0x20
mov qword [rsp + 0x20], rdx
mov r9d, ebx
mov edx, 4
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov r14, rax
mov qword [rsp + 0x48], rax
test rax, rax
je 0x1000339c2
mov rax, qword [rsp + 0xf8]
mov qword [rsp + 0x20], rax
mov r9d, ebx
mov r8d, dword [rsp + 0x6c]
mov edx, 4
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov rdi, rax
mov qword [rsp + 0x50], rax
test rax, rax
je 0x1000339c2
mov eax, 1
mov dword [rsp + 0x20], eax
mov r9d, eax
mov r8, qword [rsp + 0xf8]
mov rdx, rdi
mov rcx, r14
call sub.msvcrt.dll_memcmp
test eax, eax
jne 0x1000339c2
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
xor r14d, r14d
mov qword [rsp + 0x48], r14
xor edi, edi
mov qword [rsp + 0x50], rdi
add rbx, qword [rsp + 0xf8]
mov qword [rsp + 0x68], rbx
mov rax, qword [rsp + 0xf0]
cmp rbx, rax
mov rcx, qword [rsp + 0x88]
jb 0x1000338dc
lea r12d, [r14 + 1]
mov dword [rsp + 0x40], r12d
jmp 0x1000339e2
test r14, r14
je 0x1000339f0
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
test rdi, rdi
je 0x1000339fe
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
test r15, r15
je 0x100033a0c
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test r13, r13
je 0x100033a1a
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x70]
cmp rcx, 0xffffffffffffffff
je 0x100033a2b
call qword [sym.imp.KERNEL32.dll_CloseHandle]
cmp rsi, 0xffffffffffffffff
je 0x100033a3a
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, r12d
add rsp, 0xa0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
ret