Function at 0x14004f848
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x90
mov rax, qword [0x1400e5430]
xor rax, rsp
mov qword [rsp + 0x80], rax
mov r15d, dword [rcx + 8]
xor r14d, r14d
mov rdi, rcx
mov qword [rcx + 0x38], r14
mov dword [rcx + 0x5c], r14d
mov dword [rsp + 0x38], r15d
test r15d, r15d
je 0x14004fb0f
mov rcx, qword [rcx + 0x28]
call qword [sym.imp.USER32.dll_GetDC]
mov rcx, qword [0x1400ea2f8]
mov rdx, qword [rcx]
mov rsi, rax
test rdx, rdx
je 0x14004f8c3
mov rcx, rax
call qword [sym.imp.GDI32.dll_SelectObject]
mov r13, rax
jmp 0x14004f8c6
mov r13, r14
lea rdx, [rsp + 0x40]
mov rcx, rsi
call qword [sym.imp.GDI32.dll_GetTextMetricsW]
xor r9d, r9d
lea rdx, [0x1400ba358]
lea r8d, [r9 + 3]
mov rcx, rsi
mov qword [rsp + 0x20], r14
call qword [sym.imp.USER32.dll_GetTabbedTextExtentW]
movzx ebp, ax
add ebp, dword [rsp + 0x54]
mov dword [rsp + 0x3c], ebp
cmp qword [rdi + 0x40], r14
jne 0x14004f921
mov ecx, 0x13880
call fcn.140055b1c
mov qword [rdi + 0x40], rax
test rax, rax
jne 0x14004f921
mov rcx, rdi
call fcn.14004eb44
jmp 0x14004fae1
cmp qword [rdi + 8], r14
ja 0x14004f93a
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov ecx, 0xc000008c
call qword [sym.imp.KERNEL32.dll_RaiseException]
mov rax, qword [rdi]
mov rcx, qword [rdi + 0x18]
xor r9d, r9d
mov edx, dword [rax]
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov r8d, dword [rdi + 0x48]
mov rdx, qword [rdi + 0x50]
mov rcx, qword [rdi + 0x18]
lea r9, [rsp + 0x30]
mov ebx, r14d
mov dword [rsp + 0x34], r14d
mov dword [rsp + 0x30], r14d
mov qword [rsp + 0x20], r14
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x14004fae1
mov eax, dword [rsp + 0x30]
mov r12d, r14d
add eax, ebx
mov dword [rsp + 0x30], eax
je 0x14004fadd
mov ebx, eax
test eax, eax
je 0x14004faa7
mov edx, dword [rsp + 0x34]
mov r14d, dword [rdi + 0x3c]
cmp r14, qword [rdi + 8]
jb 0x14004f9c2
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov ecx, 0xc000008c
call qword [sym.imp.KERNEL32.dll_RaiseException]
lea rbp, [r14 + r14*4]
mov r14, qword [rdi]
mov ecx, dword [r14 + rbp*4 + 8]
add ecx, edx
cmp ecx, 0x9c40
ja 0x14004fadd
mov eax, dword [rdi + 0x3c]
inc eax
cmp eax, r15d
jae 0x14004fa17
mov r15d, eax
cmp r15, qword [rdi + 8]
jb 0x14004fa06
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov ecx, 0xc000008c
call qword [sym.imp.KERNEL32.dll_RaiseException]
mov rax, qword [rdi]
lea rcx, [r15 + r15*4]
mov r15d, dword [rax + rcx*4]
sub r15d, dword [r14 + rbp*4]
jmp 0x14004fa1c
mov r15d, dword [r14 + rbp*4 + 0xc]
cmp r15d, ebx
ja 0x14004fb40
mov rcx, qword [rdi + 0x20]
mov rax, qword [rdi + 0x40]
mov r10d, dword [r14 + rbp*4 + 8]
mov r11, qword [rcx]
mov r8d, dword [r14 + rbp*4 + 0xc]
mov ebx, edx
mov edx, r12d
lea r9, [rax + rbx*2]
mov qword [rsp + 0x20], r10
add rdx, qword [rdi + 0x50]
call qword [r11 + 0x18]
mov rax, qword [rdi + 0x40]
mov r8d, dword [r14 + rbp*4 + 8]
and qword [rsp + 0x20], 0
lea rdx, [rax + rbx*2]
xor r9d, r9d
mov rcx, rsi
call qword [sym.imp.USER32.dll_GetTabbedTextExtentW]
movzx ecx, ax
cmp dword [rdi + 0x5c], ecx
jge 0x14004fa7a
mov dword [rdi + 0x5c], ecx
mov edx, dword [rsp + 0x34]
add r12d, r15d
mov r15d, dword [rsp + 0x38]
mov dword [r14 + rbp*4 + 4], edx
add edx, dword [r14 + rbp*4 + 8]
mov ebx, dword [rsp + 0x30]
inc dword [rdi + 0x3c]
mov dword [rsp + 0x34], edx
sub ebx, r12d
jne 0x14004f9a1
xor r14d, r14d
mov ebx, r14d
mov r8d, dword [rdi + 0x48]
mov rcx, qword [rdi + 0x18]
mov edx, ebx
add rdx, qword [rdi + 0x50]
lea r9, [rsp + 0x30]
sub r8d, ebx
mov dword [rsp + 0x30], r14d
mov qword [rsp + 0x20], r14
call qword [sym.imp.KERNEL32.dll_ReadFile]
mov r15d, dword [rsp + 0x38]
test eax, eax
jne 0x14004f980
mov ebp, dword [rsp + 0x3c]
add dword [rdi + 0x5c], ebp
mov edx, 1
mov rcx, rdi
call fcn.14004f240
test r13, r13
je 0x14004fb02
mov rdx, r13
mov rcx, rsi
call qword [sym.imp.GDI32.dll_SelectObject]
mov rcx, qword [rdi + 0x28]
mov rdx, rsi
call qword [sym.imp.USER32.dll_ReleaseDC]
mov rcx, qword [rsp + 0x80]
xor rcx, rsp
call fcn.14007e1c0
lea r11, [rsp + 0x90]
mov rbx, qword [r11 + 0x38]
mov rbp, qword [r11 + 0x40]
mov rsi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret
mov rcx, qword [rdi + 0x50]
mov edx, r12d
mov r8d, ebx
add rdx, rcx
call fcn.14007e7a0
xor r14d, r14d
jmp 0x14004faaa