Function at 0x14038d4b0
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
test rcx, rcx
je 0x14037afe2
push rbx
sub rsp, 0x20
mov eax, dword [rcx + 0x220]
mov rbx, rcx
cmp dword [rcx + 0x234], eax
jae 0x14037afdd
mov r9d, 2
xor r8d, r8d
xor edx, edx
call fcn.14038c3f0
mov rcx, rbx
mov dword [rbx + 0x2bc], 0
call fcn.140384fe0
add rsp, 0x20
pop rbx
ret
push rbx
sub rsp, 0x20
xor r9d, r9d
mov rbx, rcx
call fcn.14038c3f0
mov rcx, qword [rbx + 0x240]
test rcx, rcx
je 0x14038c262
mov rax, qword [rbx + 0x248]
mov qword [rbx + 0x240], rax
mov qword [rbx + 0x248], rcx
inc dword [rbx + 0x234]
mov eax, dword [rbx + 0x234]
cmp eax, dword [rbx + 0x220]
jb 0x14038c3bd
cmp byte [rbx + 0x284], 0
je 0x14038c3aa
test byte [rbx + 0x16c], 2
movzx ecx, byte [rbx + 0x285]
mov dword [rbx + 0x234], 0
je 0x14038c2ae
inc cl
mov byte [rbx + 0x285], cl
jmp 0x14038c344
mov qword [rsp + 0x30], rdi
movzx eax, cl
lea rdi, [0x140000000]
nop dword [rax]
lea ecx, [rax + 1]
mov byte [rbx + 0x285], cl
cmp cl, 7
jae 0x14038c33f
movzx r11d, cl
movzx r8d, byte [r11 + rdi + 0x4cd4b8]
movzx eax, byte [r11 + rdi + 0x4cd4b0]
mov edx, r8d
movzx r9d, byte [r11 + rdi + 0x4cd4c8]
sub edx, eax
mov eax, dword [rbx + 0x218]
dec eax
add eax, edx
xor edx, edx
div r8d
movzx edx, byte [r11 + rdi + 0x4cd4c0]
mov r8d, r9d
mov r10d, eax
mov dword [rbx + 0x224], eax
mov eax, dword [rbx + 0x21c]
sub r8d, edx
dec eax
xor edx, edx
add eax, r8d
div r9d
mov dword [rbx + 0x220], eax
mov r8d, eax
movzx eax, cl
test r10d, r10d
je 0x14038c2c0
test r8d, r8d
je 0x14038c2c0
mov rdi, qword [rsp + 0x30]
cmp cl, 7
jae 0x14038c3aa
mov r9, qword [rbx + 0x240]
test r9, r9
je 0x14038c3bd
movzx eax, byte [rbx + 0x289]
movzx ecx, byte [rbx + 0x28c]
mov r8d, eax
mov edx, dword [rbx + 0x218]
imul eax, ecx
imul r8, rcx
cmp eax, 8
jb 0x14038c38f
shr r8, 3
mov rcx, r9
imul r8, rdx
xor edx, edx
inc r8
call sub.VCRUNTIME140.dll_memset
jmp 0x14038c3bd
imul r8, rdx
xor edx, edx
mov rcx, r9
add r8, 7
shr r8, 3
inc r8
call sub.VCRUNTIME140.dll_memset
jmp 0x14038c3bd
mov r9d, 4
xor r8d, r8d
xor edx, edx
mov rcx, rbx
call fcn.14038c3f0
mov eax, dword [rbx + 0x2bc]
mov ecx, dword [rbx + 0x2b8]
inc eax
mov dword [rbx + 0x2bc], eax
test ecx, ecx
je 0x14038c3e6
cmp eax, ecx
jb 0x14038c3e6
mov rcx, rbx
add rsp, 0x20
pop rbx
jmp 0x14037afa0
add rsp, 0x20
pop rbx
ret
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
push rbx
push rbp
push rdi
push r13
push r14
sub rsp, 0x60
mov r14, qword [rcx + 0x248]
movabs rax, 0x1ffffffffffffff
movzx ebp, byte [rdx + 0x13]
xor edi, edi
mov r9, qword [rdx + 8]
add ebp, 7
movzx r13d, byte [rcx + 0x286]
mov rbx, rcx
shr ebp, 3
mov r11, 0xfffffffffffffeff
mov dword [rsp + 0xa8], r13d
mov dword [rsp + 0xa0], ebp
mov qword [rsp + 0x20], r14
mov qword [rsp + 0x28], r14
cmp r9, rax
jb 0x14038d528
mov eax, r13d
neg eax
and r13d, eax
mov dword [rsp + 0xa8], r13d
jmp 0x14038d563
test r13b, 8
je 0x14038d563
cmp r13d, 8
je 0x14038d563
mov r11, rdi
mov rdx, rdi
test r9, r9
je 0x14038d563
nop
movzx ecx, byte [r14 + rdx + 1]
mov eax, 0x100
sub eax, ecx
cmp ecx, 0x80
cmovae ecx, eax
inc rdx
mov eax, ecx
add r11, rax
cmp rdx, r9
jb 0x14038d540
mov qword [rsp + 0x58], rsi
mov qword [rsp + 0x50], r12
mov qword [rsp + 0x48], r15
cmp r13d, 0x10
jne 0x14038d84e
mov r15, qword [rbx + 0x250]
lea r8, [r14 + 1]
mov r10d, ebp
mov rsi, rdi
mov rdx, r8
mov byte [r15], 1
lea rcx, [r15 + 1]
test ebp, ebp
je 0x14038d5b1
mov esi, r10d
nop
movzx eax, byte [rdx]
inc rdx
mov byte [rcx], al
inc rcx
sub r10, 1
jne 0x14038d5a0
mov r10, r9
sub r10, rsi
cmp rsi, r9
jae 0x14038d6a4
cmp r10, 0x40
jb 0x14038d677
lea rbp, [r9 - 1]
lea rax, [r9 - 1]
add rbp, rcx
add rax, r8
lea r14, [rcx + rsi]
lea r12, [r8 + rsi]
cmp r14, rax
ja 0x14038d5ee
cmp rbp, r12
jae 0x14038d677
lea rax, [r9 - 1]
add rax, rdx
lea r12, [rdx + rsi]
cmp r14, rax
ja 0x14038d603
cmp rbp, r12
jae 0x14038d677
and r10d, 0x3f
mov rax, r9
sub rax, r10
nop dword [rax]
movdqu xmm0, xmmword [r8]
add rsi, 0x40
movdqu xmm1, xmmword [rdx]
psubb xmm1, xmm0
movdqu xmm0, xmmword [r8 + 0x10]
movdqu xmmword [rcx], xmm1
movdqu xmm1, xmmword [rdx + 0x10]
psubb xmm1, xmm0
movdqu xmm0, xmmword [r8 + 0x20]
movdqu xmmword [rcx + 0x10], xmm1
movdqu xmm1, xmmword [rdx + 0x20]
psubb xmm1, xmm0
movdqu xmm0, xmmword [r8 + 0x30]
add r8, 0x40
movdqu xmmword [rcx + 0x20], xmm1
movdqu xmm1, xmmword [rdx + 0x30]
add rdx, 0x40
psubb xmm1, xmm0
movdqu xmmword [rcx + 0x30], xmm1
add rcx, 0x40
cmp rsi, rax
jb 0x14038d610
cmp rsi, r9
jae 0x14038d6a4
sub r8, rcx
sub rdx, rcx
mov r10, r9
sub r10, rsi
nop dword [rax]
nop word [rax + rax]
movzx eax, byte [rdx + rcx]
sub al, byte [r8 + rcx]
mov byte [rcx], al
lea rcx, [rcx + 1]
sub r10, 1
jne 0x14038d690
mov rdx, r15
test r13b, r13b
jns 0x14038dc51
mov r8, qword [rbx + 0x250]
mov rbp, rdi
mov r10, qword [rbx + 0x248]
mov rax, qword [rbx + 0x240]
inc r10
mov edx, dword [rsp + 0xa0]
inc rax
mov qword [rsp + 0x30], r8
lea r14, [r8 + 1]
mov byte [r8], 4
mov r12, rax
mov qword [rsp + 0xa8], r10
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r15
test rdx, rdx
je 0x14038d747
mov ebp, edx
mov qword [rsp + 0x20], r15
nop dword [rax]
nop word [rax + rax]
movzx eax, byte [r10]
inc r10
sub al, byte [r12]
inc r12
movzx ecx, al
mov eax, 0x100
sub eax, ecx
mov byte [r14], cl
inc r14
cmp ecx, 0x80
cmovae ecx, eax
mov eax, ecx
add rdi, rax
sub rdx, 1
jne 0x14038d710
mov rax, qword [rsp + 0x28]
cmp rbp, r9
jae 0x14038d81f
mov rbx, qword [rsp + 0xa8]
sub rax, rbx
sub r12, rbx
mov qword [rsp + 0x28], rax
sub r14, r10
nop word [rax + rax]
movzx eax, byte [rax + rbx]
movzx ecx, byte [r12 + rbx]
movzx esi, byte [rbx]
lea rbx, [rbx + 1]
mov dword [rsp + 0xa0], eax
mov r8d, ecx
sub r8d, eax
mov dword [rsp + 0xa8], ecx
mov ecx, esi
sub ecx, eax
mov eax, r8d
cdq
mov r15d, eax
mov eax, ecx
xor r15d, edx
sub r15d, edx
cdq
mov r13d, eax
lea eax, [rcx + r8]
xor r13d, edx
sub r13d, edx
cdq
xor eax, edx
sub eax, edx
cmp r15d, r13d
jg 0x14038d7c4
cmp r15d, eax
jle 0x14038d7d6
mov esi, dword [rsp + 0xa0]
cmp r13d, eax
cmovle esi, dword [rsp + 0xa8]
movzx eax, byte [r10]
sub al, sil
movzx ecx, al
mov eax, 0x100
sub eax, ecx
mov byte [r14 + r10], cl
inc r10
cmp ecx, 0x80
cmovae ecx, eax
mov eax, ecx
add rdi, rax
cmp rdi, r11
ja 0x14038d812
mov rax, qword [rsp + 0x28]
inc rbp
cmp rbp, r9
jb 0x14038d770
mov rbx, qword [rsp + 0x90]
mov r8, qword [rsp + 0x30]
cmp rdi, r11
jae 0x14038dc4c
mov rax, qword [rbx + 0x258]
mov rdx, r8
test rax, rax
je 0x14038dc51
mov qword [rbx + 0x250], rax
mov qword [rbx + 0x258], r8
jmp 0x14038dc51
test r13b, 0x10
je 0x14038d923
mov r15, qword [rbx + 0x250]
inc r14
mov r8, rdi
mov rsi, rdi
mov r10, r14
mov byte [r15], 1
lea rdx, [r15 + 1]
test rbp, rbp
je 0x14038d8a9
mov rsi, rbp
nop dword [rax + rax]
movzx eax, byte [r10]
mov ecx, eax
mov byte [rdx], al
mov eax, 0x100
sub eax, ecx
cmp ecx, 0x80
cmovae ecx, eax
inc r10
mov eax, ecx
inc rdx
add r8, rax
sub rbp, 1
jne 0x14038d880
cmp rsi, r9
jae 0x14038d8e7
sub r10, rdx
sub r14, rdx
movzx eax, byte [r10 + rdx]
sub al, byte [r14 + rdx]
movzx ecx, al
mov eax, 0x100
sub eax, ecx
mov byte [rdx], cl
cmp ecx, 0x80
cmovae ecx, eax
mov eax, ecx
add r8, rax
cmp r8, r11
ja 0x14038d915
inc rdx
inc rsi
cmp rsi, r9
jb 0x14038d8b4
cmp r8, r11
jae 0x14038d915
mov rax, qword [rbx + 0x258]
mov r11, r8
mov r14, qword [rbx + 0x248]
mov rcx, r15
test rax, rax
je 0x14038d926
mov qword [rbx + 0x250], rax
mov qword [rbx + 0x258], rcx
jmp 0x14038d926
mov r14, qword [rbx + 0x248]
mov rcx, qword [rsp + 0x28]
jmp 0x14038d926
mov rcx, r14
cmp r13d, 0x20
jne 0x14038da39
mov r15, qword [rbx + 0x250]
lea r8, [r14 + 1]
mov rdx, qword [rbx + 0x240]
mov rsi, rdi
inc rdx
mov byte [r15], 2
lea rcx, [r15 + 1]
test r9, r9
je 0x14038d6a4
cmp r9, 0x40
jb 0x14038da0b
lea r10, [r9 - 1]
lea rax, [r9 - 1]
add r10, rcx
add rax, rdx
cmp rcx, rax
ja 0x14038d97f
cmp r10, rdx
jae 0x14038da0b
lea rax, [r9 - 1]
add rax, r8
cmp rcx, rax
ja 0x14038d990
cmp r10, r8
jae 0x14038da0b
mov rax, r9
and rax, 0xffffffffffffffc0
nop word [rax + rax]
movdqu xmm0, xmmword [rdx]
add rsi, 0x40
movdqu xmm1, xmmword [r8]
psubb xmm1, xmm0
movdqu xmm0, xmmword [rdx + 0x10]
movdqu xmmword [rcx], xmm1
movdqu xmm1, xmmword [r8 + 0x10]
psubb xmm1, xmm0
movdqu xmm0, xmmword [rdx + 0x20]
movdqu xmmword [rcx + 0x10], xmm1
movdqu xmm1, xmmword [r8 + 0x20]
psubb xmm1, xmm0
movdqu xmm0, xmmword [rdx + 0x30]
add rdx, 0x40
movdqu xmmword [rcx + 0x20], xmm1
movdqu xmm1, xmmword [r8 + 0x30]
add r8, 0x40
psubb xmm1, xmm0
movdqu xmmword [rcx + 0x30], xmm1
add rcx, 0x40
cmp rsi, rax
jb 0x14038d9a0
cmp rsi, r9
jae 0x14038d6a4
sub r8, rcx
sub rdx, rcx
mov r10, r9
sub r10, rsi
nop word [rax + rax]
movzx eax, byte [r8 + rcx]
sub al, byte [rdx + rcx]
mov byte [rcx], al
lea rcx, [rcx + 1]
sub r10, 1
jne 0x14038da20
jmp 0x14038d6a4
mov rbp, r11
mov r12, rcx
test r13b, 0x20
je 0x14038dae2
mov rsi, qword [rbx + 0x250]
mov r10, rdi
mov byte [rsi], 2
lea rdx, [rsi + 1]
test r9, r9
je 0x14038dabd
mov r15, qword [rbx + 0x240]
mov r8, rdx
sub r8, rsi
sub r15, rdx
dec r8
mov r13, r14
sub r13, rdx
nop dword [rax + rax]
movzx eax, byte [rdx + r13 + 1]
sub al, byte [r15 + rdx + 1]
movzx ecx, al
mov eax, 0x100
sub eax, ecx
mov byte [rdx], cl
cmp ecx, 0x80
cmovae ecx, eax
mov eax, ecx
add r10, rax
cmp r10, r11
ja 0x14038dab5
inc rdx
inc r8
cmp r8, r9
jb 0x14038da80
mov r13d, dword [rsp + 0xa8]
cmp r10, rbp
jae 0x14038dae2
mov rax, qword [rbx + 0x258]
mov rbp, r10
mov r12, rsi
test rax, rax
je 0x14038dae2
mov qword [rbx + 0x250], rax
mov qword [rbx + 0x258], rsi
cmp r13d, 0x40
jne 0x14038db06
mov edx, dword [rsp + 0xa0]
mov r8, r9
mov rcx, rbx
call fcn.14038ba20
mov rdx, qword [rbx + 0x250]
jmp 0x14038dc51
mov r11, rbp
mov r15, r12
test r13b, 0x40
je 0x14038dc24
mov rax, qword [rbx + 0x250]
lea rsi, [r14 + 1]
mov rdx, qword [rbx + 0x240]
mov r8, rdi
inc rdx
mov r10d, edi
mov byte [rax], 3
lea r14, [rax + 1]
mov eax, dword [rsp + 0xa0]
test eax, eax
je 0x14038db8c
mov r13d, eax
mov r10d, eax
nop dword [rax]
movzx eax, byte [rsi]
inc rsi
movzx ecx, byte [rdx]
inc rdx
shr cl, 1
sub al, cl
movzx ecx, al
mov eax, 0x100
sub eax, ecx
mov byte [r14], cl
inc r14
cmp ecx, 0x80
cmovae ecx, eax
mov eax, ecx
add r8, rax
sub r13, 1
jne 0x14038db50
mov r13d, dword [rsp + 0xa8]
mov eax, r10d
cmp rax, r9
jae 0x14038dbfb
mov rbx, qword [rsp + 0x20]
sub rsi, rdx
inc rbx
sub rbx, rdx
sub r14, rdx
nop word [rax + rax]
movzx eax, byte [rdx]
movzx ecx, byte [rbx + rdx]
lea rdx, [rdx + 1]
add ecx, eax
movzx eax, byte [rsi + rdx - 1]
shr ecx, 1
sub al, cl
movzx ecx, al
mov eax, 0x100
sub eax, ecx
mov byte [r14 + rdx - 1], cl
cmp ecx, 0x80
cmovae ecx, eax
mov eax, ecx
add r8, rax
cmp r8, r11
ja 0x14038dbf3
inc r10d
mov eax, r10d
cmp rax, r9
jb 0x14038dbb0
mov rbx, qword [rsp + 0x90]
cmp r8, r11
jae 0x14038dc24
mov rax, qword [rbx + 0x258]
mov r11, r8
mov r15, qword [rbx + 0x250]
test rax, rax
je 0x14038dc24
mov qword [rbx + 0x250], rax
mov qword [rbx + 0x258], r15
cmp r13d, 0x80
jne 0x14038d6a4
mov edx, dword [rsp + 0xa0]
mov r8, r9
mov rcx, rbx
call fcn.14038bc50
mov rdx, qword [rbx + 0x250]
jmp 0x14038dc51
mov rdx, qword [rsp + 0x20]
mov r8, qword [rsp + 0x98]
mov rcx, rbx
mov r8, qword [r8 + 8]
inc r8
mov r15, qword [rsp + 0x48]
mov r12, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x58]
add rsp, 0x60
pop r14
pop r13
pop rdi
pop rbp
pop rbx
jmp 0x14038c230