Function at 0x4600e0
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x4c
mov eax, dword [esp + 0x60]
mov ebx, dword [esp + 0x64]
mov edx, dword [eax + 0x18c]
mov dword [esp + 0x2c], eax
test edx, edx
je 0x4604d8
mov esi, dword [esp + 0x2c]
mov dword [esp + 4], str.gamma_table_being_rebuilt
mov dword [esp], esi
call fcn.004609b0
mov dword [esp], esi
call fcn.0045ff70
cmp ebx, 8
mov ecx, dword [esp + 0x2c]
jg 0x46016c
mov edx, dword [ecx + 0x188]
mov eax, 0x186a0
test edx, edx
jle 0x460144
mov eax, dword [ecx + 0x2c4]
test eax, eax
je 0x460144
call fcn.0045cca0
mov esi, dword [esp + 0x2c]
mov ecx, eax
lea edx, [esi + 0x18c]
mov eax, esi
call fcn.0045cd90
test dword [esi + 0x7c], 0x600080
jne 0x4603d9
add esp, 0x4c
pop ebx
pop esi
pop edi
pop ebp
ret
test byte [ecx + 0x14f], 2
jne 0x46037e
mov eax, dword [esp + 0x2c]
movzx edx, byte [eax + 0x1a7]
lea eax, [edx - 1]
cmp al, 0xe
ja 0x4603a8
mov ecx, dword [esp + 0x2c]
mov eax, 0x10
sub eax, edx
mov ecx, dword [ecx + 0x7c]
mov edx, ecx
mov dword [esp + 0x18], ecx
and edx, 0x4000400
cmp al, 4
jbe 0x4604eb
cmp al, 8
jbe 0x460538
mov dword [esp + 0x30], 8
mov eax, 8
mov ecx, dword [esp + 0x2c]
test edx, edx
mov dword [ecx + 0x184], eax
je 0x460438
mov ecx, dword [esp + 0x2c]
mov dword [esp + 0x20], 0x186a0
mov eax, dword [ecx + 0x188]
test eax, eax
jle 0x46024e
fild dword [ecx + 0x2c4]
mov dword [esp + 0x18], eax
fmul qword [0x65bbe8]
fild dword [esp + 0x18]
fmulp st(1)
fadd dword [0x65bbf4]
fstp qword [esp]
call fcn.004d4b10
fld qword [0x65bbf8]
fucompi st(1)
jb 0x46050a
fld dword [0x65bc00]
fxch st(1)
fucomi st(1)
fstp st(1)
jb 0x46050e
fnstcw word [esp + 0x3e]
movzx eax, word [esp + 0x3e]
mov ah, 0xc
mov word [esp + 0x3c], ax
fldcw word [esp + 0x3c]
fistp dword [esp + 0x20]
fldcw word [esp + 0x3e]
mov edi, dword [esp + 0x30]
mov eax, 8
sub eax, edi
mov ecx, eax
mov dword [esp + 0x28], eax
mov eax, 1
mov esi, eax
shl esi, cl
mov ecx, 0x10
lea ebx, [esi*4]
mov dword [esp + 0x34], esi
mov esi, dword [esp + 0x2c]
sub ecx, edi
shl eax, cl
mov dword [esp + 4], ebx
sub eax, 1
mov dword [esp], esi
mov dword [esp + 0x24], eax
call fcn.004628b0
mov edi, eax
mov eax, esi
mov dword [esi + 0x190], edi
add ebx, edi
mov esi, edi
mov ebp, eax
mov dword [esp + 4], 0x200
mov dword [esp], ebp
add esi, 4
call fcn.00462870
mov dword [esi - 4], eax
cmp ebx, esi
jne 0x4602a3
movzx ecx, byte [esp + 0x30]
mov ebp, 0xff
mov dword [esp + 0x1c], 0
xor ebx, ebx
shr ebp, cl
mov dword [esp + 0x18], ebp
mov esi, esi
lea edi, [edi]
mov eax, dword [esp + 0x1c]
mov edx, dword [esp + 0x20]
mov esi, eax
sub eax, 0xffffff80
call fcn.0045ce10
movzx edx, ax
mov eax, 0x80008001
imul edx, dword [esp + 0x24]
add edx, 0x8000
mul edx
shr edx, 0xf
add edx, 1
cmp ebx, edx
jae 0x46032e
mov ecx, dword [esp + 0x28]
mov ebp, dword [esp + 0x18]
mov eax, ebx
shr eax, cl
and ebp, ebx
add ebx, 1
mov ebp, dword [edi + ebp*4]
cmp edx, ebx
mov word [ebp + eax*2], si
jne 0x460315
add dword [esp + 0x1c], 0x101
mov eax, dword [esp + 0x1c]
cmp eax, 0xffff
jne 0x4602e0
mov esi, dword [esp + 0x34]
movzx ecx, byte [esp + 0x30]
mov edx, 0xff
shl esi, 8
sar edx, cl
cmp ebx, esi
jae 0x460471
mov ecx, dword [esp + 0x28]
mov ebp, ebx
mov eax, ebx
add ebx, 1
and ebp, edx
shr eax, cl
cmp ebx, esi
mov ebp, dword [edi + ebp*4]
mov word [ebp + eax*2], 0xffff
jne 0x460360
jmp 0x460471
movzx eax, byte [ecx + 0x1a4]
movzx edx, byte [ecx + 0x1a5]
cmp al, dl
cmovae edx, eax
movzx eax, byte [ecx + 0x1a6]
cmp al, dl
cmovae edx, eax
lea eax, [edx - 1]
cmp al, 0xe
jbe 0x46018f
mov eax, dword [esp + 0x2c]
mov eax, dword [eax + 0x7c]
mov dword [esp + 0x18], eax
and eax, 0x4000400
mov dword [esp + 0x30], eax
je 0x46042a
mov eax, dword [esp + 0x2c]
mov dword [esp + 0x30], 5
mov dword [eax + 0x184], 5
jmp 0x4601d8
mov esi, dword [esp + 0x2c]
mov eax, dword [esi + 0x2c4]
mov dword [esp], eax
call fcn.0045f460
lea edx, [esi + 0x198]
mov ecx, eax
mov eax, esi
call fcn.0045cd90
mov eax, dword [esi + 0x188]
test eax, eax
jle 0x460529
mov dword [esp], eax
call fcn.0045f460
mov esi, dword [esp + 0x2c]
add esp, 0x4c
mov ecx, eax
pop ebx
lea edx, [esi + 0x194]
mov eax, esi
pop esi
pop edi
pop ebp
jmp fcn.0045cd90
mov eax, dword [esp + 0x2c]
mov dword [eax + 0x184], 0
mov ecx, dword [esp + 0x2c]
mov eax, 0x186a0
mov edx, dword [ecx + 0x188]
test edx, edx
jle 0x460459
mov eax, dword [ecx + 0x2c4]
test eax, eax
jne 0x460500
mov esi, dword [esp + 0x2c]
mov ecx, dword [esp + 0x30]
mov dword [esp], eax
lea edx, [esi + 0x190]
mov eax, esi
call fcn.0045bce0
mov eax, dword [esp + 0x2c]
test dword [eax + 0x7c], 0x600080
je 0x460164
mov esi, eax
mov eax, dword [eax + 0x2c4]
mov dword [esp], eax
call fcn.0045f460
mov ecx, dword [esp + 0x30]
lea edx, [esi + 0x1a0]
mov dword [esp], eax
mov eax, esi
call fcn.0045bce0
mov eax, dword [esi + 0x188]
test eax, eax
jle 0x46051d
mov dword [esp], eax
call fcn.0045f460
mov esi, dword [esp + 0x2c]
mov dword [esp + 0x60], eax
mov ecx, dword [esp + 0x30]
add esp, 0x4c
pop ebx
lea edx, [esi + 0x19c]
mov eax, esi
pop esi
pop edi
pop ebp
jmp fcn.0045bce0
mov eax, dword [eax + 0x190]
test eax, eax
jne 0x460101
jmp 0x46011d
test edx, edx
je 0x4601b1
jmp 0x4603be
call fcn.0045cca0
jmp 0x460459
fstp st(0)
jmp 0x460510
fstp st(0)
mov dword [esp + 0x20], 0
jmp 0x46024e
mov eax, dword [esp + 0x2c]
mov eax, dword [eax + 0x2c4]
jmp 0x4604b8
mov eax, dword [esp + 0x2c]
mov eax, dword [eax + 0x2c4]
jmp 0x460410
movzx eax, al
mov dword [esp + 0x30], eax
jmp 0x4601c6