Function at 0x140136650
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x38
mov ebp, dword [rcx + 0x24]
mov rbx, rcx
mov r9d, dword [rcx + 0x2c]
mov r8d, ebp
mov r11d, dword [rcx + 0x54]
and r8d, 0x7fff
mov esi, dword [rcx + 0x50]
mov r15d, 8
mov r13d, dword [rcx + 0x28]
mov r12, qword [rcx + 0x30]
mov r14, qword [rcx + 0x38]
mov dword [rsp + 0x90], r8d
mov dword [rsp + 0x98], ebp
mov dword [rsp + 0x80], r9d
mov dword [rsp + 0x88], r11d
mov dword [rsp + 0x20], esi
mov rdx, qword [rbx + 0xb8]
test rdx, rdx
jne 0x1401366d2
cmp dword [rbx + 0xa8], edx
je 0x140136be1
test r13d, r13d
je 0x140136be1
mov edi, r13d
mov ecx, 0x1000
add edi, ebp
sub ecx, r13d
and edi, 0x7fff
mov eax, edx
cmp rdx, rcx
cmovae eax, ecx
mov ebp, eax
add r13d, eax
sub rdx, rbp
mov qword [rbx + 0xb8], rdx
test eax, eax
je 0x14013679a
mov rdx, qword [rbx + 0xb0]
nop dword [rax + rax]
mov eax, 0x8000
mov r15d, edi
sub eax, edi
lea rcx, [rbx + 0xc8]
cmp eax, ebp
cmovae eax, ebp
add rcx, r15
mov r8d, eax
mov esi, eax
call sub.VCRUNTIME140.dll_memcpy
cmp edi, 0x101
jae 0x140136760
mov rdx, qword [rbx + 0xb0]
lea rcx, [rbx + 0x80c8]
mov eax, 0x101
sub eax, edi
cmp esi, eax
cmovb eax, esi
add rcx, rdi
mov r8d, eax
call sub.VCRUNTIME140.dll_memcpy
add qword [rbx + 0xb0], rsi
add edi, esi
mov rdx, qword [rbx + 0xb0]
and edi, 0x7fff
sub ebp, esi
jne 0x140136710
mov esi, dword [rsp + 0x20]
lea r15d, [rbp + 8]
mov r9d, dword [rsp + 0x80]
mov r11d, dword [rsp + 0x88]
mov r8d, dword [rsp + 0x90]
mov eax, 0x8000
sub eax, r13d
cmp eax, r9d
cmovae eax, r9d
cmp dword [rbx + 0xa8], 0
mov r9d, eax
jne 0x1401367c2
cmp r13d, 0x1000
jb 0x140136bda
mov ebp, dword [rsp + 0x98]
mov dword [rsp + 0x80], eax
cmp r13d, 4
jb 0x140136ae1
mov dword [rsp + 0x80], r9d
mov eax, r8d
lea r15, [rbx + 0xc8]
add r15, rax
mov r10d, 1
mov edi, dword [r15]
and edi, 0xffffff
mov eax, edi
mov ecx, edi
shr rcx, 0x11
xor rcx, rax
movzx eax, bp
and ecx, 0xfff
movzx r8d, word [rbx + rcx*2 + 0x292aa]
sub ax, r8w
mov word [rbx + rcx*2 + 0x292aa], bp
movzx ebp, ax
cmp ebp, r9d
ja 0x1401369db
mov eax, r8d
lea r9, [rbx + 0xc8]
and eax, 0x7fff
mov edx, r8d
add r9, rax
and edx, 0x7fff
lea eax, [rdx + 2]
movzx r8d, byte [rax + rbx + 0xc8]
lea eax, [rdx + 1]
movzx eax, byte [rax + rbx + 0xc8]
shl r8d, 8
or r8d, eax
movzx eax, byte [r9]
shl r8d, 8
or r8d, eax
cmp r8d, edi
jne 0x1401369db
mov rax, r15
lea r11d, [r10 + 0x1f]
nop word [rax + rax]
movzx r8d, word [rax + 2]
add rax, 2
movzx r10d, word [r9 + 2]
cmp r8w, r10w
jne 0x1401368fc
movzx edx, word [rax + 2]
add rax, 2
movzx ecx, word [r9 + 4]
movzx r8d, dl
movzx r10d, cl
cmp dx, cx
jne 0x1401368fc
movzx edx, word [rax + 2]
add rax, 2
movzx ecx, word [r9 + 6]
movzx r8d, dl
movzx r10d, cl
cmp dx, cx
jne 0x1401368fc
movzx ecx, word [rax + 2]
add rax, 2
movzx edx, word [r9 + 8]
add r9, 8
movzx r8d, cl
movzx r10d, dl
cmp cx, dx
jne 0x1401368fc
add r11d, 0xffffffff
jne 0x140136890
xor ecx, ecx
sub rax, r15
sar rax, 1
cmp r8b, r10b
sete cl
lea edx, [rcx + rax*2]
test r11d, r11d
jne 0x14013691e
mov eax, ebp
neg eax
sbb edx, edx
and edx, 0x102
cmp edx, 3
jb 0x1401369b5
jne 0x140136935
cmp ebp, 0x2000
jae 0x1401369b5
mov r11d, dword [rsp + 0x88]
lea r8, [0x140000000]
cmp edx, r13d
mov r10d, r13d
cmovb r10d, edx
dec ebp
mov word [r12 + 1], bp
mov edx, ebp
shr rdx, 8
lea eax, [r10 - 3]
mov byte [r12], al
movzx eax, byte [r14]
shr al, 1
or al, 0x80
mov byte [r14], al
mov eax, ebp
and eax, 0x1ff
cmp ebp, 0x200
movzx ecx, byte [rax + r8 + 0x149160]
movzx eax, byte [rdx + r8 + 0x1489f0]
cmovb eax, ecx
inc word [rbx + rax*2 + 0x840a]
lea eax, [r10 - 3]
movzx eax, word [r8 + rax*2 + 0x148f60]
inc word [rbx + rax*2 + 0x81ca]
mov eax, 3
jmp 0x1401369f1
mov r11d, dword [rsp + 0x88]
mov r10d, 1
movzx eax, dil
mov byte [r12], al
shr byte [r14], 1
inc word [rbx + rax*2 + 0x81ca]
mov eax, r10d
jmp 0x1401369f1
movzx eax, dil
mov byte [r12], al
shr byte [r14], 1
inc word [rbx + rax*2 + 0x81ca]
mov rax, r10
mov ebp, dword [rsp + 0x98]
lea rdx, [rax + r12]
mov r8d, dword [rsp + 0x90]
lea r12, [rdx + 1]
add esi, 0xffffffff
mov r9d, 0x8000
mov ecx, esi
mov r15d, 8
cmove esi, r15d
mov rax, rdx
test ecx, ecx
mov dword [rsp + 0x20], esi
cmovne rax, r14
cmovne r12, rdx
mov r14, rax
add r11d, r10d
mov eax, dword [rsp + 0x80]
add ebp, r10d
add eax, r10d
mov dword [rsp + 0x88], r11d
cmp eax, r9d
mov dword [rsp + 0x98], ebp
cmovb r9d, eax
add r8d, r10d
and r8d, 0x7fff
mov dword [rsp + 0x80], r9d
sub r13d, r10d
mov dword [rsp + 0x90], r8d
lea rax, [rbx + 0x192a2]
cmp r12, rax
jbe 0x140136ad7
xor edx, edx
mov dword [rbx + 0x24], ebp
mov rcx, rbx
mov dword [rbx + 0x28], r13d
mov dword [rbx + 0x2c], r9d
mov dword [rbx + 0x54], r11d
mov qword [rbx + 0x30], r12
mov qword [rbx + 0x38], r14
mov dword [rbx + 0x50], esi
call fcn.140135f20
test eax, eax
jne 0x140136c02
mov r11d, dword [rbx + 0x54]
mov esi, dword [rbx + 0x50]
mov r12, qword [rbx + 0x30]
mov r14, qword [rbx + 0x38]
mov r9d, dword [rsp + 0x80]
mov r8d, dword [rsp + 0x90]
mov dword [rsp + 0x88], r11d
mov dword [rsp + 0x20], esi
cmp r13d, 4
jae 0x1401367e2
test r13d, r13d
je 0x1401366b1
lea rdi, [rbx + 0x192a2]
inc r11d
mov eax, r8d
lea rcx, [r12 + 1]
mov dword [rsp + 0x88], r11d
movzx edx, byte [rax + rbx + 0xc8]
mov byte [r12], dl
shr byte [r14], 1
add esi, 0xffffffff
mov eax, esi
cmove esi, r15d
test eax, eax
mov dword [rsp + 0x20], esi
cmovne rcx, r14
neg eax
mov r14, rcx
sbb rax, rax
inc word [rbx + rdx*2 + 0x81ca]
add rax, 2
inc ebp
add r12, rax
mov dword [rsp + 0x98], ebp
lea eax, [r9 + 1]
mov r9d, 0x8000
cmp eax, r9d
inc r8d
cmovb r9d, eax
and r8d, 0x7fff
dec r13d
mov dword [rsp + 0x80], r9d
mov dword [rsp + 0x90], r8d
cmp r12, rdi
jbe 0x140136bcc
mov qword [rbx + 0x38], rcx
xor edx, edx
mov rcx, rbx
mov dword [rbx + 0x24], ebp
mov dword [rbx + 0x28], r13d
mov dword [rbx + 0x2c], r9d
mov dword [rbx + 0x54], r11d
mov qword [rbx + 0x30], r12
mov dword [rbx + 0x50], esi
call fcn.140135f20
test eax, eax
jne 0x140136c02
mov r11d, dword [rbx + 0x54]
mov esi, dword [rbx + 0x50]
mov r12, qword [rbx + 0x30]
mov r14, qword [rbx + 0x38]
mov r9d, dword [rsp + 0x80]
mov r8d, dword [rsp + 0x90]
mov dword [rsp + 0x88], r11d
mov dword [rsp + 0x20], esi
test r13d, r13d
jne 0x140136af1
jmp 0x1401366b1
mov ebp, dword [rsp + 0x98]
mov dword [rbx + 0x24], ebp
mov eax, 1
mov dword [rbx + 0x28], r13d
mov dword [rbx + 0x2c], r9d
mov dword [rbx + 0x54], r11d
mov qword [rbx + 0x30], r12
mov qword [rbx + 0x38], r14
mov dword [rbx + 0x50], esi
jmp 0x140136c0a
mov eax, 0
setns al
add rsp, 0x38
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret