Example #1
0
File: Des.cs Project: niuniuzhu/RC
        public static byte[] TripleDesDecrypt(byte[] data, byte[] key, byte[] iv)
        {
            TripleDes des = new TripleDes(key, iv);

            return(des.Decrypt(data));
        }
Example #2
0
File: Des.cs Project: niuniuzhu/RC
        public static byte[] TripleDesEncrypt(byte[] data, byte[] key)
        {
            TripleDes des = new TripleDes(key);

            return(des.Encrypt(data));
        }
Example #3
0
File: Des.cs Project: niuniuzhu/RC
        public static void TripleDesDecrypt(Stream i, Stream o, byte[] key, byte[] iv)
        {
            TripleDes des = new TripleDes(key, iv);

            des.Decrypt(i, o);
        }
Example #4
0
File: Des.cs Project: niuniuzhu/RC
        public static void TripleDesEncrypt(Stream i, Stream o, byte[] key)
        {
            TripleDes des = new TripleDes(key);

            des.Encrypt(i, o);
        }