From 019edc6694800a838f5cef13091b5e64c7a44d8e Mon Sep 17 00:00:00 2001 From: Jim Wigginton Date: Fri, 25 Nov 2011 00:11:19 +0000 Subject: [PATCH] - the key has to be truncated before setKey() is called or else it'll be rounded up to the nearest key size - not down git-svn-id: http://phpseclib.svn.sourceforge.net/svnroot/phpseclib/trunk@190 21d32557-59b3-4da0-833f-c5933fad653e --- phpseclib/Crypt/Rijndael.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/phpseclib/Crypt/Rijndael.php b/phpseclib/Crypt/Rijndael.php index a123c675..6d4b21ac 100644 --- a/phpseclib/Crypt/Rijndael.php +++ b/phpseclib/Crypt/Rijndael.php @@ -628,7 +628,7 @@ class Crypt_Rijndael { } } - $this->setKey($key); + $this->setKey(substr($key, 0, $this->key_size)); } /**