LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
Search this Thread
Old 01-25-2008, 03:12 AM   #1
efm
Member
 
Registered: Apr 2005
Location: indonesia
Distribution: suse 10
Posts: 101

Rep: Reputation: 15
Shorewall Port Forwarding


Hello,
I hope there's no post like this already,

I have an ubuntu machine acts as a firewall, with eth0 connects to the
internet with ip 219.83.1.0 and eth2 connects to the lan with ip
192.168.1.4.

inside the lan, i have a web server with ip 192.168.1.5. I set its http
port to 15000.

now, I want to browse to the webserver from the internet. How can I set
the routing? I'm using shorewall. I want that if I type
http://219.83.1.0:15000, then I will be connected to the webserver inside
the lan

thank you
Faizal
 
Old 01-25-2008, 04:15 AM   #2
efm
Member
 
Registered: Apr 2005
Location: indonesia
Distribution: suse 10
Posts: 101

Original Poster
Rep: Reputation: 15
btw, in etc/shorewall/rules, i wrote this line:

DNAT net loc:192.168.1.5:8082 tcp 8082

just like the FAQ, but I can't browse 192.168.1.5's web server from the
internet
 
Old 12-01-2010, 12:22 AM   #3
lqman
LQ Newbie
 
Registered: Nov 2010
Location: Surabaya, Indonesia
Distribution: debian, ubuntu, FreeBSD, Solaris
Posts: 17

Rep: Reputation: 3
Quote:
Originally Posted by efm View Post
btw, in etc/shorewall/rules, i wrote this line:

DNAT net loc:192.168.1.5:8082 tcp 8082

just like the FAQ, but I can't browse 192.168.1.5's web server from the
internet
Have you solve this problem?
if not, you may try this in your /etc/shorewall/rules

DNAT net loc:192.168.1.5:15000 tcp 15000

every connection from net zone to your firewall (ip 219.83.1.0) port 15000 will be NAT-ed into your server (ip 192.168.1.5) port 15000.

Then, you can access http://219.83.1.0:15000 from internet to browse your http server.

FYI, you can't use this 219.83.1.0 as IP Address, because that is network-address, but in this case I ignore that.0


*sorry for to late answer*
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
IPCHAINS port forwarding and IPTABLES port forwarding ediestajr Linux - Networking 26 01-14-2007 07:35 PM
Shorewall : So simple , yet so hard (Help with port forwarding) Wynand1 Linux - Networking 1 05-09-2006 12:33 AM
Shorewall port forwarding problem kresho Linux - Networking 0 01-26-2006 07:53 AM
MNF and Shorewall port forwarding apoc63 Linux - Networking 2 05-18-2005 10:39 AM
Shorewall - Port forwarding BrianNJ Linux - Networking 0 05-24-2004 08:00 AM


All times are GMT -5. The time now is 10:57 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration