summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordjm <djm@openbsd.org>2010-10-01 23:05:32 +0000
committerdjm <djm@openbsd.org>2010-10-01 23:05:32 +0000
commit3bec9ea9e67f33b4f51d3ec6dbf5bcaa87c0fbb6 (patch)
tree0cdf5edcda428342cfc9ef07ab6b9116da7806de
parentupdate to openssl-1.0.0a (diff)
downloadwireguard-openbsd-3bec9ea9e67f33b4f51d3ec6dbf5bcaa87c0fbb6.tar.xz
wireguard-openbsd-3bec9ea9e67f33b4f51d3ec6dbf5bcaa87c0fbb6.zip
adapt to API changes in openssl-1.0.0a
-rw-r--r--usr.bin/ssh/Makefile.inc8
-rw-r--r--usr.bin/ssh/cipher-3des1.c4
-rw-r--r--usr.bin/ssh/cipher-bf1.c7
-rw-r--r--usr.bin/ssh/cipher-ctr.c12
4 files changed, 16 insertions, 15 deletions
diff --git a/usr.bin/ssh/Makefile.inc b/usr.bin/ssh/Makefile.inc
index 04606afd41d..d9056fe2eb2 100644
--- a/usr.bin/ssh/Makefile.inc
+++ b/usr.bin/ssh/Makefile.inc
@@ -1,11 +1,11 @@
-# $OpenBSD: Makefile.inc,v 1.36 2010/02/20 20:28:11 markus Exp $
+# $OpenBSD: Makefile.inc,v 1.37 2010/10/01 23:05:32 djm Exp $
CFLAGS+= -I${.CURDIR}/..
CDIAGFLAGS= -Wall
-#CDIAGFLAGS+= -Werror
+CDIAGFLAGS+= -Werror
CDIAGFLAGS+= -Wpointer-arith
-CDIAGFLAGS+= -Wno-uninitialized
+CDIAGFLAGS+= -Wuninitialized
CDIAGFLAGS+= -Wstrict-prototypes
CDIAGFLAGS+= -Wmissing-prototypes
CDIAGFLAGS+= -Wunused
@@ -13,7 +13,7 @@ CDIAGFLAGS+= -Wsign-compare
CDIAGFLAGS+= -Wbounded
CDIAGFLAGS+= -Wshadow
-#DEBUG=-g
+DEBUG=-g
#CFLAGS+= -DJPAKE
diff --git a/usr.bin/ssh/cipher-3des1.c b/usr.bin/ssh/cipher-3des1.c
index 720a0634af4..8af7b792d56 100644
--- a/usr.bin/ssh/cipher-3des1.c
+++ b/usr.bin/ssh/cipher-3des1.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cipher-3des1.c,v 1.6 2006/08/03 03:34:42 deraadt Exp $ */
+/* $OpenBSD: cipher-3des1.c,v 1.7 2010/10/01 23:05:32 djm Exp $ */
/*
* Copyright (c) 2003 Markus Friedl. All rights reserved.
*
@@ -92,7 +92,7 @@ ssh1_3des_init(EVP_CIPHER_CTX *ctx, const u_char *key, const u_char *iv,
}
static int
-ssh1_3des_cbc(EVP_CIPHER_CTX *ctx, u_char *dest, const u_char *src, u_int len)
+ssh1_3des_cbc(EVP_CIPHER_CTX *ctx, u_char *dest, const u_char *src, size_t len)
{
struct ssh1_3des_ctx *c;
diff --git a/usr.bin/ssh/cipher-bf1.c b/usr.bin/ssh/cipher-bf1.c
index fc572e0849b..6664050d7f6 100644
--- a/usr.bin/ssh/cipher-bf1.c
+++ b/usr.bin/ssh/cipher-bf1.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cipher-bf1.c,v 1.5 2006/08/03 03:34:42 deraadt Exp $ */
+/* $OpenBSD: cipher-bf1.c,v 1.6 2010/10/01 23:05:32 djm Exp $ */
/*
* Copyright (c) 2003 Markus Friedl. All rights reserved.
*
@@ -57,10 +57,11 @@ swap_bytes(const u_char *src, u_char *dst, int n)
}
}
-static int (*orig_bf)(EVP_CIPHER_CTX *, u_char *, const u_char *, u_int) = NULL;
+static int (*orig_bf)(EVP_CIPHER_CTX *, u_char *,
+ const u_char *, size_t) = NULL;
static int
-bf_ssh1_cipher(EVP_CIPHER_CTX *ctx, u_char *out, const u_char *in, u_int len)
+bf_ssh1_cipher(EVP_CIPHER_CTX *ctx, u_char *out, const u_char *in, size_t len)
{
int ret;
diff --git a/usr.bin/ssh/cipher-ctr.c b/usr.bin/ssh/cipher-ctr.c
index a067ff890e9..0c7b886b9fe 100644
--- a/usr.bin/ssh/cipher-ctr.c
+++ b/usr.bin/ssh/cipher-ctr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cipher-ctr.c,v 1.10 2006/08/03 03:34:42 deraadt Exp $ */
+/* $OpenBSD: cipher-ctr.c,v 1.11 2010/10/01 23:05:32 djm Exp $ */
/*
* Copyright (c) 2003 Markus Friedl <markus@openbsd.org>
*
@@ -26,7 +26,7 @@
#include "log.h"
const EVP_CIPHER *evp_aes_128_ctr(void);
-void ssh_aes_ctr_iv(EVP_CIPHER_CTX *, int, u_char *, u_int);
+void ssh_aes_ctr_iv(EVP_CIPHER_CTX *, int, u_char *, size_t);
struct ssh_aes_ctr_ctx
{
@@ -40,7 +40,7 @@ struct ssh_aes_ctr_ctx
* (LSB at ctr[len-1], MSB at ctr[0])
*/
static void
-ssh_ctr_inc(u_char *ctr, u_int len)
+ssh_ctr_inc(u_char *ctr, size_t len)
{
int i;
@@ -51,10 +51,10 @@ ssh_ctr_inc(u_char *ctr, u_int len)
static int
ssh_aes_ctr(EVP_CIPHER_CTX *ctx, u_char *dest, const u_char *src,
- u_int len)
+ size_t len)
{
struct ssh_aes_ctr_ctx *c;
- u_int n = 0;
+ size_t n = 0;
u_char buf[AES_BLOCK_SIZE];
if (len == 0)
@@ -105,7 +105,7 @@ ssh_aes_ctr_cleanup(EVP_CIPHER_CTX *ctx)
}
void
-ssh_aes_ctr_iv(EVP_CIPHER_CTX *evp, int doset, u_char * iv, u_int len)
+ssh_aes_ctr_iv(EVP_CIPHER_CTX *evp, int doset, u_char * iv, size_t len)
{
struct ssh_aes_ctr_ctx *c;