From owner-freebsd-questions@FreeBSD.ORG Wed Aug 5 21:21:43 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B788C106566B for ; Wed, 5 Aug 2009 21:21:43 +0000 (UTC) (envelope-from norgaard@locolomo.org) Received: from mail.locolomo.org (97.pool85-48-194.static.orange.es [85.48.194.97]) by mx1.freebsd.org (Postfix) with ESMTP id 70F8F8FC16 for ; Wed, 5 Aug 2009 21:21:43 +0000 (UTC) Received: from beta.1-16-172-dyn.locolomo.org (beta.1-16-172-dyn.locolomo.org [172.16.1.127]) by mail.locolomo.org (Postfix) with ESMTPSA id 59F461C1A67; Wed, 5 Aug 2009 23:21:42 +0200 (CEST) Message-ID: <4A79F7E5.9020509@locolomo.org> Date: Wed, 05 Aug 2009 23:21:41 +0200 From: Erik Norgaard User-Agent: Thunderbird 2.0.0.22 (Macintosh/20090605) MIME-Version: 1.0 To: Stefan Miklosovic References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit Cc: freebsd-questions@freebsd.org Subject: Re: sshd and dhcp bind to specific address X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Aug 2009 21:21:44 -0000 Stefan Miklosovic wrote: > hi, > > my pc gets ip address from dhcp server, > but on my pc, there is running > sshd. > > I want to make ssh to listen to only one > ip address, but if ip changes due to dhcp, > ssh server do not work properly. > > I know, that dhcp is able to assign ip address > to client from some range e.g. 192.168.0.1-254 > It is possible to do the same with ssh in case > that it is not possible to do it only with one ip? > > I want a solution which would work every time, > not only some specific one. I don't know if this will solve your problem, you can set ListenAddress in sshd_config, by default this is 0.0.0.0 or any. You can have multiple ListenAddress entries. I do not know if you can specify an ip-range, that would solve the problem I guess. It doesn't seem like you can configure sshd to bind to a particular interface, whichever address it may have, that would be the best solution. BR, Erik -- Erik Nørgaard Ph: +34.666334818/+34.915211157 http://www.locolomo.org