using NFC.Crypto; using NFC.Mifare_DESFire; using NUnit.Framework; namespace NFC_Test.Crypto { [TestFixture] public class TDES_Test { [Test] [Ignore("Unknown Expected Data")] public void Encrypt_TDES() { MIFARE_DESFire desfire = new MIFARE_DESFire(null); byte[] data = desfire.ConvertFromHexString(""); byte[] key = desfire.ConvertFromHexString(""); byte[] iv = desfire.ConvertFromHexString("0000000000000000"); TDES des = new TDES(); byte[] data_enc = des.Encrypt(data, key, iv); byte[] data_enc_expected = desfire.ConvertFromHexString(""); Assert.AreEqual(data_enc_expected, data_enc); } [Test] [Ignore("Unknown Expected Data")] public void Encrypt_TDES_2K() { MIFARE_DESFire desfire = new MIFARE_DESFire(null); byte[] data = desfire.ConvertFromHexString(""); byte[] key = desfire.ConvertFromHexString(""); byte[] iv = desfire.ConvertFromHexString("0000000000000000"); TDES_2K des = new TDES_2K(); byte[] data_enc = des.Encrypt(data, key, iv); byte[] data_enc_expected = desfire.ConvertFromHexString(""); Assert.AreEqual(data_enc_expected, data_enc); } [Test] [Ignore("Unknown Expected Data")] public void Encrypt_TDES_3K() { MIFARE_DESFire desfire = new MIFARE_DESFire(null); byte[] data = desfire.ConvertFromHexString(""); byte[] key = desfire.ConvertFromHexString(""); byte[] iv = desfire.ConvertFromHexString("0000000000000000"); TDES_3K des = new TDES_3K(); byte[] data_enc = des.Encrypt(data, key, iv); byte[] data_enc_expected = desfire.ConvertFromHexString(""); Assert.AreEqual(data_enc_expected, data_enc); } } }