From 220702c05e5c67817e5ba45765fd75ead8e92bb3 Mon Sep 17 00:00:00 2001 From: Stefan Suhren Date: Wed, 27 May 2015 13:02:31 +0200 Subject: Use an EVP base class to reduce repetition --- src/crypt/cryptclassnullcipher.h | 30 +++--------------------------- 1 file changed, 3 insertions(+), 27 deletions(-) (limited to 'src/crypt/cryptclassnullcipher.h') diff --git a/src/crypt/cryptclassnullcipher.h b/src/crypt/cryptclassnullcipher.h index ae05ef6..b25c8e9 100644 --- a/src/crypt/cryptclassnullcipher.h +++ b/src/crypt/cryptclassnullcipher.h @@ -1,13 +1,7 @@ #ifndef CRYPTCLASSNULLCIPHER_H #define CRYPTCLASSNULLCIPHER_H -#include "cryptclassbase.h" - -#include - -#include -#include -#include +#include "cryptclassevp.h" /** @@ -21,7 +15,7 @@ * \version 0.1 * \date 28.02.2013 */ -class CryptClassNullCipher : public CryptClassBase +class CryptClassNullCipher : public CryptClassEvp { public: //Methods /** @@ -38,25 +32,7 @@ public: //Methods */ ~CryptClassNullCipher(); - /** - * \brief Overloaded Method to encrypt present unencrypted data using the current key. - * - * NullCipher is used for testing purposes and simulation. No actual encryption is done. - * Data is copied from m_clearText to m_cryptText. - */ - virtual void encrypt(); - - - /** - * \brief Overloaded Method to decrypt present encrypted data using the current key. - * - * NullCipher is used for testing purposes and simulation. No actual decryption is done. - * Data is copied from m_cryptText to m_clearText. - */ - virtual void decrypt(); - -private: - void handleErrors(); + virtual const EVP_CIPHER *algorithm(); }; #endif // CRYPTCLASSNULLCIPHER_H -- cgit v1.2.3-70-g09d2