예제 #1
0
    static Boolean Test()
    {
        Boolean bResult;

        Console.WriteLine("Testing AesManaged encrypt/decrypt...");
        AesManaged     aes = new AesManaged();
        EncDec      ed = new EncDec();
        EncDecMul   edm = new EncDecMul();

        bResult = ed.TestAlgorithm(aes);
        bResult = edm.TestAlgorithm(aes) && bResult;

        if (AesCSPSupported())
		{
			Console.WriteLine("Testing AesCryptoServiceProvider encrypt/decrypt...");
			AesCryptoServiceProvider     aescsp = new AesCryptoServiceProvider();
			ed = new EncDec();
			edm = new EncDecMul();

			bResult = ed.TestAlgorithm(aescsp);
			bResult = edm.TestAlgorithm(aescsp) && bResult;
		}

        return bResult;
    }
예제 #2
0
    static Boolean Test()
    {
        Boolean bResult;

        Console.WriteLine("Testing AesManaged encrypt/decrypt...");
        AesManaged aes = new AesManaged();
        EncDec     ed  = new EncDec();
        EncDecMul  edm = new EncDecMul();

        bResult = ed.TestAlgorithm(aes);
        bResult = edm.TestAlgorithm(aes) && bResult;

        if (AesCSPSupported())
        {
            Console.WriteLine("Testing AesCryptoServiceProvider encrypt/decrypt...");
            AesCryptoServiceProvider aescsp = new AesCryptoServiceProvider();
            ed  = new EncDec();
            edm = new EncDecMul();

            bResult = ed.TestAlgorithm(aescsp);
            bResult = edm.TestAlgorithm(aescsp) && bResult;
        }

        return(bResult);
    }
예제 #3
0
    static Boolean Test()
    {
        Boolean bResult;

        Console.WriteLine("Testing RijndaelManaged encrypt/decrypt...");
        RijndaelManaged     rijnd = new RijndaelManaged();
        EncDec      ed = new EncDec();
        EncDecMul   edm = new EncDecMul();

        bResult = ed.TestAlgorithm(rijnd);
        bResult = edm.TestAlgorithm(rijnd) && bResult;

        return bResult;
    }
    static Boolean Test()
    {
        Boolean bResult;

        Console.WriteLine("Testing RijndaelManaged encrypt/decrypt...");
        RijndaelManaged rijnd = new RijndaelManaged();
        EncDec          ed    = new EncDec();
        EncDecMul       edm   = new EncDecMul();

        bResult = ed.TestAlgorithm(rijnd);
        bResult = edm.TestAlgorithm(rijnd) && bResult;

        return(bResult);
    }
예제 #5
0
    static Boolean Test()
    {
        Boolean bResult;

        Console.WriteLine("Testing AesManaged encrypt/decrypt...");
        AesManaged     aes = new AesManaged();
        EncDec      ed = new EncDec();
        EncDecMul   edm = new EncDecMul();

        bResult = ed.TestAlgorithm(aes);
        bResult = edm.TestAlgorithm(aes) && bResult;

        return bResult;
    }
예제 #6
0
    static Boolean Test()
    {
        Boolean bResult;

        Console.WriteLine("Testing AesManaged encrypt/decrypt...");
        AesManaged aes = new AesManaged();
        EncDec     ed  = new EncDec();
        EncDecMul  edm = new EncDecMul();

        bResult = ed.TestAlgorithm(aes);
        bResult = edm.TestAlgorithm(aes) && bResult;

        return(bResult);
    }