Function at 0x100064008
Capabilities:
Read file on windows

Disassembly:
mov rax, rsp
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0xd0
mov qword [rsp + 0xc0], 0xfffffffffffffffe
mov qword [rax + 8], rbx
mov r12, rdx
mov rsi, qword [0x10019f520]
xor ebx, ebx
mov qword [rsp + 0x70], rbx
mov ebp, ebx
mov dword [rsp + 0x78], ebx
mov dword [rsp + 0x7c], ebx
lea r8, [0x10002a3a8]
mov rdx, qword [rdx + 0x10]
lea rcx, [rax + 0x10]
call qword [sym.imp.msvcrt.dll__wfopen_s]
lea r13d, [rbx + 1]
cmp qword [rsp + 0x118], rbx
je 0x1000645c9
mov r14d, 0x2028
mov rcx, r14
call fcn.100179d98
mov rdi, rax
mov r9, qword [rsp + 0x118]
mov r8, r14
mov rdx, r13
mov rcx, rax
call qword [sym.imp.msvcrt.dll_fread]
cmp rax, r14
je 0x1000640b7
mov rcx, rdi
call sub.msvcrt.dll_free
mov rcx, qword [rsp + 0x118]
call qword [sym.imp.msvcrt.dll_fclose]
jmp 0x1000645c9
cmp dword [rdi], 0x484d4752
jne 0x10006422a
cmp dword [rdi + 8], 0x2030
jne 0x10006411f
lea rdx, [rdi + 0x10]
lea rcx, [rdi + 0xc]
mov r8d, 0x2018
call sub.msvcrt.dll_memmove
mov dword [rdi + 8], r14d
mov word [rdi + 0x2024], bx
mov r8d, r13d
mov edx, 8
mov rcx, qword [rsp + 0x118]
call qword [sym.imp.msvcrt.dll_fseek]
cmp eax, ebx
je 0x10006411f
mov rcx, rdi
call sub.msvcrt.dll_free
mov rcx, qword [rsp + 0x118]
call qword [sym.imp.msvcrt.dll_fclose]
jmp 0x1000645c9
cmp dword [rdi + 8], r14d
jne 0x100064146
cmp dword [rdi + 4], r13d
je 0x100064146
mov rcx, rdi
call sub.msvcrt.dll_free
mov rcx, qword [rsp + 0x118]
call qword [sym.imp.msvcrt.dll_fclose]
jmp 0x1000645c9
mov edx, dword [rdi + 0x14]
cmp edx, ebx
je 0x10006417d
mov r8d, r13d
mov rcx, qword [rsp + 0x118]
call qword [sym.imp.msvcrt.dll_fseek]
cmp eax, ebx
je 0x10006417d
mov rcx, rdi
call sub.msvcrt.dll_free
mov rcx, qword [rsp + 0x118]
call qword [sym.imp.msvcrt.dll_fclose]
jmp 0x1000645c9
mov rcx, qword [rsp + 0x118]
call qword [sym.imp.msvcrt.dll_ftell]
mov ebp, eax
mov rcx, rdi
call sub.msvcrt.dll_free
mov rcx, qword [rsp + 0x118]
call qword [sym.imp.msvcrt.dll_fclose]
mov qword [rsp + 0x118], rbx
lea r8, [0x10002a3b0]
mov rdx, qword [r12 + 0x10]
lea rcx, [rsp + 0x118]
call qword [sym.imp.msvcrt.dll__wfopen_s]
mov r11, qword [rsp + 0x118]
cmp r11, rbx
je 0x1000645c9
cmp ebp, ebx
je 0x100064207
xor r8d, r8d
mov edx, ebp
mov rcx, r11
call qword [sym.imp.msvcrt.dll_fseek]
cmp eax, ebx
je 0x1000641ff
mov rcx, qword [rsp + 0x118]
call qword [sym.imp.msvcrt.dll_fclose]
jmp 0x1000645c9
mov r11, qword [rsp + 0x118]
mov rdx, r11
lea rcx, [rsp + 0x70]
call fcn.10006d964
mov edi, eax
mov rcx, qword [rsp + 0x118]
call qword [sym.imp.msvcrt.dll_fclose]
mov ebp, dword [rsp + 0x78]
jmp 0x100064245
mov rcx, rdi
call sub.msvcrt.dll_free
mov rcx, qword [rsp + 0x118]
call qword [sym.imp.msvcrt.dll_fclose]
mov edi, 2
cmp edi, ebx
jne 0x1000645c9
mov eax, dword [rsp + 0x88]
mov dword [0x100199d1c], eax
xor r9d, r9d
mov r14b, byte [rsp + 0x85]
mov r8b, r14b
mov r15b, byte [rsp + 0x84]
mov dl, r15b
mov rcx, rsi
call fcn.100062d74
mov r13d, ebx
cmp ebp, ebx
jle 0x100064546
mov r12d, dword [rsp + 0x80]
mov edi, dword [rsp + 0x68]
cmp r12d, ebp
jge 0x10006432f
movsxd rax, r12d
lea rcx, [rax + rax*2]
lea rax, [rsp + 0x68]
mov qword [rsp + 0x50], rax
lea rax, [rsp + 0x128]
mov qword [rsp + 0x48], rax
lea rax, [rsp + 0x118]
mov qword [rsp + 0x40], rax
lea rax, [rsp + 0x120]
mov qword [rsp + 0x38], rax
lea rax, [rsp + 0x98]
mov qword [rsp + 0x30], rax
lea rax, [rsp + 0xa0]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x60]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x64]
lea r8, [rsp + 0x90]
mov rax, qword [rsp + 0x70]
mov rdx, qword [rax + rcx*8 + 0x10]
lea rcx, [rsp + 0x70]
call fcn.10006dd28
inc r12d
mov dword [rsp + 0x80], r12d
cmp eax, ebx
jne 0x100064497
mov edi, dword [rsp + 0x68]
mov edx, dword [rsi + 0x1c]
movsxd rcx, dword [rsi + 0x30]
mov rax, qword [rsi + 0x28]
mov r10, qword [rax + rcx*8 - 8]
lea rcx, [rsi + 0x38]
mov dword [rsp + 0x58], edx
mov al, byte [rsp + 0x118]
mov byte [rsp + 0x50], al
mov al, byte [rsp + 0x120]
mov byte [rsp + 0x48], al
mov eax, dword [rsp + 0x98]
mov dword [rsp + 0x40], eax
mov eax, dword [rsp + 0xa0]
mov dword [rsp + 0x38], eax
mov eax, dword [rsp + 0x90]
mov dword [rsp + 0x30], eax
lea rax, [rsp + 0x60]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x64]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x9c]
lea r8, [rsp + 0x94]
mov rdx, r10
call fcn.10006af4c
movsxd rcx, dword [rsi + 0x30]
mov rax, qword [rsi + 0x28]
mov r8, qword [rax + rcx*8 - 8]
mov eax, dword [rsp + 0x60]
mov dword [rsp + 0x30], eax
mov eax, dword [rsp + 0x64]
mov dword [rsp + 0x28], eax
mov eax, dword [rsp + 0x9c]
mov dword [rsp + 0x20], eax
mov r9d, dword [rsp + 0x94]
lea rdx, [rsp + 0xa8]
lea rcx, [rsi + 0x38]
call fcn.10006a838
cmp byte [rsp + 0x128], bl
je 0x10006443e
cmp edi, 2
je 0x100064433
cmp edi, 4
je 0x100064426
cmp edi, 8
je 0x100064419
cmp edi, 0x10
jne 0x1000644dc
mov dword [rsp + 0xa8], 0xc
jmp 0x10006443e
mov dword [rsp + 0xa8], 0xb
jmp 0x10006443e
mov dword [rsp + 0xa8], 0xa
jmp 0x10006443e
mov dword [rsp + 0xa8], 9
movsxd rcx, dword [rsi + 0x30]
mov rax, qword [rsi + 0x28]
lea r8, [rsp + 0xa8]
mov rdx, qword [rax + rcx*8 - 8]
lea rcx, [rsi + 0x38]
call fcn.10006a9ac
cmp al, bl
je 0x100064510
lea rdx, [rsp + 0xa8]
mov rcx, rsi
call fcn.1000636d4
lea rcx, [rsi + 0x49e80]
call fcn.100069664
mov byte [rsi + 0x49d01], bl
inc r13d
cmp r13d, ebp
jge 0x100064546
jmp 0x100064292
mov r9b, 1
mov r8b, r14b
mov dl, r15b
mov rcx, rsi
call fcn.100062d74
mov dl, 1
mov cl, dl
call fcn.100053168
call fcn.100176540
xor edx, edx
xor ecx, ecx
call fcn.100053168
nop
lea rcx, [rsp + 0x70]
call fcn.1000409b0
nop
lea rcx, [rsp + 0x70]
call fcn.1000409b0
xor al, al
jmp 0x1000645fa
mov dl, 1
mov cl, dl
call fcn.100053168
call fcn.100176540
xor edx, edx
xor ecx, ecx
call fcn.100053168
nop
lea rcx, [rsp + 0x70]
call fcn.1000409b0
nop
lea rcx, [rsp + 0x70]
call fcn.1000409b0
xor al, al
jmp 0x1000645fa
mov r9b, 1
mov r8b, r14b
mov dl, r15b
mov rcx, rsi
call fcn.100062d74
mov dl, 1
mov cl, dl
call fcn.100053168
call fcn.100176540
xor edx, edx
xor ecx, ecx
call fcn.100053168
nop
lea rcx, [rsp + 0x70]
call fcn.1000409b0
nop
jmp 0x1000645bb
cmp byte [rsi + 0x18], bl
je 0x10006458b
mov eax, ebp
cdq
and eax, 1
xor eax, edx
cmp eax, edx
jne 0x100064571
mov rcx, qword [rsi + 0x40]
mov rax, qword [rcx]
mov dl, 1
call qword [rax + 8]
mov rcx, qword [rsi + 0x48]
mov rax, qword [rcx]
xor edx, edx
call qword [rax + 8]
jmp 0x1000645a3
mov rcx, qword [rsi + 0x40]
mov rax, qword [rcx]
xor edx, edx
call qword [rax + 8]
mov rcx, qword [rsi + 0x48]
mov rax, qword [rcx]
mov dl, 1
call qword [rax + 8]
jmp 0x1000645a3
mov rcx, qword [rsi + 0x40]
mov rax, qword [rcx]
xor edx, edx
call qword [rax + 8]
mov rcx, qword [rsi + 0x48]
mov rax, qword [rcx]
xor edx, edx
call qword [rax + 8]
xor edx, edx
mov rcx, rsi
call fcn.100067d4c
nop
lea rcx, [rsp + 0x70]
call fcn.1000409b0
nop
mov bl, 1
lea rcx, [rsp + 0x70]
call fcn.1000409b0
mov al, bl
jmp 0x1000645fa
mov dl, r13b
mov cl, r13b
call fcn.100053168
call fcn.100176540
xor edx, edx
xor ecx, ecx
call fcn.100053168
nop
lea rcx, [rsp + 0x70]
call fcn.1000409b0
nop
lea rcx, [rsp + 0x70]
call fcn.1000409b0
xor al, al
mov rbx, qword [rsp + 0x110]
add rsp, 0xd0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret