Re: Help setup home network when gateways, ip asigned by DHCP

2003-08-21 Thread David Kelly
On Thursday 21 August 2003 08:17 pm, Rod Person wrote:
>
> My problem is that my gateway get its external ip address via DHCP.
> I can't figure out how to setup ipfw rules to use DHCP addresses.

Use either the "me" pseudo-address or trigger on the interface. A few 
rules copied out of my current ipfw configuration:

00600 allow tcp from me to any setup
01400 allow udp from me to any dst-port 53 keep-state
01500 allow udp from me to any dst-port 123 keep-state
01600 allow udp from 69.1.30.0/24 67 to me dst-port 68
01700 allow udp from me 68 to 69.1.30.0/24 dst-port 67

-- 
David Kelly N4HHE, [EMAIL PROTECTED]
=
The human mind ordinarily operates at only ten percent of its
capacity -- the rest is overhead for the operating system.

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Help setup home network when gateways, ip asigned by DHCP

2003-08-21 Thread Bob Hall
On Thu, Aug 21, 2003 at 09:17:55PM -0400, Rod Person wrote:
> Here are the portions of rc.ipfw:
> 
> oif="fxp0"
> onet=? this is assigned via DHCP
> omask="255.255.255.240" <- Should I change this?
> oip=

I believe your current omask will work; try it and see.

I use
omask="255.255.255.0"
onet=`ifconfig fxp0 | grep "inet " | awk '{print $2}'`/24
oip=`ifconfig fxp0 | grep "inet " | awk '{print $2}'`
You could probably simplify that with
oip=`ifconfig fxp0 | grep "inet " | awk '{print $2}'`
onet=${oip}/24
but I haven't tried it. 

Bob Hall
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Help setup home network when gateways, ip asigned by DHCP

2003-08-21 Thread Mike Maltese
You may want to try IP Filter instead. In my opinion, it's rule syntax makes
it much easier to work with DHCP.

http://www.obfuscation.org/ipf/ipf-howto.html#TOC_29

- Original Message - 
From: "Rod Person" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, August 21, 2003 6:17 PM
Subject: Help setup home network when gateways, ip asigned by DHCP


> I have been trying to setup a home network for some weeks now. Here is
> the setup
>
>  --- --  ---
> |Cable Modem|---|Gateway/Server||Cisco Poweredhub|--|FreeBSD|
>  --- --    ||Laptop |
>| ---
>||win XP |
>| --- 
>|
>| 2 other
>  win ws
>
> My problem is that my gateway get its external ip address via DHCP.
> I can't figure out how to setup ipfw rules to use DHCP addresses.
>
> Here are the portions of rc.ipfw:
>
> oif="fxp0"
> onet=? this is assigned via DHCP
> omask="255.255.255.240" <- Should I change this?
> oip=
>
> #inside interface
> iif=fxp1
> inet="192.168.0.1/24"
> mask="255.255.255.0"
> iip="192.168.0.1"
>
> If someone can point me in there right direction I be really grateful.
> I can't find and discussion on this anywhere.
>
>
>
> -- 
> Rod
>
> @ Home So No Cool Signature
> http://opensourcebeef.bsd.st
>
> ___
> [EMAIL PROTECTED] mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
"[EMAIL PROTECTED]"

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"