Function at 0x561f20
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0xb8
vmovups xmmword [rsp + 0xa0], xmm6
mov rdi, qword [rcx + 0x10]
mov rbx, rdx
mov rbp, rcx
mov ecx, 0x28
mov qword [rsp + 0x98], rdi
call sub.msvcrt.dll_malloc
mov qword [rsp + 0x20], rbx
mov ecx, 0x14
vbroadcastsd ymm0, qword [rsp + 0x20]
mov qword [rsp + 0x88], rax
vmovups xmmword [rax], xmm0
vextractf128 xmmword [rax + 0x10], ymm0, 1
mov qword [rax + 0x20], rbx
vzeroupper
call sub.msvcrt.dll_malloc
vmovdqu xmm6, xmmword [0x0061ab50]
mov ecx, ebx
mov qword [rsp + 0x70], rax
vmovups xmmword [rax], xmm6
mov dword [rax + 0x10], 0
mov eax, 1
shl eax, cl
movsxd r15, eax
test r15, r15
jle 0x5620df
xor esi, esi
nop word [rax + rax]
mov edx, 1
mov ecx, 0x20
call sub.msvcrt.dll_calloc
test rdi, rdi
mov r12, rax
lea rax, [rdi + rdi]
mov rdx, rax
not rdx
cmovs rax, rdx
cmp rax, 0x7f
jbe 0x562a50
xor edx, edx
nop
mov r8d, eax
mov ecx, edx
shr rax, 7
or r8d, 0xffffff80
add edx, 1
mov byte [r12 + rcx], r8b
cmp rax, 0x7f
ja 0x561ff0
add rdx, r12
mov byte [rdx], al
mov ecx, 0x40
add rsi, 1
call sub.msvcrt.dll_malloc
vmovdqu xmm1, xmmword [r12]
mov ecx, 0x20
mov r13, rax
mov rax, qword [rbp + 0x18]
vmovdqu xmm2, xmmword [r12 + 0x10]
vmovdqu xmm5, xmmword [rax]
vmovups xmmword [r13], xmm5
vmovdqu xmm0, xmmword [rax + 0x10]
vmovups xmmword [r13 + 0x20], xmm1
vmovups xmmword [r13 + 0x10], xmm0
vmovups xmmword [r13 + 0x30], xmm2
call sub.msvcrt.dll_malloc
mov r9d, 0x20
mov edx, 0x40
mov rcx, r13
mov r8, rax
mov r14, rax
call fcn.00564450
mov rdx, qword [rbp + 0x10]
xor r8d, r8d
mov rcx, qword [rbp]
not rdx
and rdx, qword [rsp + 0x98]
shl edx, 5
call sub.msvcrt.dll_fseek
mov r9, qword [rbp]
mov edx, 1
mov rcx, r14
mov r8d, 0x20
call sub.msvcrt.dll_fwrite
mov rax, qword [rsp + 0x98]
mov rcx, r14
lea rdi, [rax + 1]
mov qword [rsp + 0x98], rdi
call sub.msvcrt.dll_free
mov rcx, r13
call sub.msvcrt.dll_free
mov rcx, r12
call sub.msvcrt.dll_free
cmp r15, rsi
jne 0x561fc0
mov byte [rsp + 0x5f], 5
cmp rbx, 1
je 0x562f00
nop
movsx rax, byte [rsp + 0x5f]
mov r15, qword [rsp + 0x88]
mov rcx, qword [rsp + 0x70]
mov rbx, rax
mov byte [rsp + 0x20], al
sub ebx, 1
mov rsi, qword [r15 + rax*8 - 8]
movsxd r12, dword [rcx + rax*4 - 4]
mov byte [rsp + 0x5f], bl
test bl, bl
jle 0x562183
movsx rbx, bl
lea r14, [rbx*8]
shl rbx, 2
mov rcx, r14
call sub.msvcrt.dll_malloc
mov r8, r14
mov rdx, r15
mov rcx, rax
mov r13, rax
call sub.msvcrt.dll_memcpy
mov rcx, r15
call sub.msvcrt.dll_free
mov rcx, rbx
call sub.msvcrt.dll_malloc
mov r8, rbx
mov rbx, qword [rsp + 0x70]
mov rcx, rax
mov r14, rax
mov rdx, rbx
call sub.msvcrt.dll_memcpy
mov rcx, rbx
call sub.msvcrt.dll_free
mov qword [rsp + 0x88], r13
mov qword [rsp + 0x70], r14
lea r15, [rsi - 1]
mov ecx, 0x28
call sub.msvcrt.dll_malloc
mov ecx, 0x14
mov qword [rax], r15
mov qword [rax + 8], r15
mov qword [rax + 0x10], r15
mov qword [rax + 0x18], r15
mov qword [rax + 0x20], r15
mov qword [rsp + 0x78], rax
call sub.msvcrt.dll_malloc
mov ecx, esi
mov edx, 1
mov qword [rsp + 0x80], rax
vmovups xmmword [rax], xmm6
mov dword [rax + 0x10], 0
mov eax, 1
shl eax, cl
lea ecx, [rsi - 1]
movsxd r8, eax
shl edx, cl
movsxd rax, edx
mov qword [rsp + 0x50], rax
test r12, r12
je 0x562640
mov rbx, rdi
cmp r12, 1
je 0x562a98
cmp r12, 2
je 0x562d40
cmp r12, 3
je 0x562860
lea rax, [rsi + 1]
imul rax, r8
lea rdx, [r8 + rdi]
imul rsi, rax
mov rax, qword [rsp + 0x50]
sub rdx, rsi
test rax, rax
jle 0x5625f1
add rax, rdi
sub rdx, rdi
mov rsi, rdi
mov qword [rsp + 0x68], rax
mov qword [rsp + 0x20], rax
mov qword [rsp + 0x60], rdx
nop word [rax + rax]
mov rdx, qword [rbp + 0x10]
mov rax, rsi
xor r8d, r8d
mov edi, 0
sub rax, qword [rsp + 0x50]
mov rcx, qword [rbp]
not rdx
and rdx, rax
shl edx, 5
call sub.msvcrt.dll_fseek
mov ecx, 0x20
call sub.msvcrt.dll_malloc
mov r9, qword [rbp]
mov r8d, 0x20
mov edx, 1
mov rcx, rax
mov r14, rax
call sub.msvcrt.dll_fread
mov r15, qword [rsp + 0x60]
mov rdx, qword [rbp + 0x10]
cmp rax, 0x20
cmovne r14, rdi
mov rcx, qword [rbp]
xor r8d, r8d
lea rax, [r15 + rsi]
not rdx
and rdx, rax
shl edx, 5
call sub.msvcrt.dll_fseek
mov ecx, 0x20
call sub.msvcrt.dll_malloc
mov r9, qword [rbp]
mov r8d, 0x20
mov edx, 1
mov rcx, rax
mov rbx, rax
call sub.msvcrt.dll_fread
mov rdx, qword [rbp + 0x10]
cmp rax, 0x20
mov rax, qword [rsp + 0x20]
cmovne rbx, rdi
mov rcx, qword [rbp]
xor r8d, r8d
not rdx
add rax, r15
and rdx, rax
shl edx, 5
call sub.msvcrt.dll_fseek
mov ecx, 0x20
call sub.msvcrt.dll_malloc
mov r9, qword [rbp]
mov r8d, 0x20
mov edx, 1
mov rcx, rax
mov r15, rax
call sub.msvcrt.dll_fread
mov edx, 1
mov ecx, 0x20
cmp rax, 0x20
cmovne r15, rdi
call sub.msvcrt.dll_calloc
mov r13, rax
lea rax, [rsi + rsi]
test rsi, rsi
jns 0x562363
mov rax, rsi
neg rax
lea rax, [rax + rax - 1]
cmp rax, 0x7f
jbe 0x562630
xor edx, edx
nop
mov r8d, eax
mov ecx, edx
shr rax, 7
or r8d, 0xffffff80
add edx, 1
mov byte [r13 + rcx], r8b
cmp rax, 0x7f
ja 0x562370
add rdx, r13
mov byte [rdx], al
mov ecx, pe_nt_image_headers64
call sub.msvcrt.dll_malloc
vmovdqu xmm3, xmmword [r13]
mov ecx, 0x20
mov r12, rax
mov rax, qword [rbp + 0x18]
vmovdqu xmm4, xmmword [r13 + 0x10]
lea rdi, [r12 + 0x60]
vmovdqu xmm5, xmmword [r14]
lea r11, [r12 + 0x20]
vmovdqu xmm0, xmmword [r14 + 0x10]
lea r10, [r12 + 0x40]
mov qword [rsp + 0x48], r11
vmovdqu xmm1, xmmword [rax]
mov qword [rsp + 0x40], r10
vmovups xmmword [r12], xmm1
vmovdqu xmm2, xmmword [rax + 0x10]
vmovdqu xmm1, xmmword [rbx]
vmovups xmmword [r12 + 0x20], xmm3
vmovups xmmword [r12 + 0x10], xmm2
vmovdqu xmm2, xmmword [rbx + 0x10]
vmovups xmmword [r12 + 0x30], xmm4
vmovups xmmword [r12 + 0x40], xmm5
vmovups xmmword [r12 + 0x50], xmm0
vmovups xmmword [r12 + 0x60], xmm1
vmovups xmmword [rdi + 0x10], xmm2
call sub.msvcrt.dll_malloc
mov rcx, r12
mov r9d, 0x20
mov edx, pe_nt_image_headers64
mov r8, rax
mov qword [rsp + 0x30], rax
call fcn.00564450
mov rcx, qword [rsp + 0x20]
mov qword [r13], 0
mov r10, qword [rsp + 0x40]
mov qword [r13 + 8], 0
mov r11, qword [rsp + 0x48]
mov qword [r13 + 0x10], 0
mov qword [r13 + 0x18], 0
lea rax, [rcx + rcx]
test rcx, rcx
jns 0x562480
mov rax, rcx
neg rax
lea rax, [rax + rax - 1]
cmp rax, 0x7f
jbe 0x562620
xor edx, edx
nop dword [rax]
mov r8d, eax
mov ecx, edx
shr rax, 7
or r8d, 0xffffff80
add edx, 1
mov byte [r13 + rcx], r8b
cmp rax, 0x7f
ja 0x562490
add rdx, r13
mov byte [rdx], al
mov rax, qword [rbp + 0x18]
mov ecx, 0x20
vmovdqu xmm5, xmmword [r13]
vmovdqu xmm0, xmmword [r13 + 0x10]
vmovdqu xmm1, xmmword [r14]
vmovdqu xmm3, xmmword [rax]
vmovdqu xmm2, xmmword [r14 + 0x10]
vmovups xmmword [r12], xmm3
vmovdqu xmm4, xmmword [rax + 0x10]
vmovdqu xmm3, xmmword [r15]
vmovups xmmword [r12 + 0x20], xmm5
vmovups xmmword [r12 + 0x10], xmm4
vmovdqu xmm4, xmmword [r15 + 0x10]
vmovups xmmword [r11 + 0x10], xmm0
vmovups xmmword [r12 + 0x40], xmm1
vmovups xmmword [r10 + 0x10], xmm2
vmovups xmmword [r12 + 0x60], xmm3
vmovups xmmword [rdi + 0x10], xmm4
call sub.msvcrt.dll_malloc
mov r9d, 0x20
mov edx, pe_nt_image_headers64
mov rcx, r12
mov r8, rax
mov rdi, rax
call fcn.00564450
mov rdx, qword [rbp + 0x10]
xor r8d, r8d
mov rcx, qword [rbp]
not rdx
and rdx, rsi
add rsi, 1
shl edx, 5
call sub.msvcrt.dll_fseek
mov r9, qword [rbp]
mov r8d, 0x20
mov edx, 1
mov rcx, qword [rsp + 0x30]
call sub.msvcrt.dll_fwrite
mov rdx, qword [rbp + 0x10]
xor r8d, r8d
mov rcx, qword [rbp]
not rdx
and rdx, qword [rsp + 0x20]
shl edx, 5
call sub.msvcrt.dll_fseek
mov r9, qword [rbp]
mov edx, 1
mov rcx, rdi
mov r8d, 0x20
call sub.msvcrt.dll_fwrite
mov rcx, r14
add qword [rsp + 0x98], 2
call sub.msvcrt.dll_free
mov rcx, rbx
call sub.msvcrt.dll_free
mov rcx, r15
call sub.msvcrt.dll_free
mov rcx, r13
call sub.msvcrt.dll_free
mov rcx, r12
call sub.msvcrt.dll_free
mov rcx, qword [rsp + 0x30]
call sub.msvcrt.dll_free
mov rcx, rdi
call sub.msvcrt.dll_free
add qword [rsp + 0x20], 1
cmp qword [rsp + 0x68], rsi
jne 0x562250
mov rcx, qword [rsp + 0x78]
call sub.msvcrt.dll_free
mov rcx, qword [rsp + 0x80]
call sub.msvcrt.dll_free
cmp byte [rsp + 0x5f], 0
je 0x562a60
mov rdi, qword [rsp + 0x98]
jmp 0x5620f0
mov rdx, r13
jmp 0x5624ae
mov rdx, r13
jmp 0x56238e
sub rdi, r8
mov rsi, rax
test rax, rax
jle 0x562a08
lea r12, [rdi + rax]
mov qword [rsp + 0x30], r15
mov qword [rsp + 0x20], r12
nop dword [rax]
mov rdx, qword [rbp + 0x10]
xor r8d, r8d
mov ebx, 0
mov rcx, qword [rbp]
not rdx
and rdx, rdi
shl edx, 5
call sub.msvcrt.dll_fseek
mov ecx, 0x20
call sub.msvcrt.dll_malloc
mov r9, qword [rbp]
mov r8d, 0x20
mov edx, 1
mov rcx, rax
mov r14, rax
call sub.msvcrt.dll_fread
mov rdx, qword [rbp + 0x10]
mov rcx, qword [rbp]
cmp rax, 0x20
cmovne r14, rbx
xor r8d, r8d
not rdx
and rdx, r12
shl edx, 5
call sub.msvcrt.dll_fseek
mov ecx, 0x20
call sub.msvcrt.dll_malloc
mov r9, qword [rbp]
mov r8d, 0x20
mov edx, 1
mov rcx, rax
mov r13, rax
call sub.msvcrt.dll_fread
mov edx, 1
mov ecx, 0x20
cmp rax, 0x20
cmovne r13, rbx
call sub.msvcrt.dll_calloc
mov rdx, qword [rsp + 0x98]
mov r12, rax
lea rax, [rdx + rdx]
test rdx, rdx
mov rcx, rax
not rcx
cmovs rax, rcx
cmp rax, 0x7f
jbe 0x562a20
xor edx, edx
nop word cs:[rax + rax]
mov r8d, eax
mov ecx, edx
shr rax, 7
or r8d, 0xffffff80
add edx, 1
mov byte [r12 + rcx], r8b
cmp rax, 0x7f
ja 0x562730
add rdx, r12
mov byte [rdx], al
mov ecx, pe_nt_image_headers64
add rdi, 1
call sub.msvcrt.dll_malloc
vmovdqu xmm1, xmmword [r14]
mov ecx, 0x20
mov r15, rax
mov rax, qword [rbp + 0x18]
vmovdqu xmm2, xmmword [r14 + 0x10]
vmovdqu xmm3, xmmword [r13]
vmovdqu xmm4, xmmword [r13 + 0x10]
vmovdqu xmm5, xmmword [rax]
vmovups xmmword [r15], xmm5
vmovdqu xmm0, xmmword [rax + 0x10]
vmovdqu xmm5, xmmword [r12]
vmovups xmmword [r15 + 0x40], xmm1
vmovups xmmword [r15 + 0x10], xmm0
vmovdqu xmm0, xmmword [r12 + 0x10]
vmovups xmmword [r15 + 0x20], xmm5
vmovups xmmword [r15 + 0x30], xmm0
vmovups xmmword [r15 + 0x50], xmm2
vmovups xmmword [r15 + 0x60], xmm3
vmovups xmmword [r15 + 0x70], xmm4
call sub.msvcrt.dll_malloc
mov r9d, 0x20
mov edx, pe_nt_image_headers64
mov rcx, r15
mov r8, rax
mov rbx, rax
call fcn.00564450
mov rdx, qword [rbp + 0x10]
xor r8d, r8d
mov rcx, qword [rbp]
not rdx
and rdx, qword [rsp + 0x98]
shl edx, 5
call sub.msvcrt.dll_fseek
mov r9, qword [rbp]
mov edx, 1
mov rcx, rbx
mov r8d, 0x20
call sub.msvcrt.dll_fwrite
mov rcx, rbx
add qword [rsp + 0x98], 1
call sub.msvcrt.dll_free
mov rcx, r15
call sub.msvcrt.dll_free
mov rcx, r14
call sub.msvcrt.dll_free
mov rcx, r13
call sub.msvcrt.dll_free
mov rcx, r12
call sub.msvcrt.dll_free
cmp rdi, qword [rsp + 0x20]
je 0x562a30
lea r12, [rdi + rsi]
jmp 0x562660
mov rdi, rax
test rax, rax
jle 0x562a08
lea rsi, [rbx + rax]
mov qword [rsp + 0x20], r15
nop dword [rax]
mov rdx, qword [rbp + 0x10]
mov rax, rbx
xor r8d, r8d
mov rcx, qword [rbp]
sub rax, rdi
not rdx
and rdx, rax
shl edx, 5
call sub.msvcrt.dll_fseek
mov ecx, 0x20
call sub.msvcrt.dll_malloc
mov r9, qword [rbp]
mov r8d, 0x20
mov edx, 1
mov rcx, rax
mov r13, rax
call sub.msvcrt.dll_fread
mov edx, 1
mov ecx, 0x20
cmp rax, 0x20
mov eax, 0
cmovne r13, rax
call sub.msvcrt.dll_calloc
mov r12, rax
lea rax, [rbx + rbx]
test rbx, rbx
jns 0x5628ee
mov rax, rbx
neg rax
lea rax, [rax + rax - 1]
cmp rax, 0x7f
jbe 0x562a40
xor edx, edx
nop word [rax + rax]
mov r8d, eax
mov ecx, edx
shr rax, 7
or r8d, 0xffffff80
add edx, 1
mov byte [r12 + rcx], r8b
cmp rax, 0x7f
ja 0x562900
add rdx, r12
mov byte [rdx], al
mov ecx, 0x60
add rbx, 1
call sub.msvcrt.dll_malloc
vmovdqu xmm1, xmmword [r12]
mov ecx, 0x20
mov r14, rax
mov rax, qword [rbp + 0x18]
vmovdqu xmm2, xmmword [r12 + 0x10]
vmovdqu xmm3, xmmword [r13]
vmovdqu xmm4, xmmword [r13 + 0x10]
vmovdqu xmm5, xmmword [rax]
vmovups xmmword [r14], xmm5
vmovdqu xmm0, xmmword [rax + 0x10]
vmovups xmmword [r14 + 0x20], xmm1
vmovups xmmword [r14 + 0x10], xmm0
vmovups xmmword [r14 + 0x30], xmm2
vmovups xmmword [r14 + 0x40], xmm3
vmovups xmmword [r14 + 0x50], xmm4
call sub.msvcrt.dll_malloc
mov r9d, 0x20
mov edx, 0x60
mov rcx, r14
mov r8, rax
mov r15, rax
call fcn.00564450
mov rdx, qword [rbp + 0x10]
xor r8d, r8d
mov rcx, qword [rbp]
not rdx
and rdx, qword [rsp + 0x98]
shl edx, 5
call sub.msvcrt.dll_fseek
mov r9, qword [rbp]
mov edx, 1
mov rcx, r15
mov r8d, 0x20
call sub.msvcrt.dll_fwrite
mov rcx, r15
add qword [rsp + 0x98], 1
call sub.msvcrt.dll_free
mov rcx, r14
call sub.msvcrt.dll_free
mov rcx, r13
call sub.msvcrt.dll_free
mov rcx, r12
call sub.msvcrt.dll_free
cmp rsi, rbx
jne 0x562878
mov r15, qword [rsp + 0x20]
lea r8, [rsp + 0x98]
mov rdx, r15
mov rcx, rbp
call fcn.00561be0
jmp 0x5625f1
mov rdx, r12
jmp 0x56274d
mov r15, qword [rsp + 0x30]
jmp 0x562a08
mov rdx, r12
jmp 0x56291d
mov rdx, r12
jmp 0x56200d
mov rcx, qword [rsp + 0x88]
call sub.msvcrt.dll_free
mov rcx, qword [rsp + 0x70]
vmovups xmm6, xmmword [rsp + 0xa0]
add rsp, 0xb8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
jmp sub.msvcrt.dll_free
mov rdi, rax
test rax, rax
jle 0x562c49
lea rax, [rbx + rax]
mov qword [rsp + 0x40], r15
mov qword [rsp + 0x30], rax
nop word [rax + rax]
mov rdx, qword [rbp + 0x10]
mov rax, rbx
xor r8d, r8d
mov rcx, qword [rbp]
sub rax, rdi
not rdx
and rdx, rax
shl edx, 5
call sub.msvcrt.dll_fseek
mov ecx, 0x20
call sub.msvcrt.dll_malloc
mov r9, qword [rbp]
mov r8d, 0x20
mov edx, 1
mov rcx, rax
mov r14, rax
call sub.msvcrt.dll_fread
mov edx, 1
mov ecx, 0x20
cmp rax, 0x20
mov eax, 0
cmovne r14, rax
call sub.msvcrt.dll_calloc
mov r12, rax
lea rax, [rbx + rbx]
test rbx, rbx
jns 0x562b2e
mov rax, rbx
neg rax
lea rax, [rax + rax - 1]
cmp rax, 0x7f
jbe 0x562d30
xor edx, edx
nop word [rax + rax]
mov r8d, eax
mov ecx, edx
shr rax, 7
or r8d, 0xffffff80
add edx, 1
mov byte [r12 + rcx], r8b
cmp rax, 0x7f
ja 0x562b40
add rdx, r12
mov byte [rdx], al
mov ecx, 0x60
add rbx, 1
call sub.msvcrt.dll_malloc
vmovdqu xmm5, xmmword [r12]
mov ecx, 0x20
mov r15, rax
mov rax, qword [rbp + 0x18]
vmovdqu xmm0, xmmword [r12 + 0x10]
vmovdqu xmm3, xmmword [rax]
vmovups xmmword [r15], xmm3
vmovdqu xmm4, xmmword [rax + 0x10]
vmovdqu xmm3, xmmword [r14]
vmovups xmmword [r15 + 0x20], xmm5
vmovups xmmword [r15 + 0x10], xmm4
vmovdqu xmm4, xmmword [r14 + 0x10]
vmovups xmmword [r15 + 0x30], xmm0
vmovups xmmword [r15 + 0x40], xmm3
vmovups xmmword [r15 + 0x50], xmm4
call sub.msvcrt.dll_malloc
mov r9d, 0x20
mov edx, 0x60
mov rcx, r15
mov r8, rax
mov r13, rax
call fcn.00564450
mov rdx, qword [rbp + 0x10]
xor r8d, r8d
mov rcx, qword [rbp]
not rdx
and rdx, qword [rsp + 0x98]
shl edx, 5
call sub.msvcrt.dll_fseek
mov r9, qword [rbp]
mov edx, 1
mov rcx, r13
mov r8d, 0x20
call sub.msvcrt.dll_fwrite
mov rcx, r13
add qword [rsp + 0x98], 1
call sub.msvcrt.dll_free
mov rcx, r15
call sub.msvcrt.dll_free
mov rcx, r14
call sub.msvcrt.dll_free
mov rcx, r12
call sub.msvcrt.dll_free
cmp rbx, qword [rsp + 0x30]
jne 0x562ab8
mov r15, qword [rsp + 0x40]
cmp rsi, 2
je 0x562a08
movsx esi, byte [rsp + 0x5f]
add esi, 5
movsxd rsi, esi
lea rdi, [rsi*8]
shl rsi, 2
mov rcx, rdi
sub rdi, 0x28
call sub.msvcrt.dll_malloc
mov r14, qword [rsp + 0x88]
mov r8, rdi
mov rcx, rax
mov rbx, rax
mov rdx, r14
call sub.msvcrt.dll_memcpy
mov rax, qword [rsp + 0x78]
lea r8, [rbx + rdi]
mov rcx, r14
vmovdqu xmm1, xmmword [rax]
vmovups xmmword [r8], xmm1
vmovdqu xmm1, xmmword [rax + 0x10]
mov rax, qword [rax + 0x20]
vmovups xmmword [r8 + 0x10], xmm1
vmovups xmmword [rsp + 0x30], xmm1
mov qword [r8 + 0x20], rax
movzx eax, byte [rsp + 0x20]
add eax, 4
mov byte [rsp + 0x5f], al
call sub.msvcrt.dll_free
mov rcx, rsi
sub rsi, 0x14
call sub.msvcrt.dll_malloc
mov r14, qword [rsp + 0x70]
mov r8, rsi
mov rcx, rax
mov rdi, rax
add rsi, rdi
mov rdx, r14
call sub.msvcrt.dll_memcpy
mov rax, qword [rsp + 0x80]
mov rcx, r14
vmovdqu xmm1, xmmword [rax]
mov eax, dword [rax + 0x10]
vmovups xmmword [rsi], xmm1
vmovups xmmword [rsp + 0x20], xmm1
mov dword [rsi + 0x10], eax
call sub.msvcrt.dll_free
mov qword [rsp + 0x70], rdi
mov qword [rsp + 0x88], rbx
jmp 0x5625f1
mov rdx, r12
jmp 0x562b5d
mov rdi, rax
test rax, rax
jle 0x562c49
lea rax, [rbx + rax]
mov qword [rsp + 0x40], r15
mov qword [rsp + 0x30], rax
nop word [rax + rax]
mov rdx, qword [rbp + 0x10]
mov rax, rbx
xor r8d, r8d
mov rcx, qword [rbp]
sub rax, rdi
not rdx
and rdx, rax
shl edx, 5
call sub.msvcrt.dll_fseek
mov ecx, 0x20
call sub.msvcrt.dll_malloc
mov r9, qword [rbp]
mov r8d, 0x20
mov edx, 1
mov rcx, rax
mov r14, rax
call sub.msvcrt.dll_fread
mov edx, 1
mov ecx, 0x20
cmp rax, 0x20
mov eax, 0
cmovne r14, rax
call sub.msvcrt.dll_calloc
mov r12, rax
lea rax, [rbx + rbx]
test rbx, rbx
jns 0x562dd6
mov rax, rbx
neg rax
lea rax, [rax + rax - 1]
cmp rax, 0x7f
jbe 0x562ef8
xor edx, edx
nop word [rax + rax]
mov r8d, eax
mov ecx, edx
shr rax, 7
or r8d, 0xffffff80
add edx, 1
mov byte [r12 + rcx], r8b
cmp rax, 0x7f
ja 0x562de8
add rdx, r12
mov byte [rdx], al
mov ecx, 0x60
add rbx, 1
call sub.msvcrt.dll_malloc
vmovdqu xmm5, xmmword [r12]
mov ecx, 0x20
mov r15, rax
mov rax, qword [rbp + 0x18]
vmovdqu xmm0, xmmword [r12 + 0x10]
vmovdqu xmm3, xmmword [r14]
vmovdqu xmm4, xmmword [r14 + 0x10]
vmovdqu xmm1, xmmword [rax]
vmovups xmmword [r15], xmm1
vmovdqu xmm2, xmmword [rax + 0x10]
vmovups xmmword [r15 + 0x20], xmm5
vmovups xmmword [r15 + 0x10], xmm2
vmovups xmmword [r15 + 0x30], xmm0
vmovups xmmword [r15 + 0x40], xmm3
vmovups xmmword [r15 + 0x50], xmm4
call sub.msvcrt.dll_malloc
mov r9d, 0x20
mov edx, 0x60
mov rcx, r15
mov r8, rax
mov r13, rax
call fcn.00564450
mov rdx, qword [rbp + 0x10]
xor r8d, r8d
mov rcx, qword [rbp]
not rdx
and rdx, qword [rsp + 0x98]
shl edx, 5
call sub.msvcrt.dll_fseek
mov r9, qword [rbp]
mov edx, 1
mov rcx, r13
mov r8d, 0x20
call sub.msvcrt.dll_fwrite
mov rcx, r13
add qword [rsp + 0x98], 1
call sub.msvcrt.dll_free
mov rcx, r15
call sub.msvcrt.dll_free
mov rcx, r14
call sub.msvcrt.dll_free
mov rcx, r12
call sub.msvcrt.dll_free
cmp qword [rsp + 0x30], rbx
jne 0x562d60
jmp 0x562c44
mov rdx, r12
jmp 0x562e05
lea r8, [rsp + 0x98]
mov edx, 1
mov rcx, rbp
call fcn.00561be0
nop
vmovups xmm6, xmmword [rsp + 0xa0]
add rsp, 0xb8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret