Function at 0x140294430
Capabilities:
Encrypt data using rc4 prga

Disassembly:
endbr64
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov rdi, qword [0x14041fc80]
mov rbp, qword [rcx]
mov rax, qword [rdi]
mov qword [rsp + 0x28], rax
xor eax, eax
lea rbx, [rdx*8]
cmp rbx, 0x80
ja 0x140294220
mov rax, rbx
shr rax, 3
cmp rbx, 1
adc rax, 0
mov rcx, qword [rbp + rax*8 + 0x20]
test rcx, rcx
je 0x1402941f0
mov rdx, qword [rcx]
mov qword [rbp + rax*8 + 0x20], rdx
mov r8, rbx
xor edx, edx
call fcn.140197fc0
mov rcx, rax
mov rax, qword [rsp + 0x28]
sub rax, qword [rdi]
jne 0x1402942a0
mov rax, rcx
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
ret
mov rcx, qword [rbp + 0xa8]
lea rsi, [rax*8]
mov rax, qword [rbp + 0xb0]
sub rax, rcx
cmp rsi, rax
jg 0x140294238
lea rax, [rcx + rsi]
mov qword [rbp + 0xa8], rax
jmp 0x1402941c2
mov rcx, rbx
mov edx, 8
call fcn.1402aa920
mov rcx, rax
jmp 0x1402941c2
test rax, rax
je 0x14029424e
shr rax, 3
mov rdx, qword [rbp + rax*8 + 0x20]
mov qword [rcx], rdx
mov qword [rbp + rax*8 + 0x20], rcx
mov rcx, qword [rbp]
mov edx, 8
call fcn.1402aa920
mov ecx, 0x18
mov qword [rbp + 0xa8], rax
add rax, qword [rbp]
mov qword [rbp + 0xb0], rax
call fcn.1402aa8b0
lea rdx, [rbp + 8]
mov rcx, rax
mov rax, qword [rbp + 0xa8]
mov qword [rcx + 0x10], rax
call fcn.140294140
add qword [rbp + 0x18], 1
mov rcx, qword [rbp + 0xa8]
jmp 0x14029420e
call fcn.14018c640
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
endbr64
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov r12, qword [0x14041fc80]
mov rax, qword [r12]
mov qword [rsp + 0x28], rax
xor eax, eax
mov rdi, rcx
xor ecx, ecx
mov rbx, rdx
mov rsi, qword [rdi]
tzcnt ecx, r9d
mov eax, 0x1f
test r9d, r9d
cmove ecx, eax
xor edx, edx
sub rbx, rsi
test rbx, rbx
jg 0x14029430d
jmp 0x140294404
add rdx, 1
cmp rbx, rdx
je 0x1402943e0
cmp byte [rsi + rdx], 0x30
je 0x140294300
lea rax, [rsi + rdx]
cmp rbx, rdx
jle 0x140294401
cmp r9d, 2
je 0x1402943f0
movzx r10d, byte [rax]
lea r13, [0x14042b560]
movzx r10d, byte [r13 + r10]
mov ebp, r10d
cmp r10d, r9d
jge 0x14029440e
mov dword [r8], r10d
lea r10, [rdx + 1]
cmp rbx, r10
jg 0x140294374
jmp 0x140294415
mov eax, dword [r8]
add r10, 1
shl eax, cl
or eax, r11d
mov dword [r8], eax
cmp rbx, r10
je 0x140294384
movzx eax, byte [rsi + r10]
movzx r11d, byte [r13 + rax]
cmp r11d, r9d
jl 0x140294360
lea rax, [rsi + r10]
movsxd r8, ecx
sub r10, rdx
imul r10, r8
cmp r9d, 2
je 0x1402943b5
test bpl, bpl
je 0x1402943b2
bsr ebp, ebp
mov edx, 0x20
xor ebp, 0x1f
sub edx, ebp
movzx edx, dl
sub ecx, edx
movsxd r8, ecx
sub r10, r8
cmp r10, 0x20
setle dl
mov qword [rdi], rax
mov rax, qword [rsp + 0x28]
sub rax, qword [r12]
jne 0x140294424
mov eax, edx
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
ret
lea rax, [rsi + rbx]
jmp 0x140294317
mov r10, rdx
xor ebp, ebp
lea r13, [0x14042b560]
jmp 0x140294374
mov rsi, rax
mov rax, rsi
mov edx, 1
jmp 0x1402943bc
mov edx, 1
jmp 0x1402943bc
movsxd r8, ecx
lea rax, [rsi + r10]
mov r10, r8
jmp 0x140294398
call fcn.14018c640
nop
nop
nop
nop
nop
nop
nop
endbr64
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov r13, qword [0x14041fc80]
mov rax, qword [r13]
mov qword [rsp + 0x28], rax
xor eax, eax
mov rdi, rcx
xor ecx, ecx
mov rbx, rdx
mov rsi, qword [rdi]
tzcnt ecx, r9d
mov eax, 0x1f
test r9d, r9d
cmove ecx, eax
xor edx, edx
sub rbx, rsi
test rbx, rbx
jg 0x14029448d
jmp 0x140294585
add rdx, 1
cmp rbx, rdx
je 0x140294560
cmp byte [rsi + rdx], 0x30
je 0x140294480
lea rax, [rsi + rdx]
cmp rbx, rdx
jle 0x140294582
cmp r9d, 2
je 0x140294570
movzx r10d, byte [rax]
lea rbp, [0x14042b560]
movzx r10d, byte [rbp + r10]
mov r12d, r10d
cmp r10d, r9d
jge 0x14029458f
movzx eax, r10b
lea r11, [rdx + 1]
mov qword [r8], rax
cmp rbx, r11
jg 0x1402944f5
jmp 0x140294596
mov rax, qword [r8]
add r11, 1
shl rax, cl
or rax, r10
mov qword [r8], rax
cmp rbx, r11
je 0x140294507
movzx eax, byte [rsi + r11]
movzx eax, byte [rbp + rax]
mov r10, rax
cmp eax, r9d
jl 0x1402944e0
lea rax, [rsi + r11]
movsxd r8, ecx
sub r11, rdx
imul r11, r8
cmp r9d, 2
je 0x14029453b
test r12b, r12b
je 0x140294538
bsr r12d, r12d
mov edx, 0x20
xor r12d, 0x1f
sub edx, r12d
movzx edx, dl
sub ecx, edx
movsxd r8, ecx
sub r11, r8
cmp r11, 0x40
setle dl
mov qword [rdi], rax
mov rax, qword [rsp + 0x28]
sub rax, qword [r13]
jne 0x1402945a5
mov eax, edx
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
ret
lea rax, [rsi + rbx]
jmp 0x140294497
mov r11, rdx
xor r12d, r12d
lea rbp, [0x14042b560]
jmp 0x1402944f5
mov rsi, rax
mov rax, rsi
mov edx, 1
jmp 0x140294542
mov edx, 1
jmp 0x140294542
movsxd r8, ecx
lea rax, [rsi + r11]
mov r11, r8
jmp 0x14029451b
call fcn.14018c640
nop
nop
nop
nop
nop
nop