Function at 0x140085290
Capabilities:
Read file on windows

Disassembly:
push rbp
push r12
push r14
lea rbp, [rsp - 0x440]
sub rsp, 0x540
mov rax, qword [0x1402a83b0]
xor rax, rsp
mov qword [rbp + 0x410], rax
mov r12, rdx
mov qword [rsp + 0x50], rdx
lea rdx, [rsp + 0x38]
mov r14, rcx
call fcn.140066e20
test eax, eax
jne 0x1400852d9
mov eax, 2
jmp 0x1400853d6
lea rdx, [rsp + 0x40]
mov rcx, r14
call fcn.140066e20
test eax, eax
je 0x1400852cf
lea rdx, [rsp + 0x30]
mov rcx, r14
call fcn.140066e20
test eax, eax
je 0x1400852cf
lea rdx, [rsp + 0x34]
mov rcx, r14
call fcn.140066e20
test eax, eax
je 0x1400852cf
mov eax, dword [rsp + 0x38]
mov qword [rsp + 0x570], rbx
dec eax
cmp eax, 0x7cff
ja 0x1400857f4
mov eax, dword [rsp + 0x40]
dec eax
cmp eax, 0x7cff
ja 0x1400857f4
mov ebx, dword [rsp + 0x34]
cmp ebx, 4
jg 0x1400857f4
mov qword [rsp + 0x538], rsi
mov qword [rsp + 0x528], r13
mov r13d, 4
mov edx, r13d
mov ecx, 0x10000
call fcn.1401be1f8
mov rsi, rax
mov qword [rsp + 0x48], rax
test rax, rax
jne 0x140085378
lea eax, [rsi + 1]
jmp 0x1400853be
mov qword [rsp + 0x530], rdi
movsxd rdi, dword [rsp + 0x30]
mov edx, 9
mov rcx, rdi
mov qword [rsp + 0x520], r15
call fcn.1401be1f8
mov r15, rax
test rax, rax
jne 0x1400853f2
mov rcx, rsi
call fcn.1401be23c
lea eax, [r15 + 1]
mov rdi, qword [rsp + 0x530]
mov r15, qword [rsp + 0x520]
mov rsi, qword [rsp + 0x538]
mov r13, qword [rsp + 0x528]
mov rbx, qword [rsp + 0x570]
mov rcx, qword [rbp + 0x410]
xor rcx, rsp
call fcn.1401bd600
add rsp, 0x540
pop r14
pop r12
pop rbp
ret
mov r9, rsi
mov r8d, ebx
mov edx, edi
mov rcx, r14
mov qword [rsp + 0x20], rax
call fcn.140084760
test ax, ax
je 0x140085412
movzx eax, r13w
jmp 0x1400853ae
lea rcx, [rsp + 0x60]
call fcn.140060c40
movzx eax, word [0x140219c48]
mov r8d, dword [rsp + 0x30]
movsd xmm0, qword [str.X_PixMap2]
movsd qword [rbp + 0x4e], xmm0
mov word [rbp + 0x56], ax
mov eax, 2
mov dword [rsp + 0x60], eax
cmp r8d, 0x100
jle 0x140085460
mov ecx, dword [rsp + 0x38]
mov eax, 0x18
mov word [rbp - 0x7e], ax
lea eax, [rcx + rcx*2]
mov dword [rbp - 0x78], eax
jmp 0x140085478
mov ecx, r8d
call fcn.14005e1c0
mov ecx, dword [rsp + 0x38]
mov r8d, dword [rsp + 0x30]
mov dword [rbp - 0x78], ecx
mov word [rbp - 0x7e], ax
mov eax, dword [rsp + 0x40]
mov edi, 1
xor edx, edx
mov dword [rsp + 0x78], ecx
mov dword [rsp + 0x7c], eax
mov word [rbp - 0x80], di
test r8d, r8d
jle 0x1400854bb
nop dword [rax]
nop dword [rax + rax]
movsxd rcx, edx
lea rax, [r15 + rcx*8]
cmp byte [rcx + rax + 8], 0
jne 0x1400854b7
inc edx
cmp edx, r8d
jl 0x1400854a0
jmp 0x1400854bb
mov word [rbp - 0x54], dx
lea rdx, [rsp + 0x60]
mov rcx, r12
call fcn.14005ee10
movzx ebx, ax
test ax, ax
jne 0x1400857dc
movsxd rdx, dword [rsp + 0x30]
lea r9, [0x140051a20]
mov r8d, 9
mov rcx, r15
call fcn.1401c2c90
xor r13d, r13d
mov dword [rsp + 0x3c], r13d
cmp dword [rsp + 0x7c], r13d
jle 0x140085768
mov rcx, qword [r14]
call fcn.1401c1a94
test eax, eax
jne 0x14008551a
mov rcx, qword [r14]
call fcn.1401c3f28
cmp eax, 0xa
jne 0x140085501
xor esi, esi
xor ebx, ebx
xor r12d, r12d
mov dword [rsp + 0x44], esi
cmp dword [rsp + 0x78], ebx
jle 0x140085729
mov eax, dword [rsp + 0x34]
xor r13d, r13d
nop word [rax + rax]
cmp dword [rsp + 0x30], 0x100
jg 0x140085625
cmp eax, 2
jle 0x1400855ba
mov r9, qword [r14]
lea rcx, [rbp + 0xe0]
movsxd rdx, eax
mov r8, rdi
call fcn.1401c1e14
mov edi, dword [rsp + 0x30]
xor ebx, ebx
test edi, edi
jle 0x1400855a7
movsxd rsi, dword [rsp + 0x34]
nop word [rax + rax]
movsxd rdx, ebx
lea rcx, [rbp + 0xe0]
mov r8, rsi
lea rax, [r15 + rdx*8]
add rdx, rax
call fcn.1401c5410
test eax, eax
je 0x1400855a3
inc ebx
cmp ebx, edi
jl 0x140085580
mov esi, dword [rsp + 0x44]
mov rax, qword [rsp + 0x70]
mov edi, 1
mov byte [r12 + rax], bl
jmp 0x140085709
cmp eax, 1
jne 0x1400855e1
mov rcx, qword [r14]
call fcn.1401c3f28
movsxd rcx, eax
mov rax, qword [rsp + 0x48]
movzx edx, byte [rax + rcx*4]
mov rax, qword [rsp + 0x70]
mov byte [r12 + rax], dl
jmp 0x140085709
cmp eax, 2
jne 0x14008570d
mov rcx, qword [r14]
call fcn.1401c3f28
mov rcx, qword [r14]
movsxd rdi, eax
call fcn.1401c3f28
mov rcx, rdi
cdqe
shl rcx, 8
mov edi, 1
add rcx, rax
mov rax, qword [rsp + 0x48]
movzx ecx, byte [rax + rcx*4]
mov rax, qword [rsp + 0x70]
mov byte [r12 + rax], cl
jmp 0x140085709
cmp eax, 2
jle 0x14008569a
mov r9, qword [r14]
lea rcx, [rbp + 0xd0]
movsxd rdx, eax
mov r8, rdi
call fcn.1401c1e14
movsxd rax, dword [rsp + 0x34]
movsxd r8, dword [rsp + 0x30]
mov byte [rbp + rax + 0xd0], 0
lea rax, [0x140051a20]
lea rcx, [rbp + 0xd0]
mov r9d, 9
mov rdx, r15
mov qword [rsp + 0x20], rax
call fcn.1401c37d8
mov rcx, rax
test rax, rax
je 0x140085696
sub rcx, r15
movabs rax, 0x1c71c71c71c71c72
imul rcx
mov rbx, rdx
shr rbx, 0x3f
add rbx, rdx
jmp 0x1400856d5
xor ebx, ebx
jmp 0x1400856d5
cmp eax, 1
jne 0x1400856ac
mov rcx, qword [r14]
call fcn.1401c3f28
movsxd rbx, eax
jmp 0x1400856cd
cmp eax, 2
jne 0x1400856d5
mov rcx, qword [r14]
call fcn.1401c3f28
mov rcx, qword [r14]
movsxd rbx, eax
call fcn.1401c3f28
shl rbx, 8
cdqe
add rbx, rax
mov rax, qword [rsp + 0x48]
mov ebx, dword [rax + rbx*4]
mov rax, qword [rsp + 0x70]
movsxd rcx, ebx
lea rdx, [r15 + rcx*8]
add rdx, rcx
movzx ecx, byte [rdx + 5]
mov byte [r13 + rax], cl
mov rax, qword [rsp + 0x70]
movzx ecx, byte [rdx + 6]
mov byte [r13 + rax + 1], cl
mov rax, qword [rsp + 0x70]
movzx ecx, byte [rdx + 7]
mov byte [r13 + rax + 2], cl
mov eax, dword [rsp + 0x34]
inc esi
inc r12
add r13, 3
mov dword [rsp + 0x44], esi
cmp esi, dword [rsp + 0x78]
jl 0x140085540
mov r13d, dword [rsp + 0x3c]
mov r12, qword [rsp + 0x50]
or r8d, 0xffffffff
mov r9d, edi
mov rcx, r12
or edx, r8d
call fcn.1400615b0
movzx ebx, ax
test ax, ax
jne 0x140085763
mov rcx, qword [r14]
call fcn.1401c3f28
inc r13d
mov dword [rsp + 0x3c], r13d
cmp r13d, dword [rsp + 0x7c]
jl 0x140085501
mov rsi, qword [rsp + 0x48]
mov eax, dword [rsp + 0x30]
cmp eax, 0x100
jg 0x1400857cc
test eax, eax
jle 0x1400857b8
lea r8, [rbp + 0x111]
lea r9, [r15 + 6]
mov r10d, eax
nop word [rax + rax]
movzx eax, byte [r9 - 1]
lea r8, [r8 + 3]
lea r9, [r9 + 9]
mov byte [r8 - 4], al
movzx eax, byte [r9 - 9]
mov byte [r8 - 3], al
movzx eax, byte [r9 - 8]
mov byte [r8 - 2], al
dec r10
jne 0x140085790
mov edx, 0x100
mov r8d, 8
lea r9, [rbp + 0x110]
jmp 0x1400857d4
xor r8d, r8d
xor edx, edx
xor r9d, r9d
mov rcx, r12
call fcn.14005cb20
mov rcx, r15
call fcn.1401be23c
mov rcx, rsi
call fcn.1401be23c
movzx eax, bx
jmp 0x1400853ae
mov eax, 2
jmp 0x1400853ce