login
Header Space

 
 

NAT with PF

Previous thread: freedom Rocks Mailing List - Action Required by freedom Rocks on Wednesday, May 16, 2007 - 11:46 am. (1 message)

Next thread: openBSD as a 802.11b/g AP by James Mackinnon on Wednesday, May 16, 2007 - 2:20 pm. (6 messages)
To: <misc@...>
Subject: NAT with PF
Date: Wednesday, May 16, 2007 - 12:55 pm

Hi;

My knowledge of PF has grown a tad but, despite whatever I may or may-not have
learned, NAT still does not seem to be functioning and my internal lan
computers cannot access the internet.

The NAT rule is as such:
pfctl -sn
nat on rl0 inet from 192.168.0.0/24 to 192.168.0.1 -&gt; 64.142.102.8

The computers on my workgroup are receiving dynamic addresses from rl1, an
ethernet card in my OpenBSD box.
Ip fowarding is enabled in /etc/sysctl.conf and pf=YES in /etc/rc.conf

I greatly appreciate any help in resolving this issue. If any further details
are required to diagnose the problem, please contact me by email at
BradenM@sonomacomputer.com

Thank you;
Bray
To: BradenM - Sonoma Computer <BradenM@...>
Cc: <misc@...>
Date: Wednesday, May 16, 2007 - 2:07 pm

Here is what mine reads:
nat on fxp0 inet from 192.168.0.0/24 to any -&gt; 69.254.129.192


[demime 1.01d removed an attachment of type APPLICATION/DEFANGED which had a name of jlindsey.11442DEFANGED-vcf]
To: <misc@...>
Date: Wednesday, May 16, 2007 - 8:30 pm

Everyone;

Thank you for the quick response. I reviewed the messages and used the 
advice from all posts to develop a solution that has solved my lack of 
internet problem.

Thank you;
Bray
To: BradenM - Sonoma Computer <BradenM@...>
Cc: <misc@...>
Date: Wednesday, May 16, 2007 - 1:29 pm

Looks bit odd to me. Are you sure you only want to nat for that
address?  The corresponding output on my home gateway is

       nat on xl0 inet from 192.168.103.0/24 to any -&gt; (xl0) round-robin static-port

which is the result of this pf.conf line:

      nat on $ext_if from $int_if:network to any -&gt; ($ext_if) static-port

The next thing to check, of course if you have the necessary
corresponding pass rules (NAT by itself does not pass)

-- 
Peter N. M. Hansteen, member of the first RFC 1149 implementation team
http://www.blug.linux.no/rfc1149/ http://www.datadok.no/ http://www.nuug.no/
"First, we kill all the spammers" The Usenet Bard, "Twice-forwarded tales"
delilah spamd[29949]: 85.152.224.147: disconnected after 42673 seconds.
To: BradenM - Sonoma Computer <BradenM@...>
Cc: <misc@...>
Date: Wednesday, May 16, 2007 - 1:24 pm

Try:
nat on rl0 inet from 192.168.0.0/24 to any -&gt; 64.142.102.8

-ME
To: BradenM - Sonoma Computer <BradenM@...>
Cc: <misc@...>
Date: Wednesday, May 16, 2007 - 1:21 pm

Please post your full pf.conf :-)

kind regards

Siju
Previous thread: freedom Rocks Mailing List - Action Required by freedom Rocks on Wednesday, May 16, 2007 - 11:46 am. (1 message)

Next thread: openBSD as a 802.11b/g AP by James Mackinnon on Wednesday, May 16, 2007 - 2:20 pm. (6 messages)
speck-geostationary