os/security/crypto/weakcryptospi/test/tpadding/tpaddingPKCS7.h
changeset 0 bde4ae8d615e
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/os/security/crypto/weakcryptospi/test/tpadding/tpaddingPKCS7.h	Fri Jun 15 03:10:57 2012 +0200
     1.3 @@ -0,0 +1,76 @@
     1.4 +/*
     1.5 +* Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
     1.6 +* All rights reserved.
     1.7 +* This component and the accompanying materials are made available
     1.8 +* under the terms of the License "Eclipse Public License v1.0"
     1.9 +* which accompanies this distribution, and is available
    1.10 +* at the URL "http://www.eclipse.org/legal/epl-v10.html".
    1.11 +*
    1.12 +* Initial Contributors:
    1.13 +* Nokia Corporation - initial contribution.
    1.14 +*
    1.15 +* Contributors:
    1.16 +*
    1.17 +* Description: 
    1.18 +*
    1.19 +*/
    1.20 +
    1.21 +
    1.22 +#ifndef _TPADDINGPKCS7_H_
    1.23 +#define _TPADDINGPKCS7_H_
    1.24 +
    1.25 +#include <e32std.h>
    1.26 +#include <e32cmn.h>
    1.27 +
    1.28 +
    1.29 +#include <test/testexecutestepbase.h>
    1.30 +#include "tpaddingTestSteps.h"
    1.31 +
    1.32 +_LIT(KPadPKCS7, "PadPKCS7");
    1.33 +_LIT(KUnpadPKCS7, "UnpadPKCS7");
    1.34 +_LIT(KUnpadCorruptPKCS7, "UnpadCorruptPKCS7");
    1.35 +_LIT(KPaddingCorruptPKCS7, "PaddingCorruptPKCS7");
    1.36 +
    1.37 +
    1.38 +class CTestPadPKCS7 : public CPaddingStep
    1.39 +{
    1.40 + 	public:
    1.41 + 		CTestPadPKCS7();
    1.42 + 		~CTestPadPKCS7();
    1.43 + 		virtual TVerdict doTestStepL();
    1.44 + 	private:
    1.45 + 		void TestPKCS7Padding(TInt aBlockSize);
    1.46 +};
    1.47 +
    1.48 +class CTestUnpadPKCS7 : public CPaddingStep
    1.49 +{
    1.50 +    public:
    1.51 + 		CTestUnpadPKCS7();
    1.52 + 		~CTestUnpadPKCS7();
    1.53 + 		virtual TVerdict doTestStepL();
    1.54 + 	private:
    1.55 + 		void TestPKCS7Unpadding(TInt aBlockSize);
    1.56 +
    1.57 +};
    1.58 +
    1.59 +class CTestUnpadCorruptPKCS7 : public CPaddingStep
    1.60 + {
    1.61 +    public:
    1.62 + 		CTestUnpadCorruptPKCS7();
    1.63 + 		~CTestUnpadCorruptPKCS7();
    1.64 + 		virtual TVerdict doTestStepL();
    1.65 + 	private:
    1.66 + 		void TestCorruptPKCS7Unpadding(TInt aBlockSize, TInt aTextSize, TUint8 aCorruptPaddingByte);
    1.67 + };
    1.68 +
    1.69 +class CTestPaddingCorruptPKCS7 : public CPaddingStep
    1.70 +	{
    1.71 +public:
    1.72 +	CTestPaddingCorruptPKCS7();
    1.73 +    ~CTestPaddingCorruptPKCS7();
    1.74 +    virtual TVerdict doTestStepL();
    1.75 +private:
    1.76 +    void TestCorruptPKCS7padding(TInt aBlockSize, TInt aTextSize);
    1.77 +};
    1.78 +
    1.79 +#endif