Subject: Re: Ipnat.conf redir portmappling
To: Jehun Cho <coolmac@mac.com>
From: John Klos <john@sixgirls.org>
List: port-mac68k
Date: 01/19/2001 03:30:46
> I use NetBSD 1.5 on Mac Iici
> I have 2 Ethernet card
> ae0 is DHCP Client by cable modem and ae1(192.168.1.254) is connect to Hub
>
> But I can't connect to My Apache server and ftp server from My Office

If you'd like to map ports from the cable modem's IP, do this:

map ae0 192.168.1.0/24 -> 0/32 proxy port ftp ftp/tcp
map ae0 192.168.1.0/24 -> 0/32 portmap tcp/udp 10000:65000
map ae0 192.168.1.0/24 -> 0/32
rdr ae0 0.0.0.0/0 port 20 -> 192.168.1.66 port 20 tcp/udp
rdr ae0 0.0.0.0/0 port 21 -> 192.168.1.66 port 21 tcp/udp
rdr ae0 0.0.0.0/0 port 80 -> 192.168.1.66 port 80 tcp/udp

The "rdr"s map ftp (ports 20 and 21; I don't know if 20 is really
necessary) and port 80 to 192.168.1.66; you could change that to whatever
internal IP you want.

If you can't talk to ftp or Apache that's running on the IIci, then it
could be that Apache and inetd need to be started after you get the DHCP
lease. Try rehupping them.

Otherwise, send your rules so we can see if there's something wrong with
them.

John Klos