Function at 0x836709
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [ebp + 8]
mov cx, word [eax + 0x22]
mov word [ebp - 4], cx
mov edx, dword [ebp + 8]
mov ax, word [edx + 0x20]
mov word [ebp - 0x14], ax
mov ecx, dword [ebp + 8]
add ecx, 0x46
mov dword [ebp - 0x10], ecx
mov edx, dword [ebp + 8]
mov al, byte [edx + 0x24]
mov byte [ebp - 8], al
mov word [ebp - 0xc], 7
jmp 0x83674b
mov cx, word [ebp - 0xc]
sub cx, 1
mov word [ebp - 0xc], cx
mov edx, dword [ebp - 0xc]
and edx, 0xffff
test edx, edx
jle 0x836780
mov eax, dword [ebp - 0x10]
mov cl, byte [ebp - 8]
mov byte [eax], cl
mov edx, dword [ebp - 8]
and edx, 0xff
xor edx, 0xa7
sub edx, 0x35
mov byte [ebp - 8], dl
mov eax, dword [ebp - 0x10]
add eax, 1
mov dword [ebp - 0x10], eax
jmp 0x83673f
mov ecx, dword [ebp - 8]
and ecx, 0xff
add ecx, 0xa7
mov edx, dword [ebp - 0x10]
mov byte [edx], cl
call fcn.00836dc9
mov eax, dword [ebp + 0xc]
push eax
mov cx, word [ebp - 0x14]
push ecx
push 7
call fcn.00836da9
add esp, 0xc
push 0x32
call fcn.00836e45
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp + 8]
push eax
lea ecx, [ebp - 0x10]
push ecx
push 0x10
call fcn.00836c19
add esp, 0x10
push 0x32
call fcn.00836e45
mov edx, dword [ebp + 8]
mov ax, word [edx + 0x3e]
or al, 0xf
mov ecx, dword [ebp + 8]
mov word [ecx + 0x3e], ax
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp + 8]
push eax
lea ecx, [ebp - 0x10]
push ecx
push 8
call fcn.00836c19
add esp, 0x10
and eax, 0xffff
cmp eax, 0x96
jne 0x836814
mov edx, dword [ebp + 8]
mov ax, word [edx + 0x3e]
xor ax, 5
mov ecx, dword [ebp + 8]
mov word [ecx + 0x3e], ax
push 0x32
call fcn.00836e45
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp + 8]
push eax
lea ecx, [ebp - 0x10]
push ecx
push 8
call fcn.00836c19
add esp, 0x10
and eax, 0xffff
and eax, 3
mov edx, dword [ebp + 8]
mov word [edx + 0x28], ax
mov eax, dword [ebp + 8]
xor ecx, ecx
mov cx, word [eax + 0x3e]
and ecx, 0xf
cmp ecx, 0xa
je 0x83685f
mov edx, dword [ebp + 8]
mov word [edx + 0x2a], 0x80
jmp 0x836b4a
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp + 8]
push ecx
push 0x28
call fcn.00836b79
add esp, 0xc
and eax, 0xffff
test eax, eax
jne 0x836888
mov edx, dword [ebp + 8]
mov word [edx + 0x2a], 0x81
jmp 0x836b4a
mov eax, dword [ebp + 8]
mov cx, word [eax + 0x34]
or cl, 0xf
mov edx, dword [ebp + 8]
mov word [edx + 0x34], cx
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp + 8]
push ecx
lea edx, [ebp - 0x10]
push edx
push 8
call fcn.00836c19
add esp, 0x10
and eax, 0xffff
cmp eax, 0x96
jne 0x8368cd
mov eax, dword [ebp + 8]
mov cx, word [eax + 0x34]
xor cx, 5
mov edx, dword [ebp + 8]
mov word [edx + 0x34], cx
push 0x32
call fcn.00836e45
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp + 8]
push ecx
lea edx, [ebp - 0x10]
push edx
push 8
call fcn.00836c19
add esp, 0x10
mov word [ebp - 0xc], ax
mov eax, dword [ebp + 8]
xor ecx, ecx
mov cx, word [eax + 0x26]
and ecx, 1
test ecx, ecx
je 0x836909
mov edx, dword [ebp + 8]
mov al, byte [ebp - 0xc]
mov byte [edx + 0x35], al
jmp 0x83692a
mov ecx, dword [ebp - 0xc]
and ecx, 0xffff
cmp ecx, 0x96
je 0x83692a
mov edx, dword [ebp + 8]
mov ax, word [edx + 0x34]
or al, 0xf
mov ecx, dword [ebp + 8]
mov word [ecx + 0x34], ax
push 0x32
call fcn.00836e45
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp + 8]
push eax
lea ecx, [ebp - 0x10]
push ecx
push 4
call fcn.00836c19
add esp, 0x10
and eax, 0xffff
and eax, 0xe
shl eax, 1
mov edx, dword [ebp + 8]
mov cx, word [edx + 0x28]
or cx, ax
mov edx, dword [ebp + 8]
mov word [edx + 0x28], cx
mov eax, dword [ebp + 8]
xor ecx, ecx
mov cx, word [eax + 0x34]
and ecx, 0xf
cmp ecx, 0xa
je 0x836981
mov edx, dword [ebp + 8]
mov word [edx + 0x2a], 0x82
jmp 0x836b4a
mov eax, dword [ebp + 8]
xor ecx, ecx
mov cx, word [eax + 0x26]
and ecx, 2
test ecx, ecx
jne 0x8369b1
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp + 8]
push eax
push 0x28
call fcn.00836b79
add esp, 0xc
mov ecx, dword [ebp + 8]
mov word [ecx + 0x2a], 0
jmp 0x836b4a
mov edx, dword [ebp + 8]
xor eax, eax
mov ax, word [edx + 0x26]
and eax, 1
test eax, eax
je 0x8369c9
mov word [ebp - 0xc], 0x190
jmp 0x8369cf
mov word [ebp - 0xc], 0x640
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
mov ax, word [ebp - 0xc]
push eax
call fcn.00836b79
add esp, 0xc
and eax, 0xffff
test eax, eax
jne 0x8369fb
mov ecx, dword [ebp + 8]
mov word [ecx + 0x2a], 0x83
jmp 0x836b4a
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp + 8]
push eax
lea ecx, [ebp - 0x10]
push ecx
push 8
call fcn.00836c19
add esp, 0x10
and eax, 0xffff
xor eax, 0x40
mov edx, dword [ebp + 8]
mov word [edx + 0x2a], ax
mov eax, dword [ebp + 8]
xor ecx, ecx
mov cx, word [eax + 0x2a]
and ecx, 0xc0
test ecx, ecx
je 0x836a41
mov edx, dword [ebp + 8]
mov word [edx + 0x2a], 0x84
jmp 0x836b4a
mov eax, dword [ebp + 8]
xor ecx, ecx
mov cx, word [eax + 0x2a]
and ecx, 4
test ecx, ecx
je 0x836ab5
mov edx, dword [ebp - 0x10]
add edx, 0x16
mov dword [ebp - 0x10], edx
mov word [ebp - 0xc], 0
jmp 0x836a6e
mov ax, word [ebp - 0xc]
add ax, 1
mov word [ebp - 0xc], ax
mov ecx, dword [ebp - 0xc]
and ecx, 0xffff
mov edx, dword [ebp + 8]
xor eax, eax
mov ax, word [edx + 0x2a]
and eax, 3
cmp ecx, eax
jg 0x836ab5
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
lea eax, [ebp - 0x10]
push eax
push 0x10
call fcn.00836c19
add esp, 0x10
mov ecx, dword [ebp + 8]
add ecx, 0x32
mov edx, dword [ebp - 0xc]
and edx, 0xffff
shl edx, 1
sub ecx, edx
mov word [ecx], ax
jmp 0x836a62
mov eax, dword [ebp + 8]
xor ecx, ecx
mov cx, word [eax + 0x26]
and ecx, 1
test ecx, ecx
je 0x836b4a
mov edx, dword [ebp + 8]
xor eax, eax
mov ax, word [edx + 0x2a]
and eax, 8
test eax, eax
je 0x836b4a
mov ecx, dword [ebp + 0xc]
push ecx
mov dx, word [ebp - 0x14]
push edx
push 0xff
call fcn.00836da9
add esp, 0xc
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp + 8]
push ecx
push 0x190
call fcn.00836b79
add esp, 0xc
and eax, 0xffff
test eax, eax
jne 0x836b18
mov edx, dword [ebp + 8]
mov word [edx + 0x2a], 0x85
jmp 0x836b4a
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp + 8]
push ecx
lea edx, [ebp - 0x10]
push edx
push 1
call fcn.00836c19
add esp, 0x10
and eax, 0xffff
and eax, 1
shl eax, 6
mov ecx, dword [ebp + 8]
mov dx, word [ecx + 0x2a]
or dx, ax
mov eax, dword [ebp + 8]
mov word [eax + 0x2a], dx
mov ecx, dword [ebp + 0xc]
push ecx
mov dx, word [ebp - 0x14]
push edx
push 0xb
call fcn.00836da9
add esp, 0xc
push 0x32
call fcn.00836e45
call fcn.00836dd9
mov esp, ebp
pop ebp
ret