Function at 0x140022f90
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rbp
push rsi
push rdi
push r12
push r14
push r15
sub rsp, 0x290
mov rdi, rdx
mov rsi, rcx
mov rcx, qword [rcx]
cmp rcx, 0xffffffffffffffff
je 0x140022fc5
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov qword [rsi], 0xffffffffffffffff
mov r8, qword [rdi]
mov rax, qword [r8 + 8]
xor r15d, r15d
mov qword [rax], r15
mov rcx, qword [r8]
test rcx, rcx
je 0x140022ff5
nop word [rax + rax]
mov rbx, qword [rcx]
mov edx, pe_nt_image_headers64
call fcn.140133e68
mov rcx, rbx
test rbx, rbx
jne 0x140022fe0
mov rax, qword [rdi]
mov qword [rax], rax
mov rax, qword [rdi]
mov qword [rax + 8], rax
mov qword [rdi + 8], r15
lea rcx, [rsi + 8]
cmp qword [rcx + 0x18], 0x10
jb 0x140023014
mov rcx, qword [rcx]
mov qword [rsp + 0x30], r15
mov dword [rsp + 0x28], r15d
mov dword [rsp + 0x20], 3
xor r9d, r9d
xor r8d, r8d
mov edx, 0xc0000000
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov qword [rsi], rax
cmp rax, 0xffffffffffffffff
je 0x14002308e
mov dword [rsp + 0x2c0], r15d
mov qword [rsp + 0x20], r15
lea r9, [rsp + 0x2c0]
mov r8d, 4
lea rdx, [rsp + 0x2c8]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_ReadFile]
mov ecx, dword [rsp + 0x2c0]
cmp ecx, 4
jae 0x1400230ac
mov rcx, qword [rsi]
cmp rcx, 0xffffffffffffffff
je 0x14002308e
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov qword [rsi], 0xffffffffffffffff
xor al, al
lea r11, [rsp + 0x290]
mov rbx, qword [r11 + 0x40]
mov rbp, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r12
pop rdi
pop rsi
ret
mov eax, dword [rsp + 0x2c8]
sub eax, ecx
mov ecx, eax
movabs rax, 0x6a63bd81a98ef607
mul rcx
mov r14, rdx
shr r14, 7
lea rcx, [rsp + 0x50]
call fcn.140016340
lea rdx, [rsi + 0x28]
cmp qword [rdx + 0x18], 0x10
jb 0x1400230e3
mov rdx, qword [rdx]
lea rcx, [rsp + 0x50]
call fcn.140016390
mov ebp, r15d
test r14d, r14d
je 0x140023224
movabs r12, 0xc7ce0c7ce0c7ce
mov qword [rsp + 0x20], r15
lea r9, [rsp + 0x2c0]
mov r8d, 0x134
lea rdx, [rsp + 0x150]
mov rcx, qword [rsi]
call qword [sym.imp.KERNEL32.dll_ReadFile]
cmp dword [rsp + 0x2c0], 0x134
jb 0x14002322b
mov r8d, 0x134
lea rdx, [rsp + 0x150]
lea rcx, [rsp + 0x50]
call fcn.140016490
test al, al
je 0x14002322b
mov rbx, qword [rdi]
cmp qword [rdi + 8], r12
je 0x14002323f
mov qword [rsp + 0x40], rdi
mov qword [rsp + 0x48], r15
mov ecx, pe_nt_image_headers64
call fcn.140133e2c
mov r9, rax
lea rdx, [rax + 0x10]
lea rcx, [rsp + 0x150]
mov r8d, 2
nop
movups xmm0, xmmword [rcx]
movups xmmword [rdx], xmm0
movups xmm1, xmmword [rcx + 0x10]
movups xmmword [rdx + 0x10], xmm1
movups xmm0, xmmword [rcx + 0x20]
movups xmmword [rdx + 0x20], xmm0
movups xmm1, xmmword [rcx + 0x30]
movups xmmword [rdx + 0x30], xmm1
movups xmm0, xmmword [rcx + 0x40]
movups xmmword [rdx + 0x40], xmm0
movups xmm1, xmmword [rcx + 0x50]
movups xmmword [rdx + 0x50], xmm1
movups xmm0, xmmword [rcx + 0x60]
movups xmmword [rdx + 0x60], xmm0
lea rdx, [rdx + 0x80]
movups xmm1, xmmword [rcx + 0x70]
movups xmmword [rdx - 0x10], xmm1
lea rcx, [rcx + 0x80]
sub r8, 1
jne 0x140023190
movups xmm0, xmmword [rcx]
movups xmmword [rdx], xmm0
movups xmm1, xmmword [rcx + 0x10]
movups xmmword [rdx + 0x10], xmm1
movups xmm0, xmmword [rcx + 0x20]
movups xmmword [rdx + 0x20], xmm0
mov eax, dword [rcx + 0x30]
mov dword [rdx + 0x30], eax
inc qword [rdi + 8]
mov rax, qword [rbx + 8]
mov qword [r9], rbx
mov qword [r9 + 8], rax
mov qword [rsp + 0x48], r15
mov qword [rbx + 8], r9
mov qword [rax], r9
inc ebp
cmp ebp, r14d
jb 0x140023103
mov al, 1
jmp 0x140023090
mov rcx, qword [rsi]
xor al, al
cmp rcx, 0xffffffffffffffff
je 0x140023090
jmp 0x140023081
lea rcx, str.list_too_long
call fcn.140101700
int3