public static byte[] decrypt(byte[] input, byte[] K1) { byte[] key_des = Feistel.form_des_key(K1); byte[][] K = Feistel.generateSubKeys(key_des); byte[] dec = Feistel.encrypt64Bloc(input, K, true); return(dec); }
public static byte[] encrypt(byte[] input, byte[] K1) { //HttpContext.Current.Trace.Warn("Feistel.encrypt K1 = " + System.Text.Encoding.UTF8.GetString(K1)); byte[] key_des = Feistel.form_des_key(K1); byte[][] K = Feistel.generateSubKeys(key_des); byte[] enc = Feistel.encrypt64Bloc(input, K, false); return(enc); }