diff options
author | raj <raj@FreeBSD.org> | 2008-08-21 16:49:57 +0000 |
---|---|---|
committer | raj <raj@FreeBSD.org> | 2008-08-21 16:49:57 +0000 |
commit | 55245871652c34dba2ba70f34edafc983ecdd479 (patch) | |
tree | 1e972851fedf57be19f8e968faa602772cf2349c | |
parent | 85c7cc2d414bcd44dcc284e051368ce50c247fd6 (diff) | |
download | FreeBSD-src-55245871652c34dba2ba70f34edafc983ecdd479.zip FreeBSD-src-55245871652c34dba2ba70f34edafc983ecdd479.tar.gz |
Increase cryptotest tool initialization vector (IV) size.
This fixes potential out-of-bound accesses when testing ciphers with block size
greater than 8 bytes (e.g. AES).
Submitted by: Bartlomiej Sieka tur ! semihalf dot com
Discussed with: pjd, sam
-rw-r--r-- | tools/tools/crypto/cryptotest.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/tools/crypto/cryptotest.c b/tools/tools/crypto/cryptotest.c index 13c52dd..5f5e450 100644 --- a/tools/tools/crypto/cryptotest.c +++ b/tools/tools/crypto/cryptotest.c @@ -250,7 +250,7 @@ runtest(struct alg *alg, int count, int size, u_long cmd, struct timeval *tv) char *cleartext, *ciphertext, *originaltext; struct session2_op sop; struct crypt_op cop; - char iv[8]; + char iv[EALG_MAX_BLOCK_LEN]; bzero(&sop, sizeof(sop)); if (!alg->ishash) { |