From d1dec816796849205bd4618edd203d979f2a9c3e Mon Sep 17 00:00:00 2001 From: George Hazan Date: Wed, 13 Nov 2013 19:49:18 +0000 Subject: stdcrypt is ready to really encrypt smth git-svn-id: http://svn.miranda-ng.org/main/trunk@6894 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- src/core/stdcrypt/stdcrypt.h | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'src/core/stdcrypt/stdcrypt.h') diff --git a/src/core/stdcrypt/stdcrypt.h b/src/core/stdcrypt/stdcrypt.h index 4d5b0710ca..f685152461 100644 --- a/src/core/stdcrypt/stdcrypt.h +++ b/src/core/stdcrypt/stdcrypt.h @@ -18,15 +18,22 @@ with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ -#define KEYLENGTH (256/8) +#include "Rijndael.h" + +// we use 256-bit keys & 128-bit blocks +#define KEY_LENGTH 32 +#define BLOCK_SIZE 16 struct CStdCrypt : public MICryptoEngine, public MZeroedObject { CStdCrypt(); - BYTE m_key[KEYLENGTH]; + BOOL m_valid; CMStringA m_password; + char m_key[KEY_LENGTH]; + CRijndael m_aes; + STDMETHODIMP_(void) destroy(); // get/set the instance key -- cgit v1.2.3