summaryrefslogtreecommitdiff
path: root/cipher-ctr.c
diff options
context:
space:
mode:
authorDamien Miller <djm@mindrot.org>2003-09-23 19:24:21 +1000
committerDamien Miller <djm@mindrot.org>2003-09-23 19:24:21 +1000
commite043e8e2211ee07e98f95fe975cca56959eb6c59 (patch)
tree862aceabb43ef9c0ce7400e1ca981033e17df61d /cipher-ctr.c
parent03575cc07de0c67586e56a5e1ee2d3a3ee35300c (diff)
- (djm) Fix SSH1 challenge kludge
- (djm) Bug #671: Fix builds on OpenBSD - (djm) Bug #676: Fix PAM stack corruption - (djm) Fix bad free() in PAM code - (djm) Don't call pam_end before pam_init - (djm) Enable build with old OpenSSL again - (djm) Trim deprecated options from INSTALL. Mention UsePAM - (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu
Diffstat (limited to 'cipher-ctr.c')
-rw-r--r--cipher-ctr.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/cipher-ctr.c b/cipher-ctr.c
index a2bab5c14..4f0814b22 100644
--- a/cipher-ctr.c
+++ b/cipher-ctr.c
@@ -21,6 +21,10 @@ RCSID("$OpenBSD: cipher-ctr.c,v 1.2 2003/06/17 18:14:23 markus Exp $");
21#include "log.h" 21#include "log.h"
22#include "xmalloc.h" 22#include "xmalloc.h"
23 23
24#if OPENSSL_VERSION_NUMBER < 0x00906000L
25#define SSH_OLD_EVP
26#endif
27
24#if OPENSSL_VERSION_NUMBER < 0x00907000L 28#if OPENSSL_VERSION_NUMBER < 0x00907000L
25#include "rijndael.h" 29#include "rijndael.h"
26#define AES_KEY rijndael_ctx 30#define AES_KEY rijndael_ctx
@@ -135,7 +139,9 @@ evp_aes_128_ctr(void)
135 aes_ctr.init = ssh_aes_ctr_init; 139 aes_ctr.init = ssh_aes_ctr_init;
136 aes_ctr.cleanup = ssh_aes_ctr_cleanup; 140 aes_ctr.cleanup = ssh_aes_ctr_cleanup;
137 aes_ctr.do_cipher = ssh_aes_ctr; 141 aes_ctr.do_cipher = ssh_aes_ctr;
142#ifndef SSH_OLD_EVP
138 aes_ctr.flags = EVP_CIPH_CBC_MODE | EVP_CIPH_VARIABLE_LENGTH | 143 aes_ctr.flags = EVP_CIPH_CBC_MODE | EVP_CIPH_VARIABLE_LENGTH |
139 EVP_CIPH_ALWAYS_CALL_INIT | EVP_CIPH_CUSTOM_IV; 144 EVP_CIPH_ALWAYS_CALL_INIT | EVP_CIPH_CUSTOM_IV;
145#endif
140 return (&aes_ctr); 146 return (&aes_ctr);
141} 147}