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. If you'd prefer to explore, try our test area to get started. And see here for current known issues.

New Member

another blooming NAT question

So the scenario is that we have an exchange server with one leg on the Inside interface (my DMZ) and I want to NAT that to one of my public range of addresses.  These are nnn.nn.n.232/29.  The ISP has .233, the ASA outside interface is .234 and I want to use .235 as the static NAT to xxx.xx.199.10 (out inside DMZ network).

 

I have put the following config on:


ASA Version 9.1(1) 
!
hostname MAIN-ASA
domain-name nnnnnnn.lllll
enable password jjjjjjjjjj
names
dns-guard
!
interface GigabitEthernet0/0
 speed 100
 duplex full
 nameif outside
 security-level 50
 ip address nnn.nn.5.234 255.255.255.248 
!
interface GigabitEthernet0/1
 nameif inside
 security-level 50
 ip address xxx.xx.199.1 255.255.255.0 
!
!
interface Management0/0
 management-only

              
 nameif management
 security-level 100
 ip address xxx.xx.140.223 255.255.255.0 
!
boot system disk0:/asa911-smp-k8.bin
ftp mode passive
dns domain-lookup outside
dns server-group DefaultDNS
 name-server 8.8.8.8
 domain-name jjjjjjjjj.lllllll
same-security-traffic permit inter-interface
same-security-traffic permit intra-interface
object network servers
 subnet yyy.yyy.0.0 255.255.255.0
object network IT-PC
 host yyy.yyy.1.22
 description IT dept PC
 host xxx.xx.199.128
object network Exchange-NAT
 host nnn.nn.5.235

              
 description Outside exchange NAT
object network Exchange-internal-NAT
 host xxx.xx.199.11
 description Inside Exchange NAT
object-group network users
 network-object yyy.yyy.1.0 255.255.255.0
object-group network DM_INLINE_NETWORK_1
 network-object xxx.xx.199.0 255.255.255.0
 network-object object servers
object-group network DM_INLINE_NETWORK_3
 network-object object Exchange-NAT
 network-object object Exchange-internal-NAT
object-group service DM_INLINE_TCP_1 tcp
 port-object eq https
 port-object eq smtp
 port-object eq echo
object-group network exchange-external
 network-object 
 network-object 
 network-object 
 object-group network DM_INLINE_NETWORK_4
 network-object object Exchange-NAT
 network-object object Exchange-internal-NAT
object-group service DM_INLINE_TCP_2 tcp
 port-object eq https
 port-object eq smtp
access-list inside_access_in extended permit ip object-group DM_INLINE_NETWORK_1 any log debugging 
access-list inside_access_in extended permit ip object IT-PC any log debugging 
access-list outside_access_in extended permit tcp any object-group DM_INLINE_NETWORK_3 object-group DM_INLINE_TCP_1 log debugging 
access-list outside_access_in extended permit tcp object-group exchange-external object-group DM_INLINE_NETWORK_4 object-group DM_INLINE_TCP_2 log debugging 
pager lines 24
logging enable
logging asdm informational
mtu outside 1500
mtu inside 1500
mtu management 1500
no failover
icmp unreachable rate-limit 1 burst-size 1

              
icmp permit any outside
icmp permit any inside
asdm image disk0:/asdm-66114.bin
no asdm history enable
arp timeout 14400
no arp permit-nonconnected
nat (outside,any) source static any any destination static Exchange-NAT Exchange-internal-NAT
nat (inside,outside) source dynamic any interface
access-group outside_access_in in interface outside
access-group inside_access_in in interface inside
route outside 0.0.0.0 0.0.0.0 nnn.nn.5.233 1
route inside yyy.yyy.0.0 255.255.255.0 xxx.xx.199.254 1
route inside yyy.yyy.1.0 255.255.255.0 xxx.xx.199.254 1
timeout xlate 3:00:00
timeout pat-xlate 0:00:30
timeout conn 1:00:00 half-closed 0:10:00 udp 0:02:00 icmp 0:00:02
timeout sunrpc 0:10:00 h323 0:05:00 h225 1:00:00 mgcp 0:05:00 mgcp-pat 0:05:00
timeout sip 0:30:00 sip_media 0:02:00 sip-invite 0:03:00 sip-disconnect 0:02:00
timeout sip-provisional-media 0:02:00 uauth 0:05:00 absolute
timeout tcp-proxy-reassembly 0:01:00
timeout floating-conn 0:00:00
dynamic-access-policy-record DfltAccessPolicy
user-identity default-domain LOCAL
aaa authentication ssh console LOCAL 

              
http server enable
http xxx.xx.1.0 255.255.255.0 management
http xxx.xx.140.0 255.255.255.0 management
no snmp-server location
no snmp-server contact
snmp-server enable traps snmp authentication linkup linkdown coldstart warmstart
sysopt noproxyarp inside
sysopt noproxyarp management
crypto ipsec security-association pmtu-aging infinite
crypto ca trustpool policy
telnet xxx.xx.140.0 255.255.255.0 management
telnet timeout 5
ssh xxx.xx.140.0 255.255.255.0 management
ssh timeout 5
console timeout 0
management-access management
vpdn group SRH-Group request dialout pppoe
vpdn group SRH-Group localname zen258800@zen
vpdn group SRH-Group ppp authentication chap
threat-detection basic-threat
threat-detection statistics access-list
no threat-detection statistics tcp-intercept
username admin password e8gq2.ujS/CECBVS encrypted
!

              
class-map inspection_default
 match default-inspection-traffic
!
!
policy-map type inspect dns preset_dns_map
 parameters
  message-length maximum client auto
  message-length maximum 512
policy-map global_policy
 class inspection_default
  inspect dns preset_dns_map 
  inspect ftp 
  inspect h323 h225 
  inspect h323 ras 
  inspect rsh 
  inspect rtsp 
  inspect esmtp 
  inspect sqlnet 
  inspect skinny  
  inspect sunrpc 
  inspect xdmcp 
  inspect sip  
  inspect netbios 
  inspect tftp 

              
  inspect ip-options 
!
service-policy global_policy global
prompt hostname context 
no call-home reporting anonymous
Cryptochecksum:2005faa8a0512f111117f8a6cb654888
: end

 

I can't seem to get it working even though the packet tracer says it should work.  Here is the "sh xlate" output.

MAIN-ASA# sh xlate
6 in use, 200 most used
Flags: D - DNS, e - extended, I - identity, i - dynamic, r - portmap,
       s - static, T - twice, N - net-to-net
NAT from outside:0.0.0.0/0 to any:0.0.0.0/0
    flags sIT idle 0:11:24 timeout 0:00:00
NAT from any:192.168.199.11 to outside:194.12.5.235
    flags sT idle 0:11:24 timeout 0:00:00
NAT from outside:0.0.0.0/0 to inside:0.0.0.0/0
    flags sIT idle 0:55:57 timeout 0:00:00
TCP PAT from inside:yyy.yyy.0.215/63102 to outside:nn.nn.5.234/63102 flags ri idle 0:54:45 timeout 0:00:30
UDP PAT from inside:yyy.yyy.0.40/6881 to outside:nn.nn.5.234/6881 flags ri idle 0:00:01 timeout 0:00:30
TCP PAT from inside:yyy.yyy.0.95/50020 to outside:nn.nn.5.234/50020 flags ri idle 0:00:48 timeout 0:00:30

 

any ideas really really appreciated.

 

Tim

 

4 REPLIES
Hall of Fame Super Blue

TimDo you just want to

Tim

Do you just want to present your internal address as a public IP to the outside ?

If so -

object network <name>

host <private IP>

nat (inside,outside) static <public IP>

Jon

New Member

Thanks for looking Jon,

Thanks for looking Jon,  actually, I built it using ASDM (I know, call myself an engineer) and I just set up a static NAT from an address on the inside interface to an address in the range that the ISP assigned to us.  The outside (public) address is not pingable but I changed my outside interface to the address I want to NAT just to see if it was a routing issue and then I can ping the public address from the WWW.  I had to change it back to allow outgoing access from my other users (they PAT to the interface address (.234) and that side all works.

 

Do I need to NAT to a physical interface address? I thought I could just create a network object and NAT to that?

 

Tim

Hall of Fame Super Blue

TimDo I need to NAT to a

Tim

Do I need to NAT to a physical interface address? I thought I could just create a network object and NAT to that?

No, you should be able to use an IP from the public range that is not actually assigned to the interface.

When you changed to the interface i suspect you were actually just pinging the outside interface ie. not the actual server.

You have acls applied to both the inside and outside interfaces. So you need to -

1) allow ICMP to the real IP in the acl applied to the outside interface

and

2) you can either -

a) allow the ICMP replies in your inside acl

or

b) turn on ICMP inspection. Note ICMP inspection generally is done for returning packets from a ping that was started from the inside but i suspect it should also work the other way as well.

Jon

 

New Member

Thanks John, I won't be able

Thanks John,

 

I won't be able to look at this until Thursday now as I am at another customer for the next few days,  I have turn on ICMP via ASDL so assume it should work.  I did notice on my "sh xlate" results this.....

"NAT from outside:0.0.0.0/0 to any:0.0.0.0/0
    flags sIT idle 0:11:24 timeout 0:00:00"

though I don't remember adding that rule, I wonder if this is masking my rule?

 

Plan of attack for Thursday is to remove my rule and start again as an outbound rule but with the "both ways" enabled.

 

Tim

102
Views
0
Helpful
4
Replies