cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
6431
Views
10
Helpful
12
Replies

ASA 8.4 Port forward problem

mross1572
Level 1
Level 1

Im trying to forward an outside public port of 60080 to an inside host port of 80 to an IP camera.

I am having no luck.

I removed the forward from the ASA config but i will paste my current config along with the commands i ran.

Any ideas?

commands i ran;

object network IP_Cam
   host 192.168.72.217
   nat (inside,outside) static interface service tcp 80 60080

access-list ipcam-in extended permit tcp any host 192.168.72.217 eq 60080 log

access-group ipcam-in in interface outside

My current config;

: Saved
:
ASA Version 8.4(2)
!
hostname MDR-ASA
domain-name MDR.LOCAL
enable password 2KFQnbNIdI.2KYOU encrypted
passwd 2KFQnbNIdI.2KYOU encrypted
names
!
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
!
interface Vlan1
nameif inside
security-level 100
ip address 192.168.72.1 255.255.255.0
!
interface Vlan2
nameif outside
security-level 0
ip address dhcp setroute
!
interface Vlan5
no nameif
security-level 50
ip address 192.168.73.1 255.255.255.128
!
boot system disk0:/asa842-k8.bin
ftp mode passive
clock timezone EST -5
clock summer-time EDT recurring
dns domain-lookup inside
dns server-group DefaultDNS
name-server 192.168.254.223
name-server 192.168.254.5
name-server 208.67.222.222
name-server 8.8.8.8
domain-name MDR.LOCAL
object network obj-192.168.72.0
subnet 192.168.72.0 255.255.255.0
object network obj_any
subnet 0.0.0.0 0.0.0.0
object-group network DM_INLINE_NETWORK_1
network-object 10.1.1.0 255.255.255.0
network-object 192.168.254.0 255.255.255.0
access-list outside_1_cryptomap extended permit ip 192.168.72.0 255.255.255.0 object-group DM_INLINE_NETWORK_1
access-list inside_nat0_outbound extended permit ip 192.168.72.0 255.255.255.0 object-group DM_INLINE_NETWORK_1
pager lines 24
logging enable
logging asdm informational
mtu inside 1500
mtu outside 1500
icmp unreachable rate-limit 1 burst-size 1
asdm image disk0:/asdm-645-106.bin
no asdm history enable
arp timeout 14400
nat (inside,any) source static obj-192.168.72.0 obj-192.168.72.0 destination static DM_INLINE_NETWORK_1 DM_INLINE_NETWORK_1 no-proxy-arp
!
object network obj_any
nat (inside,outside) dynamic interface
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
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 192.168.72.0 255.255.255.0 inside
http 208.40.72.160 255.255.255.240 outside
http 108.66.125.224 255.255.255.255 outside
no snmp-server location
no snmp-server contact
snmp-server enable traps snmp authentication linkup linkdown coldstart
crypto ipsec ikev1 transform-set ESP-AES-128-SHA esp-aes esp-sha-hmac
crypto ipsec ikev1 transform-set ESP-AES-128-MD5 esp-aes esp-md5-hmac
crypto ipsec ikev1 transform-set ESP-AES-192-SHA esp-aes-192 esp-sha-hmac
crypto ipsec ikev1 transform-set ESP-AES-192-MD5 esp-aes-192 esp-md5-hmac
crypto ipsec ikev1 transform-set ESP-AES-256-SHA esp-aes-256 esp-sha-hmac
crypto ipsec ikev1 transform-set ESP-AES-256-MD5 esp-aes-256 esp-md5-hmac
crypto ipsec ikev1 transform-set ESP-3DES-MD5 esp-3des esp-md5-hmac
crypto ipsec ikev1 transform-set ESP-DES-SHA esp-des esp-sha-hmac
crypto ipsec ikev1 transform-set ESP-DES-MD5 esp-des esp-md5-hmac
crypto ipsec ikev1 transform-set ESP-3DES-SHA esp-3des esp-sha-hmac
crypto map outside_map 1 match address outside_1_cryptomap
crypto map outside_map 1 set pfs
crypto map outside_map 1 set peer 208.40.72.162
crypto map outside_map 1 set ikev1 transform-set ESP-3DES-SHA
crypto map outside_map 1 set reverse-route
crypto map outside_map interface outside
crypto ca trustpoint _SmartCallHome_ServerCA
crl configure
crypto ca certificate chain _SmartCallHome_ServerCA
certificate ca 6ecc7aa5a7032009b8cebcf4e952d491
    308205ec 308204d4 a0030201 0202106e cc7aa5a7 032009b8 cebcf4e9 52d49130
    0d06092a 864886f7 0d010105 05003081 ca310b30 09060355 04061302 55533117
    30150603 55040a13 0e566572 69536967 6e2c2049 6e632e31 1f301d06 0355040b
    13165665 72695369 676e2054 72757374 204e6574 776f726b 313a3038 06035504
    0b133128 63292032 30303620 56657269 5369676e 2c20496e 632e202d 20466f72
    20617574 686f7269 7a656420 75736520 6f6e6c79 31453043 06035504 03133c56
    65726953 69676e20 436c6173 73203320 5075626c 69632050 72696d61 72792043
    65727469 66696361 74696f6e 20417574 686f7269 7479202d 20473530 1e170d31
    30303230 38303030 3030305a 170d3230 30323037 32333539 35395a30 81b5310b
    30090603 55040613 02555331 17301506 0355040a 130e5665 72695369 676e2c20
    496e632e 311f301d 06035504 0b131656 65726953 69676e20 54727573 74204e65
    74776f72 6b313b30 39060355 040b1332 5465726d 73206f66 20757365 20617420
    68747470 733a2f2f 7777772e 76657269 7369676e 2e636f6d 2f727061 20286329
    3130312f 302d0603 55040313 26566572 69536967 6e20436c 61737320 33205365
    63757265 20536572 76657220 4341202d 20473330 82012230 0d06092a 864886f7
    0d010101 05000382 010f0030 82010a02 82010100 b187841f c20c45f5 bcab2597
    a7ada23e 9cbaf6c1 39b88bca c2ac56c6 e5bb658e 444f4dce 6fed094a d4af4e10
    9c688b2e 957b899b 13cae234 34c1f35b f3497b62 83488174 d188786c 0253f9bc
    7f432657 5833833b 330a17b0 d04e9124 ad867d64 12dc744a 34a11d0a ea961d0b
    15fca34b 3bce6388 d0f82d0c 948610ca b69a3dca eb379c00 48358629 5078e845
    63cd1941 4ff595ec 7b98d4c4 71b350be 28b38fa0 b9539cf5 ca2c23a9 fd1406e8
    18b49ae8 3c6e81fd e4cd3536 b351d369 ec12ba56 6e6f9b57 c58b14e7 0ec79ced
    4a546ac9 4dc5bf11 b1ae1c67 81cb4455 33997f24 9b3f5345 7f861af3 3cfa6d7f
    81f5b84a d3f58537 1cb5a6d0 09e4187b 384efa0f 02030100 01a38201 df308201
    db303406 082b0601 05050701 01042830 26302406 082b0601 05050730 01861868
    7474703a 2f2f6f63 73702e76 65726973 69676e2e 636f6d30 12060355 1d130101
    ff040830 060101ff 02010030 70060355 1d200469 30673065 060b6086 480186f8
    45010717 03305630 2806082b 06010505 07020116 1c687474 70733a2f 2f777777
    2e766572 69736967 6e2e636f 6d2f6370 73302a06 082b0601 05050702 02301e1a
    1c687474 70733a2f 2f777777 2e766572 69736967 6e2e636f 6d2f7270 61303406
    03551d1f 042d302b 3029a027 a0258623 68747470 3a2f2f63 726c2e76 65726973
    69676e2e 636f6d2f 70636133 2d67352e 63726c30 0e060355 1d0f0101 ff040403
    02010630 6d06082b 06010505 07010c04 61305fa1 5da05b30 59305730 55160969
    6d616765 2f676966 3021301f 30070605 2b0e0302 1a04148f e5d31a86 ac8d8e6b
    c3cf806a d448182c 7b192e30 25162368 7474703a 2f2f6c6f 676f2e76 65726973
    69676e2e 636f6d2f 76736c6f 676f2e67 69663028 0603551d 11042130 1fa41d30
    1b311930 17060355 04031310 56657269 5369676e 4d504b49 2d322d36 301d0603
    551d0e04 1604140d 445c1653 44c1827e 1d20ab25 f40163d8 be79a530 1f060355
    1d230418 30168014 7fd365a7 c2ddecbb f03009f3 4339fa02 af333133 300d0609
    2a864886 f70d0101 05050003 82010100 0c8324ef ddc30cd9 589cfe36 b6eb8a80
    4bd1a3f7 9df3cc53 ef829ea3 a1e697c1 589d756c e01d1b4c fad1c12d 05c0ea6e
    b2227055 d9203340 3307c265 83fa8f43 379bea0e 9a6c70ee f69c803b d937f47a
    6decd018 7d494aca 99c71928 a2bed877 24f78526 866d8705 404167d1 273aeddc
    481d22cd 0b0b8bbc f4b17bfd b499a8e9 762ae11a 2d876e74 d388dd1e 22c6df16
    b62b8214 0a945cf2 50ecafce ff62370d ad65d306 4153ed02 14c8b558 28a1ace0
    5becb37f 954afb03 c8ad26db e6667812 4ad99f42 fbe198e6 42839b8f 8f6724e8
    6119b5dd cdb50b26 058ec36e c4c875b8 46cfe218 065ea9ae a8819a47 16de0c28
    6c2527b9 deb78458 c61f381e a4c4cb66
  quit
crypto ikev1 enable outside
crypto ikev1 policy 10
authentication crack
encryption aes-256
hash sha
group 2
lifetime 86400
crypto ikev1 policy 20
authentication rsa-sig
encryption aes-256
hash sha
group 2
lifetime 86400
crypto ikev1 policy 30
authentication pre-share
encryption aes-256
hash sha
group 2
lifetime 86400
crypto ikev1 policy 40
authentication crack
encryption aes-192
hash sha
group 2
lifetime 86400
crypto ikev1 policy 50
authentication rsa-sig
encryption aes-192
hash sha
group 2
lifetime 86400
crypto ikev1 policy 60
authentication pre-share
encryption aes-192
hash sha
group 2
lifetime 86400
crypto ikev1 policy 70
authentication crack
encryption aes
hash sha
group 2
lifetime 86400
crypto ikev1 policy 80
authentication rsa-sig
encryption aes
hash sha
group 2
lifetime 86400
crypto ikev1 policy 90
authentication pre-share
encryption aes
hash sha
group 2
lifetime 86400
crypto ikev1 policy 100
authentication crack
encryption 3des
hash sha
group 2
lifetime 86400
crypto ikev1 policy 110
authentication rsa-sig
encryption 3des
hash sha
group 2
lifetime 86400
crypto ikev1 policy 120
authentication pre-share
encryption 3des
hash sha
group 2
lifetime 86400
crypto ikev1 policy 130
authentication crack
encryption des
hash sha
group 2
lifetime 86400
crypto ikev1 policy 140
authentication rsa-sig
encryption des
hash sha
group 2
lifetime 86400
crypto ikev1 policy 150
authentication pre-share
encryption des
hash sha
group 2
lifetime 86400
telnet timeout 5
ssh 192.168.72.0 255.255.255.0 inside
ssh 208.40.72.160 255.255.255.240 outside
ssh 108.66.125.224 255.255.255.255 outside
ssh timeout 60
console timeout 0

dhcpd option 66 ip 192.168.254.162
!
dhcpd address 192.168.72.100-192.168.72.130 inside
dhcpd dns 192.168.254.223 208.67.220.220 interface inside
dhcpd domain netdyninc.com interface inside
dhcpd auto_config outside vpnclient-wins-override interface inside
dhcpd update dns both override interface inside
dhcpd option 66 ip 208.40.72.164 interface inside
dhcpd enable inside
!
threat-detection basic-threat
threat-detection statistics access-list
no threat-detection statistics tcp-intercept
ntp server 38.117.195.101 source outside prefer
webvpn
username mross password 1toqI9xS.gj2m19O encrypted privilege 15
tunnel-group 208.40.72.162 type ipsec-l2l
tunnel-group 208.40.72.162 ipsec-attributes
ikev1 pre-shared-key *****
!
!
prompt hostname context
call-home reporting anonymous
call-home
profile CiscoTAC-1
  no active
  destination address http https://tools.cisco.com/its/service/oddce/services/DDCEService
  destination address email callhome@cisco.com
  destination transport-method http
  subscribe-to-alert-group diagnostic
  subscribe-to-alert-group environment
  subscribe-to-alert-group inventory periodic monthly
  subscribe-to-alert-group configuration periodic monthly
  subscribe-to-alert-group telemetry periodic daily
Cryptochecksum:d77bb3f7ba2eb7b5e9e2cfc8573d1b1b
: end

1 Accepted Solution

Accepted Solutions

Hi,

Try this:

object network IP_Cam

   host 192.168.72.217

object service tcp_80

service tcp destination eq 80

object service tcp_60080

service tcp destination eq 60080

nat (oustide,inside) source static any any destination static interface IP_Cam service tcp_60080 tcp_80

access-list outside_access_in permit tcp any host 192.168.72.217

access-group outside_access_in in interface outside

This should work

Thanks,

Varun

Thanks,
Varun Rao

View solution in original post

12 Replies 12

smsneteng
Level 1
Level 1

nat (inside,outside) static interface service tcp 80 60080

Replace "interface" with "IP_Cam"

-Tim

Just did that and i am still not getting through the firewall.

Is there a debug i could run to see why i am getting blocked?

I'm an idiot, nvm.

It may be that the PAM database already knows that 80=http, so you may either need to update the PAM to use 60080 as well, or just specify http instead of 80...

You could set up a capture...I would build a new acl for the capture instead of using the existing one, since it is applied to an interface...first, enable logging @level 7 to the buffer

logging en

logg buff deb

access-list ext test-cam permit tcp any host 192.168.72.217

capture ip-cam access-l test-cam int in

then after a few attempts, do a sh cap ip-cam and sh logg | incl 192.168.72.217

Kinda new to 8.4...huge difference from 7.x/8.0 lol

this is the results

%ASA-7-710005: TCP request discarded from 198.228.227.207/46729 to outside:75.118.152.114/60080

%ASA-7-710005: TCP request discarded from 198.228.227.207/46729 to outside:75.118.152.114/60080

%ASA-7-710005: TCP request discarded from 198.228.227.207/46729 to outside:75.118.152.114/60080

%ASA-7-710005: TCP request discarded from 198.228.227.207/46729 to outside:75.118.152.114/60080

%ASA-7-710005: TCP request discarded from 198.228.227.207/46729 to outside:75.118.152.114/60080

%ASA-7-710005: TCP request discarded from 198.228.227.207/46729 to outside:75.118.152.114/60080

%ASA-7-710005: TCP request discarded from 198.228.227.207/55903 to outside:75.118.152.114/60080

%ASA-7-710005: TCP request discarded from 198.228.227.207/46729 to outside:75.118.152.114/60080

%ASA-7-710005: TCP request discarded from 198.228.227.207/46729 to outside:75.118.152.114/60080

%ASA-7-710005: TCP request discarded from 198.228.227.207/46729 to outside:75.118.152.114/60080

%ASA-7-710005: TCP request discarded from 198.228.227.207/46729 to outside:75.118.152.114/60080

%ASA-7-710005: TCP request discarded from 198.228.227.207/46729 to outside:75.118.152.114/60080

%ASA-7-710005: TCP request discarded from 198.228.227.207/46729 to outside:75.118.152.114/60080

%ASA-7-710005: TCP request discarded from 198.228.227.207/55903 to outside:75.118.152.114/60080

This whole port-mapping thing...so much easier and non-cryptic in IOS...lol

Oh wait---maybe you have to add that host to the"http outside" list

I'll bet that's it...

http outside 198.228.227.207

OR

no http server enable

and enable https instead for ASDM---I'd never allow http for ASDM inside or ESPECIALLY outside myself, but...

anyway, try that, or turn http off for ASDM management and turn on https instead...or, update PAM...or, use the "http" keyword instead of using the port number in the static PAT statement.

Hehe, i cant win, failure on that trial as well.

this was so much easier in 8.2.

might be time to open a TAC case.

Hi just a suggestion to test for those that have reached a dead end.

My ASA version is 9.0(3), and i was trying to put together a static nat rule to allow me to RDP to an internal server Real ip = 10.0.32.15 from any ip coming from the Internet.

I've spent days troubleshooting and testing different pat commands without success , no matter what i was receiving packets dropped left right and center when trying to rdp in to to my internal server via my pat rule.

dropped logs looked like this

%ASA-7-710005: TCP request discarded from.......

The solution for me was to move my static pat rules to the first position and the dynamic pat Hide rules after them.

 you can do this easily within the asdm interface attached picture.

The final pat rule that is currently in place in my configuration is described below

!
object network rdp-hskpc

! This is my internal host private ip aka Real IP and is the one i would like to remote in to from the outside
 host 10.0.32.15
! Patting the host on port 3389 RDP port
nat (inside,outside) static interface service tcp 3389 3389

!Allowing the Real ip in my outside interface via ACL
access-list Outside_access_in extended permit tcp any host 10.0.32.15 eq 3389
access-group Outside_access_in in interface outside

Link to Nat rule order article below

http://www.cisco.com/c/en/us/td/docs/security/asa/asa90/configuration/guide/asa_90_cli_config/nat_overview.html#31590

smsneteng
Level 1
Level 1

One more thing---on the acl, don't specify the port, because I remember that some IOSs in routers treat that as incoming and outgoing (in a router, I would need to specify the port in both source and dest statements...

access-list 121 permit tcp any gt 1023 host x.x.x.x eq 60080

to allow any port outside of the well known ports inbound.

Do you have any other acls inbound? The other sh run doesn't show any...does everything else work?

No i just built this asa, the only thing it does is NAT and has a site to site tunnel.

Which i can get to the IP camera fine from its inside address over the tunnel, but i have no luck getting it to work in 8.4.

Hi,

Try this:

object network IP_Cam

   host 192.168.72.217

object service tcp_80

service tcp destination eq 80

object service tcp_60080

service tcp destination eq 60080

nat (oustide,inside) source static any any destination static interface IP_Cam service tcp_60080 tcp_80

access-list outside_access_in permit tcp any host 192.168.72.217

access-group outside_access_in in interface outside

This should work

Thanks,

Varun

Thanks,
Varun Rao

Thank you, this was the answer and is working perfectly.

soldnermichael
Level 1
Level 1

This is the first I've seen of this problem, but even after building the NAT with the interface rather than an IP I still am getting constant TCP discards...

Review Cisco Networking products for a $25 gift card