Function at 0x5faeb0
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 edi, 1
mov r15, qword [rcx + 0x10]
mov rbp, rcx
mov ecx, 0x28
mov rbx, rdx
vmovq xmm6, rdx
mov qword [rsp + 0x98], r15
vpunpcklqdq xmm6, xmm6, xmm6
call sub.msvcrt.dll_malloc
mov ecx, 0x14
vmovups xmmword [rax], xmm6
vmovups xmmword [rax + 0x10], xmm6
shlx edi, edi, ebx
mov qword [rax + 0x20], rbx
mov qword [rsp + 0x88], rax
movsxd rdi, edi
call sub.msvcrt.dll_malloc
vmovups xmm6, xmmword [0x006e01a0]
mov qword [rsp + 0x70], rax
mov dword [rax + 0x10], 0
vmovups xmmword [rax], xmm6
test rdi, rdi
jle 0x5fb05c
xor esi, esi
mov edx, 1
mov ecx, 0x20
call sub.msvcrt.dll_calloc
test r15, r15
mov r12, rax
lea rax, [r15 + r15]
mov rdx, rax
not rdx
cmovs rax, rdx
cmp rax, 0x7f
jbe 0x5fba20
xor edx, edx
nop
mov r8d, eax
mov ecx, edx
shr rax, 7
inc edx
or r8d, 0xffffff80
mov byte [r12 + rcx], r8b
cmp rax, 0x7f
ja 0x5faf70
add rdx, r12
mov byte [rdx], al
mov ecx, 0x40
inc rsi
call sub.msvcrt.dll_malloc
mov ecx, 0x20
mov r13, rax
mov rax, qword [rbp + 0x18]
vmovups xmm0, xmmword [r12]
vmovups xmm1, xmmword [r12 + 0x10]
vmovups xmm4, xmmword [rax]
vmovups xmmword [r13], xmm4
vmovups xmm5, xmmword [rax + 0x10]
vmovups xmmword [r13 + 0x20], xmm0
vmovups xmmword [r13 + 0x30], xmm1
vmovups xmmword [r13 + 0x10], xmm5
call sub.msvcrt.dll_malloc
mov r9d, 0x20
mov edx, 0x40
mov rcx, r13
mov r8, rax
mov r14, rax
call fcn.005fd4a0
mov rdx, qword [rbp + 0x10]
xor r8d, r8d
mov rcx, qword [rbp]
andn rdx, rdx, qword [rsp + 0x98]
shl edx, 5
call sub.msvcrt.dll_fseek
mov r9, qword [rbp]
mov r8d, 0x20
mov edx, 1
mov rcx, r14
call sub.msvcrt.dll_fwrite
mov rax, qword [rsp + 0x98]
mov rcx, r14
lea r15, [rax + 1]
mov qword [rsp + 0x98], r15
call sub.msvcrt.dll_free
mov rcx, r13
call sub.msvcrt.dll_free
mov rcx, r12
call sub.msvcrt.dll_free
cmp rdi, rsi
jne 0x5faf40
mov byte [rsp + 0x5f], 5
cmp rbx, 1
je 0x5fbf02
nop dword [rax + rax]
movsx rax, byte [rsp + 0x5f]
mov rdi, qword [rsp + 0x88]
mov rsi, qword [rsp + 0x70]
mov byte [rsp + 0x20], al
mov r12, qword [rdi + rax*8 - 8]
movsxd r13, dword [rsi + rax*4 - 4]
dec eax
mov byte [rsp + 0x5f], al
test al, al
jg 0x5fb540
mov ecx, 0x28
lea rbx, [r12 - 1]
mov edi, 1
mov rsi, r15
call sub.msvcrt.dll_malloc
mov ecx, 0x14
mov qword [rax], rbx
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rbx
mov qword [rax + 0x20], rbx
mov qword [rsp + 0x78], rax
call sub.msvcrt.dll_malloc
mov qword [rsp + 0x80], rax
vmovups xmmword [rax], xmm6
mov dword [rax + 0x10], 0
shlx eax, edi, r12d
movsxd rdx, eax
lea eax, [r12 - 1]
shlx eax, edi, eax
cdqe
mov qword [rsp + 0x40], rax
test r13, r13
je 0x5fb5f0
cmp r13, 1
je 0x5fba70
cmp r13, 2
je 0x5fbd20
cmp r13, 3
je 0x5fb810
lea rax, [r12 + 1]
lea rcx, [rdx + r15]
imul rax, rdx
imul r12, rax
mov rax, qword [rsp + 0x40]
sub rcx, r12
test rax, rax
jle 0x5fb50c
add rax, r15
sub rcx, r15
mov qword [rsp + 0x68], rax
mov qword [rsp + 0x20], rax
mov qword [rsp + 0x60], rcx
nop word cs:[rax + rax]
nop dword [rax]
mov rax, rsi
sub rax, qword [rsp + 0x40]
xor r8d, r8d
mov edi, 0
mov rdx, qword [rbp + 0x10]
mov rcx, qword [rbp]
andn rdx, 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]
mov rcx, qword [rbp]
cmp rax, 0x20
cmovne r14, rdi
xor r8d, r8d
lea rax, [r15 + rsi]
andn rdx, 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]
mov rcx, qword [rbp]
cmovne rbx, rdi
xor r8d, r8d
add rax, r15
andn rdx, 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 0x5fb280
mov rax, rsi
neg rax
lea rax, [rax + rax - 1]
cmp rax, 0x7f
jbe 0x5fb5e0
xor edx, edx
nop dword [rax]
mov r8d, eax
mov ecx, edx
shr rax, 7
inc edx
or r8d, 0xffffff80
mov byte [r13 + rcx], r8b
cmp rax, 0x7f
ja 0x5fb290
add rdx, r13
mov byte [rdx], al
mov ecx, pe_nt_image_headers64
call sub.msvcrt.dll_malloc
mov ecx, 0x20
mov r12, rax
mov rax, qword [rbp + 0x18]
vmovups xmm2, xmmword [r13]
vmovups xmm3, xmmword [r13 + 0x10]
vmovups xmm4, xmmword [r14]
lea rdi, [r12 + 0x60]
lea r11, [r12 + 0x20]
vmovups xmm5, xmmword [r14 + 0x10]
lea r10, [r12 + 0x40]
mov qword [rsp + 0x50], r11
mov qword [rsp + 0x48], r10
vmovups xmm0, xmmword [rax]
vmovups xmmword [r12], xmm0
vmovups xmm1, xmmword [rax + 0x10]
vmovups xmm0, xmmword [rbx]
vmovups xmmword [r12 + 0x20], xmm2
vmovups xmmword [r12 + 0x30], xmm3
vmovups xmmword [r12 + 0x40], xmm4
vmovups xmmword [r12 + 0x50], xmm5
vmovups xmmword [r12 + 0x10], xmm1
vmovups xmm1, xmmword [rbx + 0x10]
vmovups xmmword [r12 + 0x60], xmm0
vmovups xmmword [rdi + 0x10], xmm1
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.005fd4a0
mov qword [r13], 0
mov qword [r13 + 8], 0
mov qword [r13 + 0x10], 0
mov qword [r13 + 0x18], 0
mov rcx, qword [rsp + 0x20]
mov r10, qword [rsp + 0x48]
mov r11, qword [rsp + 0x50]
test rcx, rcx
lea rax, [rcx + rcx]
jns 0x5fb39f
mov rax, rcx
neg rax
lea rax, [rax + rax - 1]
cmp rax, 0x7f
jbe 0x5fb5d0
xor edx, edx
nop dword [rax + rax]
mov r8d, eax
mov ecx, edx
shr rax, 7
inc edx
or r8d, 0xffffff80
mov byte [r13 + rcx], r8b
cmp rax, 0x7f
ja 0x5fb3b0
add rdx, r13
mov byte [rdx], al
mov rax, qword [rbp + 0x18]
vmovups xmm4, xmmword [r13]
mov ecx, 0x20
vmovups xmm5, xmmword [r13 + 0x10]
vmovups xmm0, xmmword [r14]
vmovups xmm1, xmmword [r14 + 0x10]
vmovups xmm2, xmmword [rax]
vmovups xmmword [r12], xmm2
vmovups xmm3, xmmword [rax + 0x10]
vmovups xmm2, xmmword [r15]
vmovups xmmword [r12 + 0x20], xmm4
vmovups xmmword [r12 + 0x10], xmm3
vmovups xmm3, xmmword [r15 + 0x10]
vmovups xmmword [r11 + 0x10], xmm5
vmovups xmmword [r12 + 0x40], xmm0
vmovups xmmword [r10 + 0x10], xmm1
vmovups xmmword [r12 + 0x60], xmm2
vmovups xmmword [rdi + 0x10], xmm3
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.005fd4a0
mov rdx, qword [rbp + 0x10]
xor r8d, r8d
mov rcx, qword [rbp]
andn rdx, rdx, rsi
inc rsi
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]
andn rdx, rdx, qword [rsp + 0x20]
shl edx, 5
call sub.msvcrt.dll_fseek
mov r9, qword [rbp]
mov r8d, 0x20
mov edx, 1
mov rcx, rdi
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
inc qword [rsp + 0x20]
cmp qword [rsp + 0x68], rsi
jne 0x5fb170
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 0x5fba30
mov r15, qword [rsp + 0x98]
jmp 0x5fb070
movsx r14, al
lea rsi, [r14*8]
mov rcx, rsi
call sub.msvcrt.dll_malloc
mov r10, rdi
lea ecx, [rsi - 1]
mov rbx, rax
mov eax, esi
shr ecx, 3
mov rdx, qword [rdi + rax - 8]
mov rsi, r10
mov rdi, rbx
mov qword [rbx + rax - 8], rdx
rep movsq qword [rdi], qword [rsi]
mov rcx, r10
lea rsi, [r14*4]
call sub.msvcrt.dll_free
mov rcx, rsi
call sub.msvcrt.dll_malloc
mov r14, rax
cmp esi, 8
jae 0x5fb9e0
test sil, 4
jne 0x5fbee8
test esi, esi
je 0x5fb5b2
mov rax, qword [rsp + 0x70]
movzx eax, byte [rax]
mov byte [r14], al
mov rcx, qword [rsp + 0x70]
call sub.msvcrt.dll_free
mov qword [rsp + 0x88], rbx
mov qword [rsp + 0x70], r14
jmp 0x5fb09f
mov rdx, r13
jmp 0x5fb3cd
mov rdx, r13
jmp 0x5fb2ad
sub rsi, rdx
test rax, rax
jle 0x5fb9ae
lea rdi, [rsi + rax]
mov qword [rsp + 0x20], rdi
mov r12, rdi
mov rdi, rsi
nop dword [rax + rax]
mov rdx, qword [rbp + 0x10]
xor r8d, r8d
mov r14d, 0
mov rcx, qword [rbp]
andn rdx, 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 rsi, rax
call sub.msvcrt.dll_fread
mov rdx, qword [rbp + 0x10]
mov rcx, qword [rbp]
cmp rax, 0x20
cmovne rsi, r14
xor r8d, r8d
andn rdx, 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, r14
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 0x5fb9d0
xor edx, edx
nop word cs:[rax + rax]
mov r8d, eax
mov ecx, edx
shr rax, 7
inc edx
or r8d, 0xffffff80
mov byte [r12 + rcx], r8b
cmp rax, 0x7f
ja 0x5fb6e0
add rdx, r12
mov byte [rdx], al
mov ecx, pe_nt_image_headers64
inc rdi
call sub.msvcrt.dll_malloc
mov ecx, 0x20
mov r14, rax
mov rax, qword [rbp + 0x18]
vmovups xmm0, xmmword [rsi]
vmovups xmm1, xmmword [rsi + 0x10]
vmovups xmm2, xmmword [r13]
vmovups xmm3, xmmword [r13 + 0x10]
vmovups xmm4, xmmword [rax]
vmovups xmmword [r14], xmm4
vmovups xmm5, xmmword [rax + 0x10]
vmovups xmm4, xmmword [r12]
vmovups xmmword [r14 + 0x40], xmm0
vmovups xmmword [r14 + 0x50], xmm1
vmovups xmmword [r14 + 0x60], xmm2
vmovups xmmword [r14 + 0x70], xmm3
vmovups xmmword [r14 + 0x10], xmm5
vmovups xmm5, xmmword [r12 + 0x10]
vmovups xmmword [r14 + 0x20], xmm4
vmovups xmmword [r14 + 0x30], xmm5
call sub.msvcrt.dll_malloc
mov r9d, 0x20
mov edx, pe_nt_image_headers64
mov rcx, r14
mov r8, rax
mov r15, rax
call fcn.005fd4a0
mov rdx, qword [rbp + 0x10]
xor r8d, r8d
mov rcx, qword [rbp]
andn rdx, rdx, qword [rsp + 0x98]
shl edx, 5
call sub.msvcrt.dll_fseek
mov r9, qword [rbp]
mov r8d, 0x20
mov edx, 1
mov rcx, r15
call sub.msvcrt.dll_fwrite
mov rcx, r15
inc qword [rsp + 0x98]
call sub.msvcrt.dll_free
mov rcx, r14
call sub.msvcrt.dll_free
mov rcx, rsi
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 0x5fb9ae
mov rax, qword [rsp + 0x40]
lea r12, [rdi + rax]
jmp 0x5fb610
test rax, rax
jle 0x5fb9ae
lea rdi, [r15 + rax]
nop dword [rax]
mov rax, rsi
sub rax, qword [rsp + 0x40]
mov rdx, qword [rbp + 0x10]
xor r8d, r8d
mov rcx, qword [rbp]
andn rdx, 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, [rsi + rsi]
test rsi, rsi
jns 0x5fb897
mov rax, rsi
neg rax
lea rax, [rax + rax - 1]
cmp rax, 0x7f
jbe 0x5fba10
xor edx, edx
nop word cs:[rax + rax]
nop
mov r8d, eax
mov ecx, edx
shr rax, 7
inc edx
or r8d, 0xffffff80
mov byte [r12 + rcx], r8b
cmp rax, 0x7f
ja 0x5fb8b0
add rdx, r12
mov byte [rdx], al
mov ecx, 0x60
inc rsi
call sub.msvcrt.dll_malloc
mov ecx, 0x20
mov r15, rax
mov rax, qword [rbp + 0x18]
vmovups xmm0, xmmword [r12]
vmovups xmm1, xmmword [r12 + 0x10]
vmovups xmm2, xmmword [r14]
vmovups xmm3, xmmword [r14 + 0x10]
vmovups xmm4, xmmword [rax]
vmovups xmmword [r15], xmm4
vmovups xmm5, xmmword [rax + 0x10]
vmovups xmmword [r15 + 0x20], xmm0
vmovups xmmword [r15 + 0x30], xmm1
vmovups xmmword [r15 + 0x40], xmm2
vmovups xmmword [r15 + 0x50], xmm3
vmovups xmmword [r15 + 0x10], xmm5
call sub.msvcrt.dll_malloc
mov r9d, 0x20
mov edx, 0x60
mov rcx, r15
mov r8, rax
mov r13, rax
call fcn.005fd4a0
mov rdx, qword [rbp + 0x10]
xor r8d, r8d
mov rcx, qword [rbp]
andn rdx, rdx, qword [rsp + 0x98]
shl edx, 5
call sub.msvcrt.dll_fseek
mov r9, qword [rbp]
mov r8d, 0x20
mov edx, 1
mov rcx, r13
call sub.msvcrt.dll_fwrite
mov rcx, r13
inc qword [rsp + 0x98]
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 rdi, rsi
jne 0x5fb820
lea r8, [rsp + 0x98]
mov rdx, rbx
mov rcx, rbp
call fcn.005fab60
jmp 0x5fb50c
mov rdx, r12
jmp 0x5fb6fc
mov r11, qword [rsp + 0x70]
mov eax, esi
lea ecx, [rsi - 1]
mov rdi, r14
shr ecx, 3
mov rdx, qword [r11 + rax - 8]
mov rsi, r11
mov qword [r14 + rax - 8], rdx
rep movsq qword [rdi], qword [rsi]
jmp 0x5fb5b2
mov rdx, r12
jmp 0x5fb8cc
mov rdx, r12
jmp 0x5faf8c
mov rcx, qword [rsp + 0x88]
call sub.msvcrt.dll_free
nop
vmovups xmm6, xmmword [rsp + 0xa0]
mov rcx, qword [rsp + 0x70]
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 0x5fbc2b
lea rax, [r15 + rax]
mov qword [rsp + 0x40], r12
mov qword [rsp + 0x30], rax
nop word [rax + rax]
mov rdx, qword [rbp + 0x10]
mov rax, rsi
xor r8d, r8d
mov rcx, qword [rbp]
sub rax, rdi
andn rdx, 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
mov eax, 0
cmovne r15, rax
call sub.msvcrt.dll_calloc
mov r13, rax
lea rax, [rsi + rsi]
test rsi, rsi
jns 0x5fbb05
mov rax, rsi
neg rax
lea rax, [rax + rax - 1]
cmp rax, 0x7f
jbe 0x5fbd10
xor edx, edx
nop word cs:[rax + rax]
nop dword [rax]
mov r8d, eax
mov ecx, edx
shr rax, 7
inc edx
or r8d, 0xffffff80
mov byte [r13 + rcx], r8b
cmp rax, 0x7f
ja 0x5fbb20
add rdx, r13
mov byte [rdx], al
mov ecx, 0x60
inc rsi
call sub.msvcrt.dll_malloc
mov ecx, 0x20
mov r12, rax
mov rax, qword [rbp + 0x18]
vmovups xmm4, xmmword [r13]
vmovups xmm5, xmmword [r13 + 0x10]
vmovups xmm2, xmmword [rax]
vmovups xmmword [r12], xmm2
vmovups xmm3, xmmword [rax + 0x10]
vmovups xmm2, xmmword [r15]
vmovups xmmword [r12 + 0x20], xmm4
vmovups xmmword [r12 + 0x30], xmm5
vmovups xmmword [r12 + 0x10], xmm3
vmovups xmm3, xmmword [r15 + 0x10]
vmovups xmmword [r12 + 0x40], xmm2
vmovups xmmword [r12 + 0x50], xmm3
call sub.msvcrt.dll_malloc
mov r9d, 0x20
mov edx, 0x60
mov rcx, r12
mov r8, rax
mov r14, rax
call fcn.005fd4a0
mov rdx, qword [rbp + 0x10]
xor r8d, r8d
mov rcx, qword [rbp]
andn rdx, rdx, qword [rsp + 0x98]
shl edx, 5
call sub.msvcrt.dll_fseek
mov r9, qword [rbp]
mov r8d, 0x20
mov edx, 1
mov rcx, r14
call sub.msvcrt.dll_fwrite
mov rcx, r14
inc qword [rsp + 0x98]
call sub.msvcrt.dll_free
mov rcx, r12
call sub.msvcrt.dll_free
mov rcx, r15
call sub.msvcrt.dll_free
mov rcx, r13
call sub.msvcrt.dll_free
cmp rsi, qword [rsp + 0x30]
jne 0x5fba90
mov r12, qword [rsp + 0x40]
cmp r12, 2
je 0x5fb9ae
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 r15, qword [rsp + 0x88]
mov r8, rdi
mov rcx, rax
mov rbx, rax
mov rdx, r15
call sub.msvcrt.dll_memcpy
mov rax, qword [rsp + 0x78]
lea r8, [rbx + rdi]
mov rcx, r15
vmovups xmm0, xmmword [rax]
vmovups xmmword [r8], xmm0
vmovups xmm0, xmmword [rax + 0x10]
mov rax, qword [rax + 0x20]
mov qword [r8 + 0x20], rax
movzx eax, byte [rsp + 0x20]
vmovups xmmword [r8 + 0x10], xmm0
add eax, 4
vmovups xmmword [rsp + 0x30], xmm0
mov byte [rsp + 0x5f], al
call sub.msvcrt.dll_free
mov rcx, rsi
sub rsi, 0x14
call sub.msvcrt.dll_malloc
mov r15, qword [rsp + 0x70]
mov r8, rsi
mov rcx, rax
mov rdi, rax
add rsi, rdi
mov rdx, r15
call sub.msvcrt.dll_memcpy
mov rax, qword [rsp + 0x80]
mov rcx, r15
vmovups xmm0, xmmword [rax]
mov eax, dword [rax + 0x10]
mov dword [rsi + 0x10], eax
vmovups xmmword [rsi], xmm0
vmovups xmmword [rsp + 0x20], xmm0
call sub.msvcrt.dll_free
mov qword [rsp + 0x70], rdi
mov qword [rsp + 0x88], rbx
jmp 0x5fb50c
mov rdx, r13
jmp 0x5fbb3d
mov rdi, rax
test rax, rax
jle 0x5fbc2b
lea rax, [r15 + rax]
mov qword [rsp + 0x40], r12
mov qword [rsp + 0x30], rax
nop word [rax + rax]
mov rdx, qword [rbp + 0x10]
mov rax, rsi
xor r8d, r8d
mov rcx, qword [rbp]
sub rax, rdi
andn rdx, 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
mov eax, 0
cmovne r15, rax
call sub.msvcrt.dll_calloc
mov r13, rax
lea rax, [rsi + rsi]
test rsi, rsi
jns 0x5fbdb5
mov rax, rsi
neg rax
lea rax, [rax + rax - 1]
cmp rax, 0x7f
jbe 0x5fbee0
xor edx, edx
nop word cs:[rax + rax]
nop dword [rax]
mov r8d, eax
mov ecx, edx
shr rax, 7
inc edx
or r8d, 0xffffff80
mov byte [r13 + rcx], r8b
cmp rax, 0x7f
ja 0x5fbdd0
add rdx, r13
mov byte [rdx], al
mov ecx, 0x60
inc rsi
call sub.msvcrt.dll_malloc
mov ecx, 0x20
mov r12, rax
mov rax, qword [rbp + 0x18]
vmovups xmm4, xmmword [r13]
vmovups xmm5, xmmword [r13 + 0x10]
vmovups xmm2, xmmword [r15]
vmovups xmm3, xmmword [r15 + 0x10]
vmovups xmm0, xmmword [rax]
vmovups xmmword [r12], xmm0
vmovups xmm1, xmmword [rax + 0x10]
vmovups xmmword [r12 + 0x20], xmm4
vmovups xmmword [r12 + 0x30], xmm5
vmovups xmmword [r12 + 0x40], xmm2
vmovups xmmword [r12 + 0x50], xmm3
vmovups xmmword [r12 + 0x10], xmm1
call sub.msvcrt.dll_malloc
mov r9d, 0x20
mov edx, 0x60
mov rcx, r12
mov r8, rax
mov r14, rax
call fcn.005fd4a0
mov rdx, qword [rbp + 0x10]
xor r8d, r8d
mov rcx, qword [rbp]
andn rdx, rdx, qword [rsp + 0x98]
shl edx, 5
call sub.msvcrt.dll_fseek
mov r9, qword [rbp]
mov r8d, 0x20
mov edx, 1
mov rcx, r14
call sub.msvcrt.dll_fwrite
mov rcx, r14
inc qword [rsp + 0x98]
call sub.msvcrt.dll_free
mov rcx, r12
call sub.msvcrt.dll_free
mov rcx, r15
call sub.msvcrt.dll_free
mov rcx, r13
call sub.msvcrt.dll_free
cmp qword [rsp + 0x30], rsi
jne 0x5fbd40
jmp 0x5fbc26
mov rdx, r13
jmp 0x5fbded
mov rdi, qword [rsp + 0x70]
mov esi, esi
mov eax, dword [rdi]
mov dword [r14], eax
mov eax, dword [rdi + rsi - 4]
mov dword [r14 + rsi - 4], eax
jmp 0x5fb5b2
lea r8, [rsp + 0x98]
mov edx, 1
mov rcx, rbp
call fcn.005fab60
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