My question is, how do I encrypt and decrypt a file in C# using the RC4 encryption algorithm?
This is not a duplicate of these questions:
I do however acknowledge that at first glance, this question will appear like a duplicate of this question, however, it is around 7 months old, and still has no answer with working code that solves the question directly.
I have however referred to the below links, but none of them answers the question fully, or in fact, at all.
http://www.codeproject.com/Articles/5719/Simple-encrypting-and-decrypting-data-in-C
http://www.codeproject.com/Articles/5068/RC-Encryption-Algorithm-C-Version
I do know that the built-in System.Security.Cryptography library in Visual Studio 2013 supports RC2, but what I want to focus on right now is RC4, as part of a research. I know it is weak yes, but I'm still using it. No important data is going to be using this encryption.
Preferably with a code example, that accepts a stream as an input. I have caused great confusion, as I did not describe my concerns properly. I am opting for a stream input, due to the concern that any kind of other input may cause a decrease in the speed of processing large files.
Specifications: NET Framework 4.5, C#, WinForms.