Function at 0x1800987b0
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
mov qword [rsp + 0x20], r9
mov qword [rsp + 0x18], r8
mov qword [rsp + 0x10], rdx
push rbp
push rbx
push rsi
lea rbp, [rsp - 0x3c0]
sub rsp, 0x4c0
xor esi, esi
mov dword [rbp - 0x6c], 0xff
lea rdx, [rsp + 0x78]
mov dword [rsp + 0x20], esi
mov rbx, rcx
call fcn.1800982a0
test rax, rax
je 0x180098829
mov eax, dword [rbx + 4]
mov dword [rsp + 0x68], eax
cdq
xor eax, edx
sub eax, edx
mov dword [rbx + 4], eax
cmp eax, 0x1000000
jbe 0x180098836
mov edx, dword [0x1801eadf4]
mov rax, qword gs:[0x58]
mov ecx, Ordinal_41
mov rax, qword [rax + rdx*8]
lea rdx, str.too_large
mov qword [rcx + rax], rdx
xor eax, eax
add rsp, 0x4c0
pop rsi
pop rbx
pop rbp
ret
cmp dword [rbx], 0x1000000
ja 0x180098806
mov eax, dword [rbp - 0x7c]
mov qword [rsp + 0x4e0], rdi
mov edi, dword [rbp - 0x6c]
mov qword [rsp + 0x4b8], r12
mov r12d, dword [rbp - 0x80]
mov dword [rbp + 0x400], eax
mov eax, dword [rbp - 0x78]
mov qword [rsp + 0x4b0], r13
mov r13d, dword [rsp + 0x78]
mov dword [rsp + 0x2c], eax
mov eax, dword [rbp - 0x74]
mov qword [rsp + 0x4a8], r14
mov r14d, dword [rbp - 0x70]
mov dword [rsp + 0x30], eax
mov eax, dword [rbp - 0x68]
mov qword [rsp + 0x4a0], r15
mov r15d, dword [rsp + 0x7c]
mov dword [rsp + 0x38], eax
mov dword [rsp + 0x34], r14d
mov dword [rbp + 0x408], edi
mov dword [rsp + 0x24], r12d
mov dword [rsp + 0x28], r13d
cmp r12d, 0xc
jne 0x1800988d2
cmp r13d, 0x18
jge 0x1800988ef
mov ecx, r15d
sub ecx, eax
mov eax, 0x55555556
sub ecx, 0x18
imul ecx
mov esi, edx
shr esi, 0x1f
add esi, edx
jmp 0x1800988e3
cmp r13d, 0x10
jge 0x1800988ef
mov esi, r15d
sub esi, eax
sub esi, r12d
sar esi, 2
mov dword [rsp + 0x20], esi
test esi, esi
jne 0x18009897c
mov edx, dword [rbx + 0xb8]
sub edx, dword [rbx + 0xd0]
mov r8d, dword [rbx + 0xc0]
add edx, r8d
lea eax, [rdx - 1]
cmp eax, 0x3ff
ja 0x1800996c6
cmp r15d, edx
jl 0x1800996aa
mov ecx, r15d
sub ecx, edx
cmp ecx, 0x400
jg 0x1800996aa
test ecx, ecx
je 0x18009897c
jns 0x180098943
mov rax, qword [rbx + 0xc8]
mov qword [rbx + 0xc0], rax
jmp 0x18009897c
cmp qword [rbx + 0x10], 0
je 0x180098972
mov edx, dword [rbx + 0xc8]
sub edx, r8d
cmp edx, ecx
jge 0x180098972
mov rax, qword [rbx + 0xc8]
sub ecx, edx
mov edx, ecx
mov qword [rbx + 0xc0], rax
mov rcx, qword [rbx + 0x28]
call qword [rbx + Ordinal_26]
jmp 0x18009897c
movsxd rax, ecx
add qword [rbx + 0xc0], rax
cmp r13d, 0x18
jne 0x180098991
cmp r14d, 0xff000000
jne 0x180098991
lea eax, [r13 - 0x15]
jmp 0x18009899c
xor eax, eax
test r14d, r14d
setne al
add eax, 3
mov dword [rbx + 8], eax
mov ecx, dword [rbx]
mov r9d, dword [rbx + 4]
test ecx, ecx
js 0x18009968e
jne 0x1800989bc
lea r8d, [rcx*4]
mov r10d, r8d
jmp 0x1800989e1
mov eax, 0x7fffffff
cdq
idiv ecx
cmp eax, 4
jl 0x18009968e
lea r8d, [rcx*4]
mov r10d, r8d
test r8d, r8d
js 0x18009968e
test r9d, r9d
js 0x18009968e
je 0x1800989fe
mov eax, 0x7fffffff
cdq
idiv r9d
cmp r10d, eax
jg 0x18009968e
test ecx, ecx
je 0x180098a1d
xor edx, edx
mov eax, 0x7fffffff
div ecx
cmp eax, 4
jl 0x180099672
test r8d, r8d
js 0x180099672
test r9d, r9d
je 0x180098a35
xor edx, edx
mov eax, 0x7fffffff
div r9d
cmp r8d, eax
jg 0x180099672
imul ecx, r9d
shl ecx, 2
movsxd rcx, ecx
call fcn.180164640
mov qword [rsp + 0x70], rax
mov r14, rax
test rax, rax
je 0x180099672
cmp r13d, 0x10
jge 0x180098ff7
xor edi, edi
test esi, esi
je 0x180098fd0
cmp esi, 0x100
jg 0x180098fd0
movsxd rax, esi
mov qword [rsp + 0x60], rax
test esi, esi
jle 0x180098bc2
mov rax, qword [rbx + 0xc0]
xor r12d, r12d
mov r14d, dword [rsp + 0x24]
mov r13, qword [rsp + 0x60]
nop dword [rax]
mov rcx, qword [rbx + 0xc8]
cmp rax, rcx
jb 0x180098ac7
cmp dword [rbx + 0x30], edi
je 0x180098aea
mov rcx, rbx
call fcn.18008e090
mov rax, qword [rbx + 0xc0]
mov rcx, qword [rbx + 0xc8]
movzx edx, byte [rax]
lea rsi, [r12*4]
inc rax
mov byte [rbp + rsi - 0x5e], dl
mov qword [rbx + 0xc0], rax
mov r8, rsi
cmp rax, rcx
jae 0x180098afa
jmp 0x180098b15
lea rsi, [r12*4]
mov byte [rbp + rsi - 0x5e], dil
mov r8, rsi
cmp dword [rbx + 0x30], edi
je 0x180098b3a
mov rcx, rbx
call fcn.18008e090
mov rax, qword [rbx + 0xc0]
mov rcx, qword [rbx + 0xc8]
movzx edx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
mov byte [rbp + rsi - 0x5f], dl
cmp rax, rcx
jae 0x180098b3f
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x180098b64
mov byte [rbp + r8 - 0x5f], dil
cmp dword [rbx + 0x30], edi
je 0x180098b62
mov rcx, rbx
call fcn.18008e090
mov rax, qword [rbx + 0xc0]
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x180098b64
xor cl, cl
mov byte [rbp + rsi - 0x60], cl
cmp r14d, 0xc
je 0x180098b9e
cmp rax, qword [rbx + 0xc8]
jae 0x180098b83
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x180098b9e
cmp dword [rbx + 0x30], edi
je 0x180098b9e
mov rcx, rbx
call fcn.18008e090
inc qword [rbx + 0xc0]
mov rax, qword [rbx + 0xc0]
inc r12
mov byte [rbp + rsi - 0x5d], 0xff
cmp r12, r13
jl 0x180098aa0
mov r14, qword [rsp + 0x70]
mov r13d, dword [rsp + 0x28]
mov esi, dword [rsp + 0x20]
mov r12d, dword [rsp + 0x24]
xor eax, eax
cmp r12d, 0xc
setne al
add eax, 3
imul eax, esi
sub r15d, eax
sub r15d, dword [rsp + 0x38]
sub r15d, r12d
je 0x180098c31
test r15d, r15d
jns 0x180098bf3
mov rax, qword [rbx + 0xc8]
mov qword [rbx + 0xc0], rax
jmp 0x180098c31
cmp qword [rbx + 0x10], rdi
je 0x180098c27
mov ecx, dword [rbx + 0xc8]
sub ecx, dword [rbx + 0xc0]
cmp ecx, r15d
jge 0x180098c27
mov rax, qword [rbx + 0xc8]
sub r15d, ecx
mov rcx, qword [rbx + 0x28]
mov edx, r15d
mov qword [rbx + 0xc0], rax
call qword [rbx + Ordinal_26]
jmp 0x180098c31
movsxd rax, r15d
add qword [rbx + 0xc0], rax
cmp r13d, 1
jne 0x180098c44
mov r12d, dword [rbx]
add r12d, 7
shr r12d, 3
jmp 0x180098c62
cmp r13d, 4
jne 0x180098c55
mov r12d, dword [rbx]
inc r12d
shr r12d, 1
jmp 0x180098c62
cmp r13d, 8
jne 0x180098fa9
mov r12d, dword [rbx]
mov eax, dword [rbx + 4]
neg r12d
and r12d, 3
mov ecx, eax
cmp r13d, 1
jne 0x180098def
xor r13d, r13d
test eax, eax
jle 0x180099582
mov rax, qword [rbx + 0xc0]
mov esi, 7
cmp rax, qword [rbx + 0xc8]
jae 0x180098ca7
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x180098ccd
cmp dword [rbx + 0x30], 0
je 0x180098ccb
mov rcx, rbx
call fcn.18008e090
mov rax, qword [rbx + 0xc0]
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x180098ccd
xor cl, cl
mov edx, dword [rbx]
xor r15d, r15d
movzx r9d, cl
test edx, edx
jle 0x180098d96
mov r8d, edx
mov eax, r9d
mov ecx, esi
sar eax, cl
and eax, 1
lea rcx, [rax*4]
movzx eax, byte [rbp + rcx - 0x60]
mov byte [rdi + r14], al
movzx eax, byte [rbp + rcx - 0x5f]
mov byte [rdi + r14 + 1], al
movzx eax, byte [rbp + rcx - 0x5e]
mov byte [rdi + r14 + 2], al
mov byte [rdi + r14 + 3], 0xff
add rdi, 4
inc r15d
cmp r15d, edx
je 0x180098d96
sub esi, 1
jns 0x180098d87
mov rax, qword [rbx + 0xc0]
mov esi, 7
cmp rax, qword [rbx + 0xc8]
jae 0x180098d52
movzx ecx, byte [rax]
mov edx, r8d
inc rax
movzx r9d, cl
mov qword [rbx + 0xc0], rax
jmp 0x180098d8a
cmp dword [rbx + 0x30], 0
je 0x180098d7c
mov rcx, rbx
call fcn.18008e090
mov rax, qword [rbx + 0xc0]
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
mov edx, dword [rbx]
movzx r9d, cl
jmp 0x180098d8a
xor cl, cl
mov edx, r8d
movzx r9d, cl
jmp 0x180098d8a
mov edx, r8d
mov r8d, edx
cmp r15d, edx
jl 0x180098ce1
test r12d, r12d
je 0x180098dd9
cmp qword [rbx + 0x10], 0
je 0x180098dcf
mov ecx, dword [rbx + 0xc8]
sub ecx, dword [rbx + 0xc0]
cmp ecx, r12d
jge 0x180098dcf
mov rax, qword [rbx + 0xc8]
mov edx, r12d
sub edx, ecx
mov qword [rbx + 0xc0], rax
mov rcx, qword [rbx + 0x28]
call qword [rbx + Ordinal_26]
jmp 0x180098dd9
mov eax, r12d
add qword [rbx + 0xc0], rax
mov eax, dword [rbx + 4]
inc r13d
mov ecx, eax
cmp r13d, eax
jl 0x180098c83
jmp 0x180099582
xor r15d, r15d
test eax, eax
jle 0x180099582
nop word [rax + rax]
mov r8d, dword [rbx]
xor esi, esi
test r8d, r8d
jle 0x180098f50
nop
mov r9, qword [rbx + 0xc0]
cmp r9, qword [rbx + 0xc8]
jae 0x180098e30
movzx ecx, byte [r9]
inc r9
mov qword [rbx + 0xc0], r9
jmp 0x180098e5a
cmp dword [rbx + 0x30], 0
je 0x180098e58
mov rcx, rbx
call fcn.18008e090
mov rax, qword [rbx + 0xc0]
mov r8d, dword [rbx]
movzx ecx, byte [rax]
lea r9, [rax + 1]
mov qword [rbx + 0xc0], r9
jmp 0x180098e5a
xor cl, cl
xor r10d, r10d
movzx eax, cl
cmp r13d, 4
jne 0x180098e70
mov r10d, eax
and r10d, 0xf
shr eax, 4
movsxd rcx, edi
lea rdx, [rax*4]
movzx eax, byte [rbp + rdx - 0x60]
inc edi
mov byte [rcx + r14], al
movzx eax, byte [rbp + rdx - 0x5f]
movsxd rcx, edi
inc edi
mov byte [rcx + r14], al
movzx eax, byte [rbp + rdx - 0x5e]
movsxd rcx, edi
inc edi
mov byte [rcx + r14], al
movsxd rax, edi
inc edi
mov byte [rax + r14], 0xff
lea eax, [rsi + 1]
cmp eax, r8d
je 0x180098f50
cmp r13d, 8
jne 0x180098f05
cmp r9, qword [rbx + 0xc8]
jae 0x180098ed8
movzx ecx, byte [r9]
lea rax, [r9 + 1]
mov qword [rbx + 0xc0], rax
jmp 0x180098f01
cmp dword [rbx + 0x30], 0
je 0x180098eff
mov rcx, rbx
call fcn.18008e090
mov rax, qword [rbx + 0xc0]
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
mov r8d, dword [rbx]
jmp 0x180098f01
xor cl, cl
movzx r10d, cl
movsxd rcx, edi
lea rdx, [r10*4]
movzx eax, byte [rbp + rdx - 0x60]
inc edi
add esi, 2
mov r9d, r8d
mov byte [rcx + r14], al
movzx eax, byte [rbp + rdx - 0x5f]
movsxd rcx, edi
inc edi
mov byte [rcx + r14], al
movzx eax, byte [rbp + rdx - 0x5e]
movsxd rcx, edi
inc edi
mov byte [rcx + r14], al
movsxd rax, edi
inc edi
mov byte [rax + r14], 0xff
cmp esi, r8d
jl 0x180098e10
test r12d, r12d
je 0x180098f93
cmp qword [rbx + 0x10], 0
je 0x180098f89
mov ecx, dword [rbx + 0xc8]
sub ecx, dword [rbx + 0xc0]
cmp ecx, r12d
jge 0x180098f89
mov rax, qword [rbx + 0xc8]
mov edx, r12d
sub edx, ecx
mov qword [rbx + 0xc0], rax
mov rcx, qword [rbx + 0x28]
call qword [rbx + Ordinal_26]
jmp 0x180098f93
mov eax, r12d
add qword [rbx + 0xc0], rax
mov eax, dword [rbx + 4]
inc r15d
mov ecx, eax
cmp r15d, eax
jl 0x180098e00
jmp 0x180099582
mov rcx, r14
call fcn.180164304
mov edx, dword [0x1801eadf4]
mov rax, qword gs:[0x58]
mov rax, qword [rax + rdx*8]
lea rdx, str.bad_bpp
jmp 0x1800996e0
mov rcx, r14
call fcn.180164304
mov edx, dword [0x1801eadf4]
mov rax, qword gs:[0x58]
mov rax, qword [rax + rdx*8]
lea rdx, str.invalid
jmp 0x1800996e0
sub r15d, dword [rsp + 0x38]
xor eax, eax
mov dword [rsp + 0x44], eax
mov r13d, eax
mov dword [rsp + 0x4c], eax
mov dword [rsp + 0x54], eax
mov dword [rsp + 0x60], eax
mov dword [rsp + 0x40], eax
mov dword [rsp + 0x48], eax
mov dword [rsp + 0x50], eax
mov dword [rsp + 0x58], eax
sub r15d, r12d
je 0x18009907b
test r15d, r15d
jns 0x18009903b
mov rax, qword [rbx + 0xc8]
mov qword [rbx + 0xc0], rax
jmp 0x180099079
cmp qword [rbx + 0x10], rax
je 0x18009906f
mov ecx, dword [rbx + 0xc8]
sub ecx, dword [rbx + 0xc0]
cmp ecx, r15d
jge 0x18009906f
mov rax, qword [rbx + 0xc8]
sub r15d, ecx
mov rcx, qword [rbx + 0x28]
mov edx, r15d
mov qword [rbx + 0xc0], rax
call qword [rbx + Ordinal_26]
jmp 0x180099079
movsxd rax, r15d
add qword [rbx + 0xc0], rax
xor eax, eax
mov ecx, dword [rsp + 0x28]
cmp ecx, 0x18
jne 0x18009908b
mov eax, dword [rbx]
lea edx, [rax + rax*2]
jmp 0x180099098
cmp ecx, 0x10
jne 0x180099096
mov edx, dword [rbx]
add edx, edx
jmp 0x180099098
mov edx, eax
neg edx
and edx, 3
mov dword [rsp + 0x24], edx
cmp ecx, 0x18
jne 0x1800990b6
mov r12d, 1
mov qword [rsp + 0x38], r12
jmp 0x1800992c6
mov r11d, dword [rsp + 0x30]
cmp ecx, 0x20
mov ecx, dword [rbp + 0x400]
mov r10d, dword [rsp + 0x2c]
jne 0x180099103
cmp r11d, 0xff
jne 0x180099103
cmp r10d, 0xff00
jne 0x180099103
cmp ecx, 0xff0000
jne 0x180099103
mov r9d, dword [rsp + 0x34]
cmp r9d, 0xff000000
jne 0x180099122
mov r12d, 2
mov qword [rsp + 0x38], r12
jmp 0x1800992c6
test ecx, ecx
je 0x18009964e
test r10d, r10d
je 0x18009964e
test r11d, r11d
je 0x18009964e
mov r9d, dword [rsp + 0x34]
call fcn.180098130
mov edx, dword [rbp + 0x400]
sub eax, 7
mov ecx, dword [rbp + 0x400]
shr edx, 1
and ecx, 0x55555555
and edx, 0x55555555
mov dword [rsp + 0x44], eax
add edx, ecx
mov ecx, edx
and edx, 0x33333333
shr ecx, 2
and ecx, 0x33333333
add ecx, edx
mov edx, ecx
shr edx, 4
add edx, ecx
mov ecx, r10d
and edx, 0xf0f0f0f
mov eax, edx
shr eax, 8
add edx, eax
mov eax, edx
shr eax, 0x10
add eax, edx
movzx r15d, al
mov dword [rsp + 0x40], r15d
call fcn.180098130
sub eax, 7
mov edx, r10d
shr edx, 1
mov ecx, r10d
and edx, 0x55555555
mov dword [rsp + 0x4c], eax
and ecx, 0x55555555
add edx, ecx
mov ecx, edx
and edx, 0x33333333
shr ecx, 2
and ecx, 0x33333333
add ecx, edx
mov edx, ecx
shr edx, 4
add edx, ecx
mov ecx, r11d
and edx, 0xf0f0f0f
mov eax, edx
shr eax, 8
add edx, eax
mov eax, edx
shr eax, 0x10
add eax, edx
movzx esi, al
mov dword [rsp + 0x48], esi
call fcn.180098130
sub eax, 7
mov edx, r11d
shr edx, 1
mov ecx, r11d
and edx, 0x55555555
mov dword [rsp + 0x54], eax
and ecx, 0x55555555
add edx, ecx
mov ecx, edx
and edx, 0x33333333
shr ecx, 2
and ecx, 0x33333333
add ecx, edx
mov edx, ecx
shr edx, 4
add edx, ecx
mov ecx, r9d
and edx, 0xf0f0f0f
mov eax, edx
shr eax, 8
add edx, eax
mov eax, edx
shr eax, 0x10
add eax, edx
movzx r11d, al
mov dword [rsp + 0x50], r11d
call fcn.180098130
sub eax, 7
mov edx, r9d
shr edx, 1
mov ecx, r9d
and edx, 0x55555555
mov dword [rsp + 0x60], eax
and ecx, 0x55555555
add edx, ecx
mov ecx, edx
and edx, 0x33333333
shr ecx, 2
and ecx, 0x33333333
add ecx, edx
mov edx, ecx
shr edx, 4
add edx, ecx
and edx, 0xf0f0f0f
mov eax, edx
shr eax, 8
add edx, eax
mov eax, edx
shr eax, 0x10
add eax, edx
movzx r8d, al
mov dword [rsp + 0x58], r8d
cmp r15d, 8
ja 0x18009964e
cmp esi, 8
ja 0x18009964e
cmp r11d, 8
ja 0x18009964e
xor r12d, r12d
mov qword [rsp + 0x38], r12
cmp r8d, 8
ja 0x18009964e
mov edx, dword [rsp + 0x24]
mov eax, dword [rbx + 4]
xor esi, esi
mov dword [rsp + 0x20], esi
mov ecx, eax
test eax, eax
jle 0x180099582
nop dword [rax]
mov eax, dword [rbx]
movsxd rcx, r13d
test r12, r12
je 0x180099482
xor esi, esi
test eax, eax
jle 0x180099437
mov r15d, dword [rbp + 0x408]
lea rdi, [rcx + r14]
nop dword [rax]
nop word [rax + rax]
mov rcx, qword [rbx + 0xc8]
mov rax, qword [rbx + 0xc0]
cmp rax, rcx
jb 0x18009933f
cmp dword [rbx + 0x30], 0
je 0x180099356
mov rcx, rbx
call fcn.18008e090
mov rax, qword [rbx + 0xc0]
mov rcx, qword [rbx + 0xc8]
movzx edx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
mov byte [rdi + 2], dl
cmp rax, rcx
jae 0x18009935a
jmp 0x180099376
mov byte [rdi + 2], 0
cmp dword [rbx + 0x30], 0
je 0x18009939a
mov rcx, rbx
call fcn.18008e090
mov rax, qword [rbx + 0xc0]
mov rcx, qword [rbx + 0xc8]
movzx edx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
mov byte [rdi + 1], dl
cmp rax, rcx
jae 0x18009939e
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x1800993c4
mov byte [rdi + 1], 0
cmp dword [rbx + 0x30], 0
je 0x1800993c2
mov rcx, rbx
call fcn.18008e090
mov rax, qword [rbx + 0xc0]
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x1800993c4
xor cl, cl
mov byte [rdi], cl
cmp r12, 2
jne 0x18009940c
cmp rax, qword [rbx + 0xc8]
jae 0x1800993e4
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18009940e
cmp dword [rbx + 0x30], 0
je 0x180099408
mov rcx, rbx
call fcn.18008e090
mov rax, qword [rbx + 0xc0]
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18009940e
xor cl, cl
jmp 0x18009940e
mov cl, 0xff
movzx eax, cl
add r13d, 4
mov byte [rdi + 3], cl
or r15d, eax
add rdi, 4
inc esi
cmp esi, dword [rbx]
jl 0x180099310
mov edx, dword [rsp + 0x24]
mov edi, r15d
mov dword [rbp + 0x408], r15d
mov esi, dword [rsp + 0x20]
test edx, edx
je 0x18009956f
cmp qword [rbx + 0x10], 0
je 0x180099566
mov ecx, dword [rbx + 0xc8]
sub ecx, dword [rbx + 0xc0]
cmp ecx, edx
jge 0x180099566
mov rax, qword [rbx + 0xc8]
sub edx, ecx
mov rcx, qword [rbx + 0x28]
mov qword [rbx + 0xc0], rax
call qword [rbx + Ordinal_26]
mov edx, dword [rsp + 0x24]
jmp 0x18009956f
test eax, eax
jle 0x18009955c
lea r15, [rcx + r14]
mov r14d, dword [rsp + 0x28]
mov rcx, rbx
call fcn.18008e2a0
cmp r14d, 0x10
jne 0x1800994a5
mov esi, eax
jmp 0x1800994bc
mov rcx, rbx
mov edi, eax
call fcn.18008e2a0
mov esi, eax
shl esi, 0x10
add esi, edi
mov edi, dword [rbp + 0x408]
mov r8d, dword [rsp + 0x40]
mov ecx, esi
and ecx, dword [rbp + 0x400]
mov edx, dword [rsp + 0x44]
call fcn.1800981a0
mov r8d, dword [rsp + 0x48]
mov ecx, esi
and ecx, dword [rsp + 0x2c]
mov edx, dword [rsp + 0x4c]
mov byte [r15], al
call fcn.1800981a0
mov r8d, dword [rsp + 0x50]
mov ecx, esi
and ecx, dword [rsp + 0x30]
mov edx, dword [rsp + 0x54]
mov byte [r15 + 1], al
call fcn.1800981a0
mov r9d, dword [rsp + 0x34]
mov byte [r15 + 2], al
test r9d, r9d
je 0x180099524
mov r8d, dword [rsp + 0x58]
and esi, r9d
mov edx, dword [rsp + 0x60]
mov ecx, esi
call fcn.1800981a0
jmp 0x180099529
mov eax, 0xff
or edi, eax
mov byte [r15 + 3], al
add r15, 4
mov dword [rbp + 0x408], edi
add r13d, 4
inc r12d
cmp r12d, dword [rbx]
jl 0x180099493
mov r14, qword [rsp + 0x70]
mov edx, dword [rsp + 0x24]
mov r12, qword [rsp + 0x38]
jmp 0x180099437
mov r12, qword [rsp + 0x38]
jmp 0x18009943b
mov eax, edx
add qword [rbx + 0xc0], rax
mov eax, dword [rbx + 4]
inc esi
mov dword [rsp + 0x20], esi
mov ecx, eax
cmp esi, eax
jl 0x1800992e0
cmp dword [rbp + 0x408], 0
jne 0x1800995ae
imul eax, dword [rbx]
lea eax, [rax*4 - 1]
movsxd rdx, eax
test eax, eax
js 0x1800995ae
nop dword [rax]
mov byte [rdx + r14], 0xff
sub rdx, 4
jns 0x1800995a0
mov ecx, dword [rbx + 4]
cmp dword [rsp + 0x68], 0
jle 0x180099621
xor r10d, r10d
mov edx, ecx
test ecx, 0xfffffffe
jle 0x180099621
mov ecx, dword [rbx]
sub edx, r10d
dec edx
mov r9d, ecx
imul edx, ecx
xor r8d, r8d
imul r9d, r10d
lea eax, [rcx*4]
shl edx, 2
mov r11d, edx
add rdx, r14
shl r9d, 2
test eax, eax
jle 0x180099610
sub r9, r11
movzx eax, byte [rdx]
inc r8d
movzx ecx, byte [rdx + r9]
mov byte [rdx + r9], al
mov byte [rdx], cl
lea rdx, [rdx + 1]
mov eax, dword [rbx]
shl eax, 2
cmp r8d, eax
jl 0x1800995f1
mov ecx, dword [rbx + 4]
inc r10d
mov eax, ecx
mov edx, ecx
sar eax, 1
cmp r10d, eax
jl 0x1800995c2
mov eax, dword [rbx]
mov rdx, qword [rbp + 0x3e8]
mov dword [rdx], eax
mov rax, qword [rbp + 0x3f0]
mov dword [rax], ecx
mov rcx, qword [rbp + 0x3f8]
test rcx, rcx
je 0x180099646
mov eax, dword [rbx + 8]
mov dword [rcx], eax
mov rax, r14
jmp 0x1800996eb
mov rcx, r14
call fcn.180164304
mov edx, dword [0x1801eadf4]
mov rax, qword gs:[0x58]
mov rax, qword [rax + rdx*8]
lea rdx, str.bad_masks
jmp 0x1800996e0
mov edx, dword [0x1801eadf4]
mov rax, qword gs:[0x58]
mov rax, qword [rax + rdx*8]
lea rdx, str.outofmem
jmp 0x1800996e0
mov edx, dword [0x1801eadf4]
mov rax, qword gs:[0x58]
mov rax, qword [rax + rdx*8]
lea rdx, str.too_large
jmp 0x1800996e0
mov edx, dword [0x1801eadf4]
mov rax, qword gs:[0x58]
mov rax, qword [rax + rdx*8]
lea rdx, str.bad_offset
jmp 0x1800996e0
mov edx, dword [0x1801eadf4]
mov rax, qword gs:[0x58]
mov rax, qword [rax + rdx*8]
lea rdx, str.bad_header
mov ecx, Ordinal_41
mov qword [rcx + rax], rdx
xor eax, eax
mov r14, qword [rsp + 0x4a8]
mov r13, qword [rsp + 0x4b0]
mov r12, qword [rsp + 0x4b8]
mov rdi, qword [rsp + 0x4e0]
mov r15, qword [rsp + 0x4a0]
add rsp, 0x4c0
pop rsi
pop rbx
pop rbp
ret