Function at 0x140040d60
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 0x18], r8
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
mov eax, 0x1098
call fcn.140061f00
sub rsp, rax
mov rax, qword [0x140083080]
xor rax, rsp
mov qword [rsp + 0x1080], rax
lea rcx, [rsp + 0x10a0]
call fcn.140006a70
mov rcx, rax
call fcn.140036700
mov dword [rsp + 0x30], eax
lea rcx, [rsp + 0x10a0]
call fcn.140006a70
cmp dword [rax + 0x10], 0
jne 0x140040dc7
mov rax, qword [rsp + 0x10a8]
jmp 0x140041008
lea rcx, [rsp + 0x10a0]
call fcn.140006a70
mov qword [rsp + 0x70], rax
lea rcx, [rsp + 0x10a0]
call fcn.140006a70
mov rax, qword [rax + 8]
mov rcx, qword [rsp + 0x70]
mov rcx, qword [rcx]
sub rcx, rax
mov rax, rcx
cqo
sub rax, rdx
sar rax, 1
mov qword [rsp + 0x50], rax
mov eax, dword [rsp + 0x30]
sar eax, 6
cdqe
lea rcx, [0x140085850]
mov edx, dword [rsp + 0x30]
and edx, 0x3f
movsxd rdx, edx
imul rdx, rdx, 0x48
mov rax, qword [rcx + rax*8]
mov r9, qword [rsp + 0x10b0]
xor r8d, r8d
mov rdx, qword [rax + rdx + 0x30]
mov ecx, dword [rsp + 0x30]
call fcn.140043820
mov qword [rsp + 0x68], rax
mov eax, dword [rsp + 0x30]
sar eax, 6
cdqe
lea rcx, [0x140085850]
mov edx, dword [rsp + 0x30]
and edx, 0x3f
movsxd rdx, edx
imul rdx, rdx, 0x48
mov rax, qword [rcx + rax*8]
mov rax, qword [rax + rdx + 0x30]
cmp qword [rsp + 0x68], rax
je 0x140040e7f
mov rax, 0xffffffffffffffff
jmp 0x140041008
mov eax, dword [rsp + 0x30]
sar eax, 6
cdqe
lea rcx, [0x140085850]
mov edx, dword [rsp + 0x30]
and edx, 0x3f
movsxd rdx, edx
imul rdx, rdx, 0x48
mov qword [rsp + 0x78], rdx
mov rax, qword [rcx + rax*8]
mov qword [rsp + 0x20], 0
lea r9, [rsp + 0x40]
mov r8d, 0x1000
lea rdx, [rsp + 0x80]
mov rcx, qword [rsp + 0x78]
mov rcx, qword [rax + rcx + 0x28]
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x140040ee2
mov rax, 0xffffffffffffffff
jmp 0x140041008
mov r9, qword [rsp + 0x10b0]
xor r8d, r8d
mov rdx, qword [rsp + 0x10a8]
mov ecx, dword [rsp + 0x30]
call fcn.140043820
test rax, rax
jge 0x140040f0f
mov rax, 0xffffffffffffffff
jmp 0x140041008
mov eax, dword [rsp + 0x40]
cmp qword [rsp + 0x50], rax
jle 0x140040f26
mov rax, 0xffffffffffffffff
jmp 0x140041008
lea rax, [rsp + 0x80]
mov qword [rsp + 0x60], rax
mov eax, dword [rsp + 0x40]
lea rax, [rsp + rax + 0x80]
mov qword [rsp + 0x58], rax
mov rax, qword [rsp + 0x60]
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x48], 0
jmp 0x140040f73
mov rax, qword [rsp + 0x48]
inc rax
mov qword [rsp + 0x48], rax
mov rax, qword [rsp + 0x38]
inc rax
mov qword [rsp + 0x38], rax
mov rax, qword [rsp + 0x50]
cmp qword [rsp + 0x48], rax
je 0x140040fed
mov rax, qword [rsp + 0x58]
cmp qword [rsp + 0x38], rax
jae 0x140040fed
mov rax, qword [rsp + 0x38]
movsx eax, byte [rax]
cmp eax, 0xd
jne 0x140040fc4
mov rax, qword [rsp + 0x58]
dec rax
cmp qword [rsp + 0x38], rax
jae 0x140040fc2
mov rax, qword [rsp + 0x38]
movsx eax, byte [rax + 1]
cmp eax, 0xa
jne 0x140040fc2
mov rax, qword [rsp + 0x38]
inc rax
mov qword [rsp + 0x38], rax
jmp 0x140040fe8
lfence
mov rax, qword [rsp + 0x38]
movzx ecx, byte [rax]
call fcn.1400398a0
movsx rax, al
mov rcx, qword [rsp + 0x38]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x38], rax
jmp 0x140040f59
mov rax, qword [rsp + 0x60]
mov rcx, qword [rsp + 0x38]
sub rcx, rax
mov rax, rcx
mov rcx, qword [rsp + 0x68]
add rcx, rax
mov rax, rcx
mov rcx, qword [rsp + 0x1080]
xor rcx, rsp
call fcn.1400071b0
add rsp, 0x1098
ret