1

Let say an ISP gives me 12.12.12.0/28, and I have an internal network of 10.10.10.0/24. If I run a webserver on say 12.12.12.1 and have that statically mapped to 10.10.10.12, is there any problem with also making 12.12.12.1 my nat overload IP for general outgoing traffic that originates from anywhere in the 10.10.10.0/24 network on Cisco IOS?

Logically it seems like it should work fine, but I have never tried it.

Kyle Brandt
  • 83,619
  • 74
  • 305
  • 448

2 Answers2

3

Yeah, This is referred to in Cisco documentation as Static Nat Translations with Overload. Its certainly one of the most common configurations with residential NAT.

I'd suggest doing the standard assignment of inside/outside interfaces

ip nat pool IPPOOL 12.12.12.1 12.12.12.14 netmask 255.255.255.240
ip access-list standard NAT_POOL
permit 10.10.10.0 0.0.0.255
ip nat inside source list NAT_POOL pool IPPOOL overload
ip nat inside source static tcp 10.10.10.12 80 interface X/X 80

I should point out that this configuration has no guarantee in using a specific IP, but you could easily just narrow the pool and adjust the source-static rule appropriately

zetavolt
  • 1,352
  • 1
  • 8
  • 12
1

That's perfectly fine... and also quite usual, when you only have a single public IP address and still want something to be accessible from outside your LAN.

I'm actually doing it on my home router (Cisco 877) at this very same moment :-)

Massimo
  • 70,200
  • 57
  • 200
  • 323