From owner-freebsd-questions@FreeBSD.ORG Tue Oct 4 05:38:48 2005 Return-Path: X-Original-To: freebsd-questions@freebsd.org 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 589FE16A41F for ; Tue, 4 Oct 2005 05:38:48 +0000 (GMT) (envelope-from freebsduser@comcast.net) Received: from sccrmhc14.comcast.net (sccrmhc14.comcast.net [63.240.76.49]) by mx1.FreeBSD.org (Postfix) with ESMTP id E8BD643D45 for ; Tue, 4 Oct 2005 05:38:47 +0000 (GMT) (envelope-from freebsduser@comcast.net) Received: from opteron (c-67-171-212-242.hsd1.or.comcast.net[67.171.212.242]) by comcast.net (sccrmhc14) with SMTP id <2005100405384601400ok3lae>; Tue, 4 Oct 2005 05:38:46 +0000 Message-ID: <005901c5c8a6$2ee5ddf0$0c64a8c0@opteron> From: "K Anderson" To: "Foo Ji-Haw" , References: <010a01c5c89a$f4234c80$c801a8c0@nexpc> <004b01c5c8a0$59001f70$0c64a8c0@opteron> <013b01c5c8a2$b8f57b80$c801a8c0@nexpc> Date: Mon, 3 Oct 2005 22:40:52 -0700 X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.2180 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180 X-RFC2646: Format=Flowed; Original Cc: Subject: Re: Need help: fwd on ipfw X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Oct 2005 05:38:48 -0000 ----- Original Message ----- From: "Foo Ji-Haw" To: "K Anderson" ; Sent: Monday, October 03, 2005 10:16 PM Subject: Re: Need help: fwd on ipfw > Hello Mr Anderson, > > So, the story is that the newer versions of 5.x comes with forwarding > disabled, hence the inability to to ipfw add fwd? > > Ok, will definately give it a try. Thanks for being a better Googler than > me! I don't recall if the default kernel has it compiled in, most likely not. You can check the generic kernel configuration file. > ----- Original Message ----- > From: "K Anderson" > To: "Foo Ji-Haw" ; > Sent: Tuesday, October 04, 2005 12:59 PM > Subject: Re: Need help: fwd on ipfw > > >> >> ----- Original Message ----- >> From: "Foo Ji-Haw" >> To: >> Sent: Monday, October 03, 2005 9:20 PM >> Subject: Need help: fwd on ipfw >> >> >> Hi all, I really need your help on this if you can... >> >> I am trying to put set up port forwarding on my machine. So far the usual >> 'add allow' and 'add deny' rules work perfectly. The most important rule >> which bugs me is the 'add fwd' rule, which the snippet below shows: >> ipfw add fwd 192.168.0.4,80 tcp from 10.10.10.0 to any 80 >> >> When I try to enter this on the command line, I get the following error: >> ipfw: getsockopt(IP_FW_ADD): Invalid Argument >> >> I tried researching the web. Some mention the error only upon recompiling >> kernels. But I am using the standard 5.4 product release as-is. My > firewall >> rules in rc.conf are as follows: >> firewall_enable="YES" >> firewall_logging="YES" >> >> I also have this line in dmesg: >> ipfw2 initialized, divert disabled, rule-based forwarding disabled, > default >> to deny, logging disabled >> >> I see that 'rule-based forwarding' is disabled. Is this what caused the >> error? How can I enable it? I can't find the details on the Handbook. >> ----------------- >> >> I did a google search on your message and found something. Here's a snip > of >> it. >> >> options IPFIREWALL >> options IPFIREWALL_DEFAULT_TO_ACCEPT >> options IPFIREWALL_VERBOSE >> options IPFIREWALL_FORWARD >> >> if you don't add them to your kernel, forwarding in ipfw will be > disabled. >> >> Here's the URL. >> http://archives.neohapsis.com/archives/freebsd/2005-01/0089.html >> >> Hope that helps. >> >> ~Mr. Anderson >> >> >> _______________________________________________ >> freebsd-questions@freebsd.org mailing list >> http://lists.freebsd.org/mailman/listinfo/freebsd-questions >> To unsubscribe, send any mail to > "freebsd-questions-unsubscribe@freebsd.org" >