From owner-freebsd-bugs@FreeBSD.ORG Tue Jun 19 07:00:21 2007 Return-Path: X-Original-To: freebsd-bugs@hub.freebsd.org Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 3C20416A421 for ; Tue, 19 Jun 2007 07:00:21 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [69.147.83.40]) by mx1.freebsd.org (Postfix) with ESMTP id 2E5C313C45A for ; Tue, 19 Jun 2007 07:00:21 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.4/8.13.4) with ESMTP id l5J70K2h013296 for ; Tue, 19 Jun 2007 07:00:20 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.4/8.13.4/Submit) id l5J70KJd013294; Tue, 19 Jun 2007 07:00:20 GMT (envelope-from gnats) Date: Tue, 19 Jun 2007 07:00:20 GMT Message-Id: <200706190700.l5J70KJd013294@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org From: "Frank Behrens" Cc: Subject: Re: kern/84215: [jail] [patch] wildcard ip (INADDR_ANY) should not bind inside a jail X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Frank Behrens List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Jun 2007 07:00:21 -0000 The following reply was made to PR kern/84215; it has been noted by GNATS. From: "Frank Behrens" To: linimon@FreeBSD.org, freebsd-bugs@FreeBSD.org, FreeBSD-gnats-submit@FreeBSD.org Cc: Subject: Re: kern/84215: [jail] [patch] wildcard ip (INADDR_ANY) should not bind inside a jail Date: Tue, 19 Jun 2007 08:51:11 +0200 Mark Linimon wrote on 19 Jun 2007 1:00: > State-Changed-From-To: open->feedback > Note that feedback (about ssh not working with this patch) was requested > some time ago. Sorry, I must have overlooked that. My answer is: The patch should work, I can not confirm the problem. Meanwhile I'm using this patch for years and I use FreeBSD 6.2-STABLE-200705211513. A short test shows with net.inet.ip.bindwildcardtojails=0: > ifconfig lo1 alias 192.168.200.11 > jail / testssh 192.168.200.11 /bin/csh otherhost>nc -vvv 192.168.0.10 22 router.behrens [192.168.0.10] 22 (?) open SSH-2.0-OpenSSH_4.5p1 FreeBSD-20061110 otherhost>nc -vvv 192.168.200.11 22 192.168.200.11: inverse host lookup failed: h_errno 11004: NO_DATA (UNKNOWN) [192.168.200.11] 22 (?): connection refused Now I start inside the jail the sshd daemon: frank@testssh:/# /usr/sbin/sshd frank@testssh:/# sockstat -4 USER COMMAND PID FD PROTO LOCAL ADDRESS FOREIGN ADDRESS root sshd 25774 3 tcp4 192.168.200.11:22 *:* and the connection to jail is possible otherhost>nc -vvv 192.168.200.11 22 192.168.200.11: inverse host lookup failed: h_errno 11004: NO_DATA (UNKNOWN) [192.168.200.11] 22 (?) open SSH-2.0-OpenSSH_4.5p1 FreeBSD-20061110 The short examples with nc show the same behavior as real ssh connections. Frank Behrens