diff options
author | Markus Friedl <markus@cvs.openbsd.org> | 2008-07-31 14:48:29 +0000 |
---|---|---|
committer | Markus Friedl <markus@cvs.openbsd.org> | 2008-07-31 14:48:29 +0000 |
commit | f2e6d8b2683777ebbb87b4ba5a457be2e7a7fafb (patch) | |
tree | bb3198d70d71f651868260596fe1516e37708774 /usr.bin/ssh | |
parent | 5b6d4ae4b19e5a1ff5701feb61afd3298e34ea6c (diff) |
don't allocate space for empty banners; report t8m at centrum.cz; ok deraadt
Diffstat (limited to 'usr.bin/ssh')
-rw-r--r-- | usr.bin/ssh/sshconnect2.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/ssh/sshconnect2.c b/usr.bin/ssh/sshconnect2.c index 3723abeb2c8..8cfa505c339 100644 --- a/usr.bin/ssh/sshconnect2.c +++ b/usr.bin/ssh/sshconnect2.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sshconnect2.c,v 1.166 2008/07/17 08:48:00 djm Exp $ */ +/* $OpenBSD: sshconnect2.c,v 1.167 2008/07/31 14:48:28 markus Exp $ */ /* * Copyright (c) 2000 Markus Friedl. All rights reserved. * @@ -377,7 +377,7 @@ input_userauth_banner(int type, u_int32_t seq, void *ctxt) debug3("input_userauth_banner"); raw = packet_get_string(&len); lang = packet_get_string(NULL); - if (options.log_level >= SYSLOG_LEVEL_INFO) { + if (len > 0 && options.log_level >= SYSLOG_LEVEL_INFO) { if (len > 65536) len = 65536; msg = xmalloc(len * 4); /* max expansion from strnvis() */ |