I need to encrypt bytecode to send over a connection to a webservice, preferably using a GUID as a key. I have done a bit of research and found several classes developed for a similar purpo开发者_StackOverflowse, but haven't been able to turn up much that is built into the Windows libraries. My question is: Is there something built in to C# that performs this task? If there is not, I would very much appreciate any suggestions as to implementation.
Edit: After reading this post When would I choose AesCryptoServiceProvider over AesManaged or RijndaelManaged? I am going with AESCryptoServiceProvider.
You should check out the System.Security.Cryptography
namespace.
It's not clear whether you're in a position to choose which algorithm etc to use, but you might consider one of the following symmetric algorithms:
- AES:
AesManaged
orAesCryptoServiceProvider
- Rijndael:
RijndaelManaged
- Triple DES:
TripleDESCryptoServiceProvider
There are also implementations of DES and RC2, but I would probably ignore them unless you're forced to use them.
精彩评论