Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. And see here for current known issues.

New Member

NAT without DMZ

Hi,

here is a sample config:

interface FastEthernet0

ip address 1.1.1.2 255.255.255.252

ip nat outside

ip virtual-reassembly

duplex auto

speed auto

no cdp enable

!

interface Vlan1

ip address 10.0.1.2 255.255.255.0

ip nat inside

ip virtual-reassembly

!

ip classless

ip route 0.0.0.0 0.0.0.0 1.1.1.1

!

!

ip nat inside source list 120 interface FastEthernet0 overload

ip nat inside source static tcp 10.0.1.33 80 interface FastEthernet0 80

!

!

access-list 120 permit ip 10.0.1.0 0.0.0.255 any

!

end

and now, what is my problem:

a PC in the internal network would like to communicate with 1.1.1.2:80 (a 1.1.1.2 is the response from DNS server).

It is solvable by ip nat outside command? Are anybody have any idea? I don't want to configure DMZ.

THX for ideas...

1 ACCEPTED SOLUTION

Accepted Solutions
Silver

Re: NAT without DMZ

Solution 3:

------------------

access-list 55 permit host 1.1.1.2

route-map HTTPredirect permit 10

match ip address 55

set ip next-hop 10.0.1.33

int vlan1

ip policy route-map HTTPredirect in

------------------

This would point the traffic towards the HTTP server's MAC address, but you still need to configure it to listen on 1.1.1.2's IP address (which may or may not be possible on the servers OS)

As for solution 2: DNS is out of my expertise, so we'd need someone else to help out with that.

7 REPLIES
Blue

Re: NAT without DMZ

your DNS is configured incorrectly if you ping a DNS name and it responds with 1.1.1.2. (unless this is what you want to happen)

1.1.1.2 is the routers ethernet interface and will not respond to http (80) requests. (do you have http server configured where you can access the router via http at the 1.1.1.2:80 address/port?)

since this ethernet interface is 1.1.1.2/30 then the only other host that can reside on that subnet is 1.1.1.1/30.

your question may not be clear as i'm not sure where you are worried about a DMZ..???

what is the "internal network" where the PC resides? if it is on the 10.0.1.0/24 network, then NO nat will not be needed.

New Member

Re: NAT without DMZ

The PC is a notebook.

When the notebook is in the another network (another internet access), all works fine. The user clicks on a desktop shortcut, and open a website at 1.1.1.2:80 (address is translated to internal web server 10.0.1.33:80).

but

if the notebook is in a local network (10.0.1.0/24) and user clicks on the same shortcut (same dns name, same ip address 1.1.1.2:80), the user can't establishe a connection, because the router could not translate an address - because the connection come from NAT inside interface!!!

Exists any solution?

New Member

Re: NAT without DMZ

Maybe help some DNS translating on the router... like an ip nat outside...

pls advise me some solution

Silver

Re: NAT without DMZ

The problem here is in the design. The static NAT entry you configured will only translate traffic coming in the outside interface. There isn't any feature (that I know of) that will let you hair-pin the connection from the internal network, through the router, and translated back into the internal network.

Some workarounds I can think of:

1. Make a different hyperlink for internal users to click

2. Get creative with DNS (resolve the IP differently for internal users than external users)

3. Somehow configure the HTTP server to use 1.1.1.2 as an alias. Cisco routers have this feature, where they can respond to requests destined for another IP. (You'd need to pair this with PBR on the router, so packets get forwarded back out the FA interface to servers MAC address...might be more trouble than its worth)

New Member

Re: NAT without DMZ

THX a lot...

do you have any examples for solution 3?

and what about solution 2? I saw some tutorials, where router modifies the DNS reply for internal ip address... but not for routers (only PIX) :o((

Silver

Re: NAT without DMZ

Solution 3:

------------------

access-list 55 permit host 1.1.1.2

route-map HTTPredirect permit 10

match ip address 55

set ip next-hop 10.0.1.33

int vlan1

ip policy route-map HTTPredirect in

------------------

This would point the traffic towards the HTTP server's MAC address, but you still need to configure it to listen on 1.1.1.2's IP address (which may or may not be possible on the servers OS)

As for solution 2: DNS is out of my expertise, so we'd need someone else to help out with that.

New Member

Re: NAT without DMZ

Ok, thx a lot. The solution with DNS is seems to be a best.

bye

582
Views
4
Helpful
7
Replies
CreatePlease login to create content