diff options
author | weidai <weidai@57ff6487-cd31-0410-9ec3-f628ee90f5f0> | 2003-07-31 01:52:57 +0000 |
---|---|---|
committer | weidai <weidai@57ff6487-cd31-0410-9ec3-f628ee90f5f0> | 2003-07-31 01:52:57 +0000 |
commit | ab81a0ed8b889d6e50225792f4b3b62f0217d182 (patch) | |
tree | f3c0672a5c6522766b04ebf11ae86a0fbd9e6463 /tea.h | |
parent | 4c8fdf71733c7ea14d5ee47306cc45e781d27b30 (diff) | |
download | cryptopp-ab81a0ed8b889d6e50225792f4b3b62f0217d182.tar.gz |
fix BTEA
git-svn-id: svn://svn.code.sf.net/p/cryptopp/code/trunk/c5@120 57ff6487-cd31-0410-9ec3-f628ee90f5f0
Diffstat (limited to 'tea.h')
-rw-r--r-- | tea.h | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -87,7 +87,8 @@ struct BTEA_Info : public FixedKeyLength<16> static const char *StaticAlgorithmName() {return "BTEA";} }; -/// <a href="http://www.weidai.com/scan-mirror/cs.html#TEA">corrected Block TEA</a> (as described in "xxtea"). +//! <a href="http://www.weidai.com/scan-mirror/cs.html#TEA">corrected Block TEA</a> (as described in "xxtea"). +/*! This class hasn't been tested yet. */ class BTEA : public BTEA_Info, public BlockCipherDocumentation { class CRYPTOPP_NO_VTABLE Base : public AlgorithmImpl<SimpleKeyingInterfaceImpl<BlockCipher, BTEA_Info>, BTEA_Info>, public BTEA_Info @@ -97,8 +98,8 @@ class BTEA : public BTEA_Info, public BlockCipherDocumentation static inline void CheckedSetKey(T *obj, CipherDir dir, const byte *key, unsigned int length, const NameValuePairs ¶m) { obj->ThrowIfInvalidKeyLength(length); - m_blockSize = param.GetIntValueWithDefault("BlockSize", 60*4); - GetUserKey(BIG_ENDIAN_ORDER, m_k.begin(), 4, userKey, KEYLENGTH); + obj->m_blockSize = param.GetIntValueWithDefault("BlockSize", 60*4); + GetUserKey(BIG_ENDIAN_ORDER, obj->m_k.begin(), 4, userKey, KEYLENGTH); } unsigned int BlockSize() const {return m_blockSize;} |