Quantcast
Channel: EdgeRouter topics
Viewing all articles
Browse latest Browse all 20028

1 to 1 NAT and Mail forwarding scenario challenge

$
0
0

Hello,

I have a problem with configuring port forwarding and forwarding port 25 to an specific server box.

Here's the scenario (IPs are not real and used for example):

 

I have an EdgeMax router

 

eth0 - LAN (172.16.0.0/24)
eth1 - WAN (5 static IPs provided by ISP IP range is 2.2.2.145 - 149)
eth2 - not configured

 

I have all 5 static IPs assigned to the eth1 interface.
All traffic from eth0 routes properly outbound to the internet..


I am having trouble with 2 parts:

 

1. emails are coming from specific public IP addresses (5.5.5.70-6.6.6.80, 7.7.7.100-8.8.8.200, 9.9.9.150-11.11.11.160) and once it reaches the router at port 25 I'd like them to be forwarded to an specific server in the LAN (172.16.0.26).

for some reason, I can't get this working either through the FW/NAT or Port forward Tabs in the GUI.

 

2. There's another server whose only job is to provide VPN client services.

I'd like all requests (any port) to WAN IP 2.2.2.149 to forward (all ports) to LAN IP is 172.16.0.40 specifically.

In other words, I'd like to assign an entire server(172.16.0.40) to one of the ISP static IPs(2.2.2.149) but must leave the server on the LAN subnet.

I tried really hard but cannot get this to work. Here's how I tried setting that up:

 

I went to the Firewall/NAT tab.

Destination NAT:

Inbound Interface: eth1
Translaton: 172.168.0.40

Port: blank
TCP

Dest Port (blank) - " For all ports ???? "
Destination Address: 2.2.2.149

 

Destination NAT:

Inbound Interface: eth1
Translaton: 172.168.0.26

Port: blank
TCP

Dest Port : 25
Destination Address: 2.2.2.147


AND the Firewall/NAT (do I need to do both???):

 

Orig Port 25, TCP , Forward to add 172.168.0.26, Forw to Port 26

 

Orig Port 10-6000, TCP , Forward to add 172.168.0.40, Forw to Port 40

 

Plus I set up Firewall rules:

 

WAN_LOCAL (WAN to Router - I assume this is from requests from WAN to my WAN public addresses)

rule

Dest 2.2.2.149, Prot All, Action Accept , related & stablished

Dest 2.2.2.147, Prot TCP, Action Accept , Port 25, related & stablished

 

WAN_IN (WAN to Internal - I assume this is from the router to internal devices)

rule

Dest 172.16.0.40, Prot All, Action Accept , related & stablished

Dest 172.16.0.26, Prot TCP, Action Accept , Port 25, related & stablished

 

 

Everything else I needed (http,ftp,etc forwarding to other internal LAN IPs and other WAN addresses) I could get to work except those above.

 

I am also fairly new to Edgemax and don't have CLI experience with it beyond some of the basic Linux commands.

 

 

I've done a lot of research everywhere on the web, including here, but nothing has helped get beyond this issue.
If possible, could someone post a good tutorial tackling these issues using the GUI? I am not as comfortable using the CLI...

 

Could you please help me with this problem? Thanks in advance!Icon Biggrin


Viewing all articles
Browse latest Browse all 20028

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>