From owner-freebsd-net@FreeBSD.ORG Sun Mar 13 23:09:13 2005 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 826DE16A4CE for ; Sun, 13 Mar 2005 23:09:13 +0000 (GMT) Received: from diehard.n-r-g.com (diehard.n-r-g.com [62.48.3.9]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9DAD443D1F for ; Sun, 13 Mar 2005 23:09:12 +0000 (GMT) (envelope-from cjeker@diehard.n-r-g.com) Received: (qmail 18457 invoked by uid 1001); 13 Mar 2005 23:09:15 -0000 Date: Mon, 14 Mar 2005 00:08:53 +0059 From: Claudio Jeker To: freebsd-net@freebsd.org Message-ID: <20050313230915.GF3697@diehard.n-r-g.com> Mail-Followup-To: Claudio Jeker , freebsd-net@freebsd.org References: <42348BDF.2080101@authtec.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <42348BDF.2080101@authtec.com> User-Agent: Mutt/1.5.6i Subject: Re: OpenBGPD with FreeBSD X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 13 Mar 2005 23:09:13 -0000 On Mon, Mar 14, 2005 at 02:52:15AM +0800, sam wun wrote: > Hi, > > Had openbgpd ported to freebsd or is it in any progress? > If I want to install it in FreeBSD, is there any guideline for me to follow? > You have to remove the full pfkey interface and replace it with dummy functions as it is incompatible. So tcp md5 does not work but I think it is still broken in FreeBSD anyway. Here is a diff I created some time ago. Perhaps some other minor changes are needed. -- :wq Claudio ? obj Index: Makefile =================================================================== RCS file: /cvs/src/usr.sbin/bgpd/Makefile,v retrieving revision 1.19 diff -u -p -r1.19 Makefile --- Makefile 7 May 2004 10:06:15 -0000 1.19 +++ Makefile 26 May 2004 19:21:27 -0000 @@ -5,7 +5,7 @@ PROG= bgpd SRCS= bgpd.c buffer.c session.c log.c parse.y config.c imsg.c \ rde.c rde_rib.c rde_decide.c rde_prefix.c mrt.c kroute.c \ - control.c pfkey.c rde_update.c rde_attr.c printconf.c \ + control.c pfkey_compat.c rde_update.c rde_attr.c printconf.c \ rde_filter.c pftable.c CFLAGS+= -Wall -I${.CURDIR} CFLAGS+= -Wstrict-prototypes -Wmissing-prototypes Index: pfkey_compat.c =================================================================== RCS file: pfkey_compat.c diff -N pfkey_compat.c --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ pfkey_compat.c 26 May 2004 19:21:27 -0000 @@ -0,0 +1,26 @@ +#include "bgpd.h" +#include "session.h" + +int +pfkey_establish(struct peer *p) +{ + if (p->conf.auth.method) + return (-1); + return (0); +} + +int +pfkey_remove(struct peer *p) +{ + if (p->conf.auth.method) + return (-1); + return (0); +} + +int +pfkey_init(void) +{ + log_warnx("no kernel support for PF_KEY"); + return (-1); +} +