Function at 0x436480
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push rbp
push rbx
sub rsp, 0x38
mov rbp, rsp
mov rbx, rcx
movsd qword [rbp + 0x58], xmm1
movzx eax, word [rbp + 0x5e]
shr eax, 4
mov dword [rbp + 0x2c], eax
mov rax, qword [rbx + 0x30]
mov ecx, dword [rbp + 0x2c]
and ecx, 0x800
cmp ecx, 0x800
sete cl
mov byte [rax + 2], cl
and dword [rbp + 0x2c], 0x7ff
cmp dword [rbp + 0x2c], 0
jne 0x436500
movzx rax, word [rbp + 0x5e]
test ax, 0xf
jne 0x436500
cmp word [rbp + 0x5c], 0
jne 0x436500
cmp word [rbp + 0x5a], 0
jne 0x436500
cmp word [rbp + 0x58], 0
jne 0x436500
mov rax, qword [rbx + 0x30]
mov word [rax], 0
mov rax, qword [rbx + 0x30]
mov byte [rax + 3], 0
mov rax, qword [rbx + 0x30]
mov byte [rax + 2], 0
jmp 0x43676b
cmp dword [rbp + 0x2c], 0x7ff
jne 0x436553
movzx rax, word [rbp + 0x5e]
test ax, 0xf
jne 0x436535
cmp word [rbp + 0x5c], 0
jne 0x436535
cmp word [rbp + 0x5a], 0
jne 0x436535
cmp word [rbp + 0x58], 0
jne 0x436535
mov rax, qword [rbx + 0x30]
mov word [rax], 0x7ff
jmp 0x436546
mov rax, qword [rbx + 0x30]
mov word [rax], 0x800
mov rax, qword [rbx + 0x30]
mov byte [rax + 2], 0
mov rax, qword [rbx + 0x30]
mov byte [rax + 3], 0
jmp 0x43676b
mov rax, qword [rbx + 0x30]
cmp byte [rax + 2], 0
je 0x43656f
movsd xmm0, qword [rbp + 0x58]
xorpd xmm0, xmmword [0x00436780]
movsd qword [rbp + 0x58], xmm0
cmp dword [rbp + 0x2c], 0
jne 0x436594
mov rax, qword [rbp + 0x58]
jmp 0x436582
sub dword [rbp + 0x2c], 1
add rax, rax
movabs rcx, 0x8000000000000
mov rdx, rax
test rcx, rdx
je 0x43657b
sub dword [rbp + 0x2c], 0x3ff
mov eax, dword [rbp + 0x2c]
imul eax, eax, 0x4d10
mov dword [rbp + 0x2c], eax
movsx rax, word [rbp + 0x2e]
mov dword [rbp + 0x2c], eax
add dword [rbp + 0x2c], 1
mov rax, qword [rbx + 0x30]
movzx rcx, word [rbp + 0x2c]
mov word [rax], cx
movsd xmm0, qword [rbp + 0x58]
mov edx, 0x12
sub edx, dword [rbp + 0x2c]
call fcn.0040bf00
call fcn.0040af20
cvtsi2sd xmm0, rax
movsd qword [rbp + 0x58], xmm0
movsd xmm0, qword [rbp + 0x58]
comisd xmm0, xmmword [0x0059db20]
jb 0x43660d
cvtsi2sd xmm0, dword [0x0059db28]
movsd xmm1, qword [rbp + 0x58]
divsd xmm1, xmm0
movsd qword [rbp + 0x58], xmm1
mov rax, qword [rbx + 0x30]
add word [rax], 1
mov rcx, rbx
lea rdx, [rbp + 0x22]
movsd xmm2, qword [rbp + 0x58]
call fcn.004363c0
mov eax, 8
lea rcx, [rbp + 0x2a]
movzx rdx, byte [rcx]
mov r8, qword [rbx + 0x30]
mov r9d, 0x10
mov r10d, eax
add r10d, r10d
sub r9d, r10d
movsxd r9, r9d
mov r10d, edx
and r10b, 0xf
movzx r10w, r10b
shl r10d, 8
and dl, 0xf0
movzx rdx, dl
shr edx, 4
add r10w, dx
add r10w, 0x3030
mov word [r8 + r9 + 3], r10w
sub eax, 1
sub rcx, 1
cmp eax, 0xffffffff
jne 0x436627
nop
mov rax, qword [rbx + 0x30]
mov byte [rax + 0x15], 0
mov rax, qword [rbx + 0x30]
movsx rax, word [rax]
add eax, dword [rbx + 0x50]
test eax, eax
jge 0x4366ad
mov rax, qword [rbx + 0x30]
mov word [rax], 0
mov rax, qword [rbx + 0x30]
mov byte [rax + 2], 0
mov rax, qword [rbx + 0x30]
mov byte [rax + 3], 0
jmp 0x43676b
mov rax, qword [rbx + 0x30]
movsx rax, word [rax]
add eax, dword [rbx + 0x50]
cmp eax, dword [rbx + 0x48]
jl 0x4366c0
mov eax, dword [rbx + 0x48]
cmp eax, 0x12
jge 0x4366d8
mov rcx, qword [rbx + 0x30]
movsxd rdx, eax
movzx cx, byte [rcx + rdx + 3]
cmp cx, 0x35
jae 0x436714
cmp eax, 0x12
jle 0x4366e2
mov eax, 0x12
mov rcx, qword [rbx + 0x30]
movsxd rdx, eax
mov byte [rcx + rdx + 3], 0
sub eax, 1
test eax, eax
jge 0x4366ff
mov rax, qword [rbx + 0x30]
mov byte [rax + 2], 0
jmp 0x43676b
mov rcx, qword [rbx + 0x30]
movsxd rdx, eax
movzx cx, byte [rcx + rdx + 3]
cmp cx, 0x30
jne 0x43676b
jmp 0x4366e2
mov rcx, qword [rbx + 0x30]
mov edx, eax
add edx, 1
movsxd rdx, edx
mov byte [rcx + rdx + 3], 0
mov rcx, qword [rbx + 0x30]
movsxd rdx, eax
mov byte [rcx + rdx + 3], 0
sub eax, 1
test eax, eax
jge 0x43674a
mov rax, qword [rbx + 0x30]
mov byte [rax + 3], 0x31
mov rax, qword [rbx + 0x30]
add word [rax], 1
jmp 0x43676b
movsxd rcx, eax
mov rdx, qword [rbx + 0x30]
lea rdx, [rdx + rcx + 3]
add byte [rdx], 1
mov rdx, qword [rbx + 0x30]
movzx cx, byte [rdx + rcx + 3]
cmp cx, 0x39
jbe 0x43676b
jmp 0x436725
lea rsp, [rbp + 0x38]
pop rbx
pop rbp
ret