Function at 0x180017690
Capabilities:
Decompress data using aplib

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
movzx eax, byte [rcx]
mov ebx, dword [rsp + 0x30]
mov rsi, rdx
xor r9d, r9d
xor r11d, r11d
lea r10, [rdx + 1]
mov byte [rdx], al
mov edx, dword [rsp + 0x10]
lea r8, [rcx + 1]
xor edi, edi
nop
mov eax, r9d
add r9d, 0xffffffff
test eax, eax
jne 0x1800176d7
movzx edx, byte [r8]
add r8, 1
lea r9d, [rax + 7]
mov eax, edx
add edx, edx
shr eax, 7
and eax, 1
je 0x18001796e
mov eax, r9d
add r9d, 0xffffffff
test eax, eax
jne 0x1800176fe
movzx edx, byte [r8]
add r8, 1
lea r9d, [rax + 7]
mov eax, edx
add edx, edx
shr eax, 7
and eax, 1
je 0x1800177df
mov eax, r9d
add r9d, 0xffffffff
test eax, eax
jne 0x180017725
movzx edx, byte [r8]
add r8, 1
lea r9d, [rax + 7]
mov eax, edx
add edx, edx
shr eax, 7
and eax, 1
je 0x18001778a
xor ecx, ecx
lea r11d, [rcx + 4]
nop
nop
nop
mov eax, r9d
add r9d, 0xffffffff
test eax, eax
jne 0x180017757
movzx edx, byte [r8]
add r8, 1
lea r9d, [rax + 7]
mov eax, edx
add edx, edx
shr eax, 7
and eax, 1
sub r11d, 1
lea ecx, [rax + rcx*2]
jne 0x180017740
test ecx, ecx
je 0x180017781
mov eax, ecx
mov rcx, r10
sub rcx, rax
movzx eax, byte [rcx]
mov byte [r10], al
jmp 0x180017979
mov byte [r10], 0
jmp 0x180017979
movzx ebx, byte [r8]
add r8, 1
mov ecx, ebx
and ecx, 1
add ecx, 2
shr ebx, 1
je 0x1800177cf
test ecx, ecx
mov r11d, ebx
je 0x1800177d4
nop
nop
nop
mov rax, r10
add r10, 1
sub rax, r11
add ecx, 0xffffffff
movzx eax, byte [rax]
mov byte [r10 - 1], al
jne 0x1800177b0
lea r11d, [rcx + 1]
jmp 0x180017980
mov edi, 1
mov r11d, 1
jmp 0x180017980
mov ecx, 1
mov eax, r9d
add r9d, 0xffffffff
test eax, eax
jne 0x1800177fb
movzx edx, byte [r8]
add r8, 1
lea r9d, [rax + 7]
mov eax, edx
add edx, edx
shr eax, 7
and eax, 1
lea ecx, [rax + rcx*2]
mov eax, r9d
add r9d, 0xffffffff
test eax, eax
jne 0x18001781f
movzx edx, byte [r8]
add r8, 1
lea r9d, [rax + 7]
mov eax, edx
add edx, edx
shr eax, 7
and eax, 1
jne 0x1800177e4
test r11d, r11d
jne 0x1800178c4
cmp ecx, 2
jne 0x1800178bf
lea ecx, [rax + 1]
mov eax, r9d
add r9d, 0xffffffff
test eax, eax
jne 0x180017857
movzx edx, byte [r8]
add r8, 1
lea r9d, [rax + 7]
mov eax, edx
add edx, edx
shr eax, 7
and eax, 1
lea ecx, [rax + rcx*2]
mov eax, r9d
add r9d, 0xffffffff
test eax, eax
jne 0x18001787b
movzx edx, byte [r8]
add r8, 1
lea r9d, [rax + 7]
mov eax, edx
add edx, edx
shr eax, 7
and eax, 1
jne 0x180017840
test ecx, ecx
movsxd r11, ebx
je 0x180017966
nop
nop
nop
nop
mov rax, r10
add r10, 1
sub rax, r11
add ecx, 0xffffffff
movzx eax, byte [rax]
mov byte [r10 - 1], al
jne 0x1800178a0
lea r11d, [rcx + 1]
jmp 0x180017980
lea ebx, [rcx - 3]
jmp 0x1800178c7
lea ebx, [rcx - 2]
movzx eax, byte [r8]
shl ebx, 8
mov ecx, 1
add ebx, eax
add r8, 1
nop
nop
mov eax, r9d
add r9d, 0xffffffff
test eax, eax
jne 0x1800178f7
movzx edx, byte [r8]
add r8, 1
lea r9d, [rax + 7]
mov eax, edx
add edx, edx
shr eax, 7
and eax, 1
lea ecx, [rax + rcx*2]
mov eax, r9d
add r9d, 0xffffffff
test eax, eax
jne 0x18001791b
movzx edx, byte [r8]
add r8, 1
lea r9d, [rax + 7]
mov eax, edx
add edx, edx
shr eax, 7
and eax, 1
jne 0x1800178e0
cmp ebx, 0x7d00
jb 0x180017932
add ecx, 1
cmp ebx, 0x500
jb 0x18001793d
add ecx, 1
cmp ebx, 0x80
jae 0x180017948
add ecx, 2
test ecx, ecx
movsxd r11, ebx
je 0x180017966
nop
mov rax, r10
add r10, 1
sub rax, r11
add ecx, 0xffffffff
movzx eax, byte [rax]
mov byte [r10 - 1], al
jne 0x180017950
mov r11d, 1
jmp 0x180017980
movzx ecx, byte [r8]
add r8, 1
mov byte [r10], cl
add r10, 1
xor r11d, r11d
test edi, edi
je 0x1800176c0
mov rbx, qword [rsp + 0x38]
sub r10, rsi
mov rsi, qword [rsp + 0x40]
mov eax, r10d
add rsp, 0x20
pop rdi
ret