From owner-freebsd-questions@FreeBSD.ORG Mon Oct 11 10:03:13 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6575C16A4CE for ; Mon, 11 Oct 2004 10:03:13 +0000 (GMT) Received: from virtual.micronet.sk (smtp-r.micronet.sk [213.215.96.238]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6C04543D53 for ; Mon, 11 Oct 2004 10:03:12 +0000 (GMT) (envelope-from danger@wilbury.sk) Received: from danger.dnv.dewnet.sk ([213.215.105.189]) by virtual.micronet.sk (8.12.11/8.12.11) with ESMTP id i9BA2tZ2032979 for ; Mon, 11 Oct 2004 12:02:55 +0200 (CEST) (envelope-from danger@wilbury.sk) Resent-Date: Mon, 11 Oct 2004 12:02:55 +0200 (CEST) Resent-Message-Id: <200410111002.i9BA2tZ2032979@virtual.micronet.sk> Date: Mon, 11 Oct 2004 12:04:19 +0200 From: DanGer X-Mailer: The Bat! (v2.12.00) Business X-Priority: 3 (Normal) Message-ID: <1168543283.20041011120419@wilbury.sk> To: questions@freebsd.org Resent-From: DanGer MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Subject: Re: Adding network & IP to hosts.deny X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: DanGer List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Oct 2004 10:03:13 -0000 Hello Subhro, Monday, October 11, 2004, 11:32:13 AM, you wrote: > The firewall would be definitely a better bet than host.deny. > If you are using ipfw you can simply add a couple of deny rules like: > ipfw add 100 deny all from 192.168.100.0/24 to me in > Regards > S. > On Mon, 11 Oct 2004 08:46:40 +0200, Pelle Andersson wrote: >> >> Hi! >> >> I have a lot of login attempts from various networks and IP addresses >> on my FBSD 4.10 server. I have read the man pages for hosts.deny but >> do not understand how to add networks and IP addresses to it. >> >> Let's say I want to block the network address 192.168.100.0 and/or >> the IP address 192.168.135.77. >> >> What I understand is when using hosts.deny, I stopping them totally >> from using any networking services, right? >> >> Would it be better to let the built-in firewall (/etc/rc.firewall) >> to stopping them? I have the firewall activated and have changed >> the port for example SSH to a higher one. >> >> Could someone please provide me with some examples on either using >> hosts.deny or the default firewall? you should try hosts.allow alrady. for example: sshd : 192.168.135.77 : deny >> >> A big thanks in advance, >> Best Regards Pelle -- Best regards +----------==/\/\==----------+ | DanGer | | DanGer@IRCnet ICQ261701668 | | http://danger.homeunix.org | +----------==\/\/==----------+