summaryrefslogtreecommitdiff
path: root/cipher.c
diff options
context:
space:
mode:
authordtucker@openbsd.org <dtucker@openbsd.org>2020-01-23 10:24:29 +0000
committerDarren Tucker <dtucker@dtucker.net>2020-01-23 21:53:54 +1100
commit7f8e66fea8c4e2a910df9067cb7638999b7764d5 (patch)
tree88c1a4a73a03cfa993fee0c1f23b6327ef1351a1 /cipher.c
parent69ac4e33023b379e9a8e9b4b6aeeffa6d1fcf6fa (diff)
upstream: Make zlib optional. This adds a "ZLIB" build time option
that allows building without zlib compression and associated options. With feedback from markus@, ok djm@ OpenBSD-Commit-ID: 44c6e1133a90fd15a3aa865bdedc53bab28b7910
Diffstat (limited to 'cipher.c')
-rw-r--r--cipher.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/cipher.c b/cipher.c
index 25f98ba8e..820bc6ace 100644
--- a/cipher.c
+++ b/cipher.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: cipher.c,v 1.113 2019/09/06 05:23:55 djm Exp $ */ 1/* $OpenBSD: cipher.c,v 1.114 2020/01/23 10:24:29 dtucker Exp $ */
2/* 2/*
3 * Author: Tatu Ylonen <ylo@cs.hut.fi> 3 * Author: Tatu Ylonen <ylo@cs.hut.fi>
4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland 4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -143,6 +143,17 @@ cipher_alg_list(char sep, int auth_only)
143 return ret; 143 return ret;
144} 144}
145 145
146const char *
147compression_alg_list(int compression)
148{
149#ifdef WITH_ZLIB
150 return compression ? "zlib@openssh.com,zlib,none" :
151 "none,zlib@openssh.com,zlib";
152#else
153 return "none";
154#endif
155}
156
146u_int 157u_int
147cipher_blocksize(const struct sshcipher *c) 158cipher_blocksize(const struct sshcipher *c)
148{ 159{