Skip site navigation (1)Skip section navigation (2)
Date:      19 Nov 2003 00:53:24 -0000
From:      Max Laier <max@love2party.net>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/59442: [Maintainer-Update:] security/pf - build after ip_input.c#1.254
Message-ID:  <20031119005324.99203.qmail@vampire.homelinux.org>
Resent-Message-ID: <200311190100.hAJ10Pls025304@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         59442
>Category:       ports
>Synopsis:       [Maintainer-Update:] security/pf - build after ip_input.c#1.254
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          maintainer-update
>Submitter-Id:   current-users
>Arrival-Date:   Tue Nov 18 17:00:25 PST 2003
>Closed-Date:
>Last-Modified:
>Originator:     Max Laier
>Release:        FreeBSD 5.1-RELEASE-p10 i386
>Organization:
>Environment:
System: FreeBSD router.laiers.local 5.1-RELEASE-p10 FreeBSD 5.1-RELEASE-p10 #1: Sun Oct 5 17:38:55 CEST 2003 root@router.laiers.local:/usr/obj/usr/src/sys/ALTQ i386


	
>Description:
	ip_input.c#1.254 changes parameter lists for ip_rtaddr and ip_output.
	Make pf build again with new ip_input.c (__FreeBSD_version was not
	explicitly bumped for this commit so we have a delta of one day)
	
	Found-by: bento
>How-To-Repeat:
	
>Fix:

	

--- pf.diff begins here ---
diff -ruN pf.orig/Makefile pf/Makefile
--- pf.orig/Makefile	Wed Nov 19 01:44:47 2003
+++ pf/Makefile	Wed Nov 19 01:46:08 2003
@@ -7,6 +7,7 @@
 
 PORTNAME=	pf_freebsd
 PORTVERSION=	2.00
+PORTREVISION=	1
 CATEGORIES=	security ipv6
 MASTER_SITES=	http://pf4freebsd.love2party.net/
 .if defined(WITH_ALTQ) && (${WITH_ALTQ} == "yes")
diff -ruN pf.orig/files/patch-ac pf/files/patch-ac
--- pf.orig/files/patch-ac	Thu Jan  1 01:00:00 1970
+++ pf/files/patch-ac	Tue Nov 18 21:39:39 2003
@@ -0,0 +1,45 @@
+--- pf/pf.c.orig	Tue Nov 18 21:38:30 2003
++++ pf/pf.c	Tue Nov 18 21:39:01 2003
+@@ -1250,8 +1250,10 @@
+ 	struct tcphdr	*th;
+ #if defined(__FreeBSD__)
+ 	struct ip 	*ip;
++#if __FreeBSD_version < 501114
+ 	struct route 	 ro;
+ #endif
++#endif /* __FreeBSD__ */
+ 	char *opt;
+ 
+ 	/* maximum segment size tcp option */
+@@ -1366,7 +1368,6 @@
+ 		h->ip_ttl = ttl ? ttl : ip_defttl;
+ 		h->ip_sum = 0;
+ #if defined(__FreeBSD__)
+-		bzero(&ro, sizeof(ro));
+ 		ip = mtod(m, struct ip *);
+ 		/*
+ 		 * XXX
+@@ -1376,6 +1377,8 @@
+ 		 */
+ 		NTOHS(ip->ip_len);
+ 		NTOHS(ip->ip_off);
++#if __FreeBSD_version < 501114
++		bzero(&ro, sizeof(ro));
+ 		ip_rtaddr(ip->ip_dst, &ro);
+ 		PF_UNLOCK();
+ 		ip_output(m, (void *)NULL, &ro, 0, (void *)NULL,
+@@ -1384,7 +1387,13 @@
+ 		if(ro.ro_rt) {
+ 			RTFREE(ro.ro_rt);
+ 		}
+-#else
++#else /* __FreeBSD_version > 501113 */
++		PF_UNLOCK();
++		ip_output(m, (void *)NULL, (void *)NULL, 0, (void *)NULL,
++		    (void *)NULL);
++		PF_LOCK();
++#endif
++#else /* ! __FreeBSD__ */
+ 		ip_output(m, (void *)NULL, (void *)NULL, 0, (void *)NULL,
+ 		    (void *)NULL);
+ #endif
--- pf.diff ends here ---


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20031119005324.99203.qmail>