Make the tests of EVP operations without padding. As a consequence,
authorRichard Levitte <levitte@openssl.org>
Mon, 28 Jun 2004 16:32:14 +0000 (16:32 +0000)
committerRichard Levitte <levitte@openssl.org>
Mon, 28 Jun 2004 16:32:14 +0000 (16:32 +0000)
there's no need for a larger BUFSIZE any more...

PR: 904

apps/speed.c

index 11d1a90ea6211741a62691fd737e8e46f144e0bb..5ed510ced69b94ca505b41824e28f0a06a10ea6d 100644 (file)
 #endif
 
 #undef BUFSIZE
-/* BUFSIZE needs to be one cipherblock larger than the largest number in the
-   lengths array (see below), to make space for padding when doing EVP tests.
-   1024 extra bytes may seem much, but hey, it doesn't hurt!
-                                                       -- Richard Levitte */
-#define BUFSIZE        ((long)1024*9+1)
+#define BUFSIZE        ((long)1024*8+1)
 int run=0;
 
 static char ftime_used = 0, times_used = 0, gettimeofday_used = 0, getrusage_used = 0;
@@ -1399,6 +1395,7 @@ int MAIN(int argc, char **argv)
                                        EVP_DecryptInit_ex(&ctx,evp_cipher,NULL,key16,iv);
                                else
                                        EVP_EncryptInit_ex(&ctx,evp_cipher,NULL,key16,iv);
+                               EVP_CIPHER_CTX_set_padding(&ctx, 0);
 
                                Time_F(START);
                                if(decrypt)