Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 09 Apr 2000 21:16:49 -0400
From:      Jason Miller <jmille34@tampabay.rr.com>
To:        freebsd-questions@freebsd.org
Subject:   natd won't redirect a port
Message-ID:  <38F12B81.72EAB1D0@tampabay.rr.com>

next in thread | raw e-mail | index | archive | help
I'm having a hard time getting natd to redirect_port. I've got freebsd
hooked to the internet via ed0 (cable, 24.92.x.x) and to my lan via ed1
(10.1.1.1). Natd is running mostly okay.. Inside computers have complete
access to the internet. I don't want to disturb any of freebsd's ports,
but I want to direct a random incoming port (8902) to point to
10.1.1.10:80 (the webcam server on my windows machine). I've tried
everything I can think of.

in rc.conf I have:
natd_enable="yes"
natd_progra="/sbin/natd"
natd_interface="ed0"
natd_flags="-f /usr/local/etc/natd.conf" (what I wrote)

in /usr/local/etc/natd.conf I have:
dynamic yes
same_ports yes
use_sockets yes
unregistered_only yes
redirect_port tcp bunk:80 8902
interface ed0

It's the last two lines I've been changing. The two shown are just the
latest ones I've tried. "bunk" is the hostname of the machine running
the server on port 80. I've also tried referencing by IP address. The
interface I've tried as ed0 and ed1 and not at all.

I'm not sure what else to check. From reading the man pages for natd, it
seems to me like I've got it right, but apparently I've got something
wrong. Can anyone help? This seems basic enough, but I'm getting really
frustrated after several days of failure. I can do lynx 10.1.1.10 from
bsd, and it connects, but when i try lynx 24.92.x.x:8902, it fails.
Could my test method be the problem? I don't have a readily available
outside connection to try from.

I also looked into using SOCKET, but I couldn't follow the directions,
and it only gave examples for redirecting existing services, whereas I
want to make up a port and map it to another machine. If there's a
better or easier way to do it than natd, I'm fully open to suggestion.

I'm using freebsd 3.4 stable

If anyone will take the time to help me, I'll gladly email the .conf
files or put them up on a webserver for your perusal or whatever would
make it easiest.

--jason miller
jmille34@tampabay.rr.com




To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?38F12B81.72EAB1D0>