From: djm@openbsd.org Date: Mon, 25 Jun 2018 22:28:33 +0000 (+0000) Subject: upstream: fix NULL dereference in open_listen_match_tcpip() X-Git-Tag: V_7_8_P1~105 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=90e51d672711c19a36573be1785caf35019ae7a8;p=thirdparty%2Fopenssh-portable.git upstream: fix NULL dereference in open_listen_match_tcpip() OpenBSD-Commit-ID: c968c1d29e392352383c0f9681fcc1e93620c4a9 --- diff --git a/channels.c b/channels.c index 1b40d7da6..83778b465 100644 --- a/channels.c +++ b/channels.c @@ -1,4 +1,4 @@ -/* $OpenBSD: channels.c,v 1.381 2018/06/06 18:22:41 djm Exp $ */ +/* $OpenBSD: channels.c,v 1.382 2018/06/25 22:28:33 djm Exp $ */ /* * Author: Tatu Ylonen * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland @@ -3886,7 +3886,7 @@ open_listen_match_tcpip(struct permission *allowed_open, allowed_host = translate ? channel_rfwd_bind_host(allowed_open->listen_host) : allowed_open->listen_host; - if (allowed_host == NULL || + if (allowed_host == NULL || requestedhost == NULL || strcmp(allowed_host, requestedhost) != 0) return 0; return 1;