mirror of
https://github.com/veracrypt/VeraCrypt.git
synced 2025-11-11 11:08:02 -06:00
Optimize code space and solve the Serpent issue (https://sourceforge.net/p/veracrypt/discussion/technical/thread/fb09633a/#6406) by removing key length parameter from serpent_set_key and twofish_set_key
This commit is contained in:
@@ -211,7 +211,7 @@ namespace VeraCrypt
|
||||
|
||||
void CipherSerpent::SetCipherKey (const byte *key)
|
||||
{
|
||||
serpent_set_key (key, static_cast<int> (GetKeySize ()), ScheduledKey);
|
||||
serpent_set_key (key, ScheduledKey);
|
||||
}
|
||||
|
||||
|
||||
@@ -233,7 +233,7 @@ namespace VeraCrypt
|
||||
|
||||
void CipherTwofish::SetCipherKey (const byte *key)
|
||||
{
|
||||
twofish_set_key ((TwofishInstance *) ScheduledKey.Ptr(), (unsigned int *) key, static_cast<int> (GetKeySize ()) * 8);
|
||||
twofish_set_key ((TwofishInstance *) ScheduledKey.Ptr(), (unsigned int *) key);
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user