From owner-cvs-all Sun Dec 13 20:39:52 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id UAA24288 for cvs-all-outgoing; Sun, 13 Dec 1998 20:39:52 -0800 (PST) (envelope-from owner-cvs-all@FreeBSD.ORG) Received: from alpo.whistle.com (alpo.whistle.com [207.76.204.38]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id UAA24267; Sun, 13 Dec 1998 20:39:27 -0800 (PST) (envelope-from julian@whistle.com) Received: (from daemon@localhost) by alpo.whistle.com (8.8.5/8.8.5) id UAA12473; Sun, 13 Dec 1998 20:34:59 -0800 (PST) Received: from current1.whistle.com(207.76.205.22) via SMTP by alpo.whistle.com, id smtpdF12471; Mon Dec 14 04:34:49 1998 Date: Sun, 13 Dec 1998 20:34:46 -0800 (PST) From: Julian Elischer To: Gary Palmer cc: Matthew Dillon , committers@FreeBSD.ORG Subject: Re: Proposed changes to fix bounds checking in alias_nbt.c In-Reply-To: <81947.913582743@gjp.erols.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk This is a bug in CVS under some circumstances it is impossible to get CVS to generate a correct DIFF you'll probably find a truncated line in the diff with the next line appended to the end of it, somewhere in that vicinity.. On Sun, 13 Dec 1998, Gary Palmer wrote: > Matthew Dillon wrote in message ID > <199812122259.OAA03354@apollo.backplane.com>: > > While looking at PR bin/8962, I found that > > /usr/src/lib/libalias/alias_nbt.c is completely broken - it does no > > bounds checking whatsoever. None. Zilch. > > > > Below is a proposed diff, and after that is the complete file. I would > > appreciate it if someone looked over it. I cannot easily test it because > > I don't run NAT. > > > > Also: the formatting of the original source is phenominally aweful. I > > did not try to fix it completely, so don't post followups about the bad > > formatting please! > > Tried using the patch, but got: > > |Index: alias_nbt.c > |=================================================================== > |RCS file: /home/ncvs/src/lib/libalias/alias_nbt.c,v > |retrieving revision 1.1 > |diff -c -r1.1 alias_nbt.c > |*** alias_nbt.c 1998/05/24 03:03:10 1.1 > |--- alias_nbt.c 1998/12/12 22:54:58 > -------------------------- > Patching file alias_nbt.c using Plan A... > Hunk #1 succeeded at 132. > Hunk #2 succeeded at 158. > Hunk #3 succeeded at 188. > Hunk #4 succeeded at 207. > Hunk #5 succeeded at 282. > Hunk #6 succeeded at 332. > Hunk #7 succeeded at 350. > Hunk #8 succeeded at 385. > Hunk #9 succeeded at 397. > Hunk #10 succeeded at 417. > Hunk #11 succeeded at 441. > Hunk #12 succeeded at 450. > Hunk #13 succeeded at 466. > Hunk #14 succeeded at 494. > Hunk #15 succeeded at 541. > Hunk #16 succeeded at 565. > Hunk #17 succeeded at 575. > patch: **** Premature "---" at line 739--check line numbers at line 693 > > > The full version of the file seemed to compile though. Since I was the > originator, I'll test it out, but it doesn't core regularly enough for me to > say if it worked or not (i.e. I have no way of knowing if the patch fixed > anything or not). So you may want to go ahead and just commit it. > > Gary > -- > Gary Palmer FreeBSD Core Team Member > FreeBSD: Turning PC's into workstations. See http://www.FreeBSD.ORG/ for info > > > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message