From owner-freebsd-current@FreeBSD.ORG Wed Oct 22 08:35:15 2003 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 56C1B16A4B3; Wed, 22 Oct 2003 08:35:15 -0700 (PDT) Received: from srv1.cosmo-project.de (srv1.cosmo-project.de [213.83.6.106]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5C23243F3F; Wed, 22 Oct 2003 08:35:13 -0700 (PDT) (envelope-from andreas@klemm.apsfilter.org) Received: from srv1.cosmo-project.de (localhost [IPv6:::1]) h9MFZ9t2076706 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=NO); Wed, 22 Oct 2003 17:35:09 +0200 (CEST) (envelope-from andreas@klemm.apsfilter.org) Received: (from uucp@localhost)h9MFZ91P076705; Wed, 22 Oct 2003 17:35:09 +0200 (CEST) (envelope-from andreas@klemm.apsfilter.org) Received: from titan.klemm.apsfilter.org (localhost.klemm.apsfilter.org [127.0.0.1]) by klemm.apsfilter.org (8.12.10/8.12.9) with ESMTP id h9MFViN9004310; Wed, 22 Oct 2003 17:31:49 +0200 (CEST) (envelope-from andreas@titan.klemm.apsfilter.org) Received: (from andreas@localhost)h9MFVc3D004309; Wed, 22 Oct 2003 17:31:38 +0200 (CEST) (envelope-from andreas) Date: Wed, 22 Oct 2003 17:31:38 +0200 From: Andreas Klemm To: portmgr@FreeBSD.org Message-ID: <20031022153138.GA4102@titan.klemm.apsfilter.org> References: <20031022113039.GA10053@titan.klemm.apsfilter.org> <3F969491.5000405@openet-telecom.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3F969491.5000405@openet-telecom.com> X-Operating-System: FreeBSD 5.1-CURRENT X-Disclaimer: A free society is one where it is safe to be unpopular User-Agent: Mutt/1.5.4i cc: current@FreeBSD.org Subject: Approval for Hotfix needed for portscanner (was Re: Error assigning master socket: Too many open files) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 22 Oct 2003 15:35:15 -0000 On Wed, Oct 22, 2003 at 03:30:41PM +0100, Peter Edwards wrote: > The patch applied by the port appears bogus. It adds braces around an > "if" that stops it executing the way it was intended. I've a sneaking > suspicion that the braces were added for "clarity", but the indentation > in the original file is so badly off that the terminating brace was put > in the wrong place. Try replacing patch-ab with this: > > --- portscanner.c.orig Wed Aug 19 18:37:44 1998 > +++ portscanner.c Wed Oct 22 15:28:05 2003 > @@ -25,8 +25,8 @@ > /***********************************************************/ > > #include > -#include > #include > +#include > #include > #include > #include Hi Peter, thanks a lot for your help. You're completely right with your diagnose and fix. I'll put portmgr@ on Cc: to be allowed to commit the change and will happily apply your fix to the port if I get the approval. look here: root@titan[ttyp2]{82} /usr/ports/security/portscanner portscanner -b 1 -e 60000 -vv xx.xx.xx.xxx Resolving: xx.xx.xx.xxx -> resolved Current address: xx.xx.xx.xxx Port range: 1 to 60000 Port 135 found. Service name: loc-srv Port 445 found. Service name: microsoft-ds Port 1025 found. Service name: blackjack Port scan finished ! After changing the patch and reinstalling the port, the portscanner is completely functional again now. Best regards Andreas /// -- Andreas Klemm - Powered by FreeBSD 5.1-CURRENT Need a magic printfilter today ? -> http://www.apsfilter.org/