Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Trying to setup ASA5505. Semi working but having issues with accessing services from the outside.

ASA5505 Basic License, Version 8.2. (plus upgrade to unlimited inside hosts).

Alert: I'm a Cisco Noob.

10.10.39.X is a place holder for privacy. (EDIT: to be less confusing)

I came up with this config and tested it tonight.

ASA Version 8.2(1)
!
hostname <removed>
domain-name <removed>
enable password <removed> encrypted
passwd <removed> encrypted
names
!
interface Vlan1
 nameif inside
 security-level 100
 ip address 172.21.36.1 255.255.252.0
!
interface Vlan2
 nameif outside
 security-level 0
 ip address 10.10.39.10 255.255.255.248
!
interface Ethernet0/0
 switchport access vlan 2
!
interface Ethernet0/1
!
interface Ethernet0/2
!
interface Ethernet0/3
!
interface Ethernet0/4
!
interface Ethernet0/5
!
interface Ethernet0/6
!
interface Ethernet0/7
!
ftp mode passive
dns server-group DefaultDNS
 domain-name <removed>
access-list outside_inbound extended permit tcp any host 10.10.39.10 eq pptp
access-list outside_inbound extended permit tcp any host 10.10.39.11 eq https
access-list outside_inbound extended permit tcp any host 10.10.39.11 eq 993
access-list outside_inbound extended permit tcp any host 10.10.39.11 eq smtp
access-list outside_inbound extended permit tcp any host 10.10.39.11 eq 1001
access-list outside_inbound extended permit tcp any host 10.10.39.11 eq 465
access-list outside_inbound extended permit tcp any host 10.10.39.11 eq domain
access-list outside_inbound extended permit udp any eq domain host 10.10.39.11 eq domain
access-list outside_inbound extended permit tcp any host 10.10.39.12 eq www
access-list outside_inbound extended permit tcp any host 10.10.39.12 eq https
access-list outside_inbound extended permit tcp any host 10.10.39.13 eq www
access-list outside_inbound extended permit tcp any host 10.10.39.13 eq https
access-list outside_inbound extended permit icmp any any echo-reply
access-list outside_inbound extended permit icmp any any source-quench
access-list outside_inbound extended permit icmp any any unreachable
access-list outside_inbound extended permit icmp any any time-exceeded
access-list outside_inbound extended permit icmp any any traceroute
access-list outside_inbound extended permit icmp any any echo
pager lines 24
logging asdm informational
mtu inside 1500
mtu outside 1500
icmp unreachable rate-limit 1 burst-size 1
no asdm history enable
arp timeout 14400
global (outside) 2 10.10.39.11-10.10.39.14 netmask 255.255.255.248
global (outside) 1 interface
nat (inside) 1 0.0.0.0 0.0.0.0
static (inside,outside) tcp interface pptp 172.21.37.20 pptp netmask 255.255.255.255
static (inside,outside) 10.10.39.11 172.21.37.14 netmask 255.255.255.255
static (inside,outside) 10.10.39.12 172.21.37.24 netmask 255.255.255.255
static (inside,outside) 10.10.39.13 172.21.37.17 netmask 255.255.255.255
access-group outside_inbound in interface outside
route outside 0.0.0.0 0.0.0.0 10.10.39.9 1
route inside 192.168.15.0 255.255.255.0 172.21.36.52 1
timeout xlate 3:00:00
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
dynamic-access-policy-record DfltAccessPolicy
http server enable
http 172.21.36.0 255.255.252.0 inside
no snmp-server location
no snmp-server contact
snmp-server enable traps snmp authentication linkup linkdown coldstart
crypto ipsec security-association lifetime seconds 28800
crypto ipsec security-association lifetime kilobytes 4608000
telnet 172.21.36.0 255.255.252.0 inside
telnet timeout 60
ssh timeout 5
console timeout 0
threat-detection basic-threat
threat-detection statistics access-list
no threat-detection statistics tcp-intercept
webvpn
!
class-map inspection_default
 match default-inspection-traffic
!
!
policy-map type inspect dns preset_dns_map
 parameters
  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 sqlnet
  inspect skinny
  inspect sunrpc
  inspect xdmcp
  inspect sip
  inspect netbios
  inspect tftp
  inspect pptp
  inspect ipsec-pass-thru
  inspect http
!
service-policy global_policy global
prompt hostname context

The servers that had static forwards did not have any outside network access. couldn't ping google.com for instance. mail server couldn't Domain POP the Barracuda spam filter from our ISP etc.

So after doing some reading I removed the statics for 10.10.39.11, 12 and 13, and replaced those three with what's below.. (Edit: corrected IPs in this statment.)

static (inside,outside) tcp 10.10.39.11 https 172.21.37.14 https netmask 255.255.255.255
static (inside,outside) tcp 10.10.39.11 993 172.21.37.14 993 netmask 255.255.255.255
static (inside,outside) tcp 10.10.39.11 smtp 172.21.37.14 smtp netmask 255.255.255.255
static (inside,outside) tcp 10.10.39.11 1001 172.21.37.14 1001 netmask 255.255.255.255
static (inside,outside) tcp 10.10.39.11 465 172.21.37.14 465 netmask 255.255.255.255
static (inside,outside) tcp 10.10.39.11 domain 172.21.37.14 domain netmask 255.255.255.255
static (inside,outside) tcp 10.10.39.12 www 172.21.37.24 www netmask 255.255.255.255
static (inside,outside) tcp 10.10.39.12 https 172.21.37.24 https netmask 255.255.255.255
static (inside,outside) tcp 10.10.39.13 www 172.21.37.17 www netmask 255.255.255.255
static (inside,outside) tcp 10.10.39.13 https 172.21.37.17 https netmask 255.255.255.255

Now the servers (for instance 172.21.37.14) could ping the outside world again. Mail started flowing (Domain POP was successful) etc. etc. But I forgot to check if webmail worked from the outside admittedly.

But the webservers at 172.21.37.17 and 172.21.37.24 still didn't respond from the outside world. Although I was able to PPTP VPN in on 10.10.39.10 (interface) which is the outside interface IP address. and it is static mapped to 172.21.37.20.

So I'm thinking there must be something wrong with NAT somewhere? no response from 10.10.39.11 to 10.10.39.14..

Could anyone look over the config and please let me know what I've done wrong? Is there something I've missed? well obviously but.. please help! Thank you.

share|improve this question
    
You were closer with your first attempt, I think. You want to NAT the whole IP, and control protocols with access rules. Not just NAT certain protocols. Or so I'd do anyway. Long night, too much beer, so that's all I got for you right now, but I would recommend using the ASDM GUI to configure your NAT and firewall rules. The ASA CLI, is much more... unwieldy and difficult than it need be, and this is coming from someone who usually scoffs at anyone using a GUI over a CLI. –  HopelessN00b Dec 15 '12 at 9:30
    
I find the GUI more confusing than CLI to be honest.. But perhaps I'll do a Wizard Run to setup the NAT?! Then go back to the CLI to finish up. –  GriffJ Dec 15 '12 at 9:40
add comment

1 Answer

(your example IP address scheme is confusing... don't do that!)

Use the Cisco ASDM GUI wizard walkthrough to set up basic PAT rules. I'd also recommend a move to the ASA 8.3 or 8.4 software (and corresponding ASDM) that was probably included in the packaging. I think it makes setting static NAT entries much easier, as it can be done on a host-by-host level in one dialog.

share|improve this answer
    
I inherited this network and the hardware had been sitting on a shelf for a year or more before I arrived at this job. I don't have Cisco service agreement so I can't upgrade the iOS. I thought PAT was for only having 1 outside IP. I have a /29 from my ISP which from what I've read you use NAT !? My outside IP range is lets say. 10.10.39.8 to 10.10.39.15 Netmask 255.255.255.248. .8 and .15 are broadcast, .9 is taken my the ISP's router. that leaves me .10 .11 .12 .13 .14 to use. the ASA is at 10.10.39.10 (Outside Interface). and the rest are used to access web/vpn/mail servers. –  GriffJ Dec 15 '12 at 19:42
    
Please use the GUI Setup Wizard. The PAT is to provide the source address for traffic that DOES NOT have a static NAT entry. –  ewwhite Dec 15 '12 at 20:01
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.