hwgtech
asked on
Cisco ASA 5505 Config Open Ports / Forwarding
I have a new ASA 5505 and I'm not a Cisco guy - I have everything working now, but for some reason I have a feeling I've opened up the entire network. I need Telnet access externally to forward to internal IP - 192.168.22.90. Can someone tell me I am crazy and didn't open everything up and if I did - how I need to change the config to NOT have the entire network vulnerable?
ASA Version 7.2(4)
!
hostname HOSTNAME
domain-name DOMAIN.LOCAL
enable password PASSWORD encrypted
passwd 2KFQnbNIdI.2KYOU encrypted
names
!
interface Vlan1
nameif inside
security-level 100
ip address 192.168.22.113 255.255.255.0
!
interface Vlan2
nameif outside
security-level 0
ip address 74.143.137.107 255.255.255.248
!
interface Vlan3
no forward interface Vlan1
nameif dmz
security-level 50
ip address dhcp
!
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 walnutridge.local
same-security-traffic permit inter-interface
same-security-traffic permit intra-interface
access-list outside_access_in extended permit tcp any interface outside eq telnet
access-list outside_1_cryptomap extended permit ip 192.168.22.0 255.255.255.0 192.168.23.0 255.255.255.0
access-list inside_nat0_outbound extended permit ip 192.168.22.0 255.255.255.0 192.168.23.0 255.255.255.0
access-list outside_access_in_1 extended permit tcp any host 192.168.22.90 eq telnet
access-list outside_access_in_1 extended permit ip any 74.143.137.104 255.255.255.248
pager lines 24
logging enable
logging asdm informational
mtu outside 1500
mtu inside 1500
mtu dmz 1500
icmp unreachable rate-limit 1 burst-size 1
asdm image disk0:/asdm-524.bin
no asdm history enable
arp timeout 14400
global (outside) 1 interface
nat (inside) 0 access-list inside_nat0_outbound
nat (inside) 1 0.0.0.0 0.0.0.0
static (inside,outside) tcp interface telnet 192.168.22.90 telnet netmask 255.255.255.255
access-group outside_access_in_1 in interface outside
route outside 0.0.0.0 0.0.0.0 74.143.137.105 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
http server enable
http 192.168.22.0 255.255.255.0 inside
no snmp-server location
no snmp-server contact
snmp-server enable traps snmp authentication linkup linkdown coldstart
crypto ipsec 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 group1
crypto map outside_map 1 set peer 72.151.39.36
crypto map outside_map 1 set transform-set ESP-3DES-SHA
crypto map outside_map interface outside
crypto isakmp enable outside
crypto isakmp policy 10
authentication pre-share
encryption 3des
hash sha
group 2
lifetime 86400
telnet timeout 5
ssh timeout 5
console timeout 0
dhcpd auto_config outside
!
dhcpd address 192.168.22.200-192.168.22. 250 inside
dhcpd dns 74.128.17.114 interface inside
dhcpd wins 74.128.19.102 interface inside
dhcpd enable inside
!
group-policy DfltGrpPolicy attributes
banner none
wins-server none
dns-server none
dhcp-network-scope none
vpn-access-hours none
vpn-simultaneous-logins 3
vpn-idle-timeout none
vpn-session-timeout none
vpn-filter none
vpn-tunnel-protocol IPSec l2tp-ipsec webvpn
password-storage disable
ip-comp disable
re-xauth disable
group-lock none
pfs disable
ipsec-udp disable
ipsec-udp-port 10000
split-tunnel-policy tunnelall
split-tunnel-network-list none
default-domain none
split-dns none
intercept-dhcp 255.255.255.255 disable
secure-unit-authentication disable
user-authentication disable
user-authentication-idle-t imeout 30
ip-phone-bypass disable
leap-bypass disable
nem disable
backup-servers keep-client-config
msie-proxy server none
msie-proxy method no-modify
msie-proxy except-list none
msie-proxy local-bypass disable
nac disable
nac-sq-period 300
nac-reval-period 36000
nac-default-acl none
address-pools none
smartcard-removal-disconne ct enable
client-firewall none
client-access-rule none
webvpn
functions url-entry
html-content-filter none
homepage none
keep-alive-ignore 4
http-comp gzip
filter none
url-list none
customization value DfltCustomization
port-forward none
port-forward-name value Application Access
sso-server none
deny-message value Login was successful, but because certain criteria have not been met or due to some specific group policy, you do not have permission to use any of the VPN features. Contact your IT administrator for more information
svc none
svc keep-installer installed
svc keepalive none
svc rekey time none
svc rekey method none
svc dpd-interval client none
svc dpd-interval gateway none
svc compression deflate
tunnel-group 72.151.39.36 type ipsec-l2l
tunnel-group 72.151.39.36 ipsec-attributes
pre-shared-key *
!
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 esmtp
inspect sqlnet
inspect skinny
inspect sunrpc
inspect xdmcp
inspect sip
inspect netbios
inspect tftp
!
service-policy global_policy global
ASA Version 7.2(4)
!
hostname HOSTNAME
domain-name DOMAIN.LOCAL
enable password PASSWORD encrypted
passwd 2KFQnbNIdI.2KYOU encrypted
names
!
interface Vlan1
nameif inside
security-level 100
ip address 192.168.22.113 255.255.255.0
!
interface Vlan2
nameif outside
security-level 0
ip address 74.143.137.107 255.255.255.248
!
interface Vlan3
no forward interface Vlan1
nameif dmz
security-level 50
ip address dhcp
!
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 walnutridge.local
same-security-traffic permit inter-interface
same-security-traffic permit intra-interface
access-list outside_access_in extended permit tcp any interface outside eq telnet
access-list outside_1_cryptomap extended permit ip 192.168.22.0 255.255.255.0 192.168.23.0 255.255.255.0
access-list inside_nat0_outbound extended permit ip 192.168.22.0 255.255.255.0 192.168.23.0 255.255.255.0
access-list outside_access_in_1 extended permit tcp any host 192.168.22.90 eq telnet
access-list outside_access_in_1 extended permit ip any 74.143.137.104 255.255.255.248
pager lines 24
logging enable
logging asdm informational
mtu outside 1500
mtu inside 1500
mtu dmz 1500
icmp unreachable rate-limit 1 burst-size 1
asdm image disk0:/asdm-524.bin
no asdm history enable
arp timeout 14400
global (outside) 1 interface
nat (inside) 0 access-list inside_nat0_outbound
nat (inside) 1 0.0.0.0 0.0.0.0
static (inside,outside) tcp interface telnet 192.168.22.90 telnet netmask 255.255.255.255
access-group outside_access_in_1 in interface outside
route outside 0.0.0.0 0.0.0.0 74.143.137.105 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
http server enable
http 192.168.22.0 255.255.255.0 inside
no snmp-server location
no snmp-server contact
snmp-server enable traps snmp authentication linkup linkdown coldstart
crypto ipsec 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 group1
crypto map outside_map 1 set peer 72.151.39.36
crypto map outside_map 1 set transform-set ESP-3DES-SHA
crypto map outside_map interface outside
crypto isakmp enable outside
crypto isakmp policy 10
authentication pre-share
encryption 3des
hash sha
group 2
lifetime 86400
telnet timeout 5
ssh timeout 5
console timeout 0
dhcpd auto_config outside
!
dhcpd address 192.168.22.200-192.168.22.
dhcpd dns 74.128.17.114 interface inside
dhcpd wins 74.128.19.102 interface inside
dhcpd enable inside
!
group-policy DfltGrpPolicy attributes
banner none
wins-server none
dns-server none
dhcp-network-scope none
vpn-access-hours none
vpn-simultaneous-logins 3
vpn-idle-timeout none
vpn-session-timeout none
vpn-filter none
vpn-tunnel-protocol IPSec l2tp-ipsec webvpn
password-storage disable
ip-comp disable
re-xauth disable
group-lock none
pfs disable
ipsec-udp disable
ipsec-udp-port 10000
split-tunnel-policy tunnelall
split-tunnel-network-list none
default-domain none
split-dns none
intercept-dhcp 255.255.255.255 disable
secure-unit-authentication
user-authentication disable
user-authentication-idle-t
ip-phone-bypass disable
leap-bypass disable
nem disable
backup-servers keep-client-config
msie-proxy server none
msie-proxy method no-modify
msie-proxy except-list none
msie-proxy local-bypass disable
nac disable
nac-sq-period 300
nac-reval-period 36000
nac-default-acl none
address-pools none
smartcard-removal-disconne
client-firewall none
client-access-rule none
webvpn
functions url-entry
html-content-filter none
homepage none
keep-alive-ignore 4
http-comp gzip
filter none
url-list none
customization value DfltCustomization
port-forward none
port-forward-name value Application Access
sso-server none
deny-message value Login was successful, but because certain criteria have not been met or due to some specific group policy, you do not have permission to use any of the VPN features. Contact your IT administrator for more information
svc none
svc keep-installer installed
svc keepalive none
svc rekey time none
svc rekey method none
svc dpd-interval client none
svc dpd-interval gateway none
svc compression deflate
tunnel-group 72.151.39.36 type ipsec-l2l
tunnel-group 72.151.39.36 ipsec-attributes
pre-shared-key *
!
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 esmtp
inspect sqlnet
inspect skinny
inspect sunrpc
inspect xdmcp
inspect sip
inspect netbios
inspect tftp
!
service-policy global_policy global
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
MightySW, what is the problem with this command?
static (inside,outside) tcp interface telnet 192.168.22.90 telnet netmask 255.255.255.255
It is doing static PAT for outside telnet traffic destined to the outside interface, being forwarded to the telnet-port of the 192.168-address. In this command the first "telnet" occurrance is not the name of the interface but the port. Like this:
static (inside,outside) tcp interface 23 192.168.22.90 23 netmask 255.255.255.255
The interface-name is not specified after the interface-keyword because it is already within the parentesis. Have a look at the syntax in command reference and you will se.
/Kvistofta
static (inside,outside) tcp interface telnet 192.168.22.90 telnet netmask 255.255.255.255
It is doing static PAT for outside telnet traffic destined to the outside interface, being forwarded to the telnet-port of the 192.168-address. In this command the first "telnet" occurrance is not the name of the interface but the port. Like this:
static (inside,outside) tcp interface 23 192.168.22.90 23 netmask 255.255.255.255
The interface-name is not specified after the interface-keyword because it is already within the parentesis. Have a look at the syntax in command reference and you will se.
/Kvistofta
Sorry about that. I misread that statement totally. YES, I was being silly and...wow! LOL, thanks for calling me on that K. Yes, there is nothing wrong with that statement, other than the fact that you probably don't want to use it externally , but syntacticaly correct. Seriously sorry about that.
No problem, it could happen to anyone. ;)
hwqtech: are your questions answered, or are there anything else we can do?
/Kvistofta
hwqtech: are your questions answered, or are there anything else we can do?
/Kvistofta
ASKER
Thank you both very much. Makes perfect sense. I knew there was something off. Telnet is for a terminal emulator application to our unix application.
conf t
no access-list outside_access_in_1 extended permit tcp any host 192.168.22.90 eq telnet
and remove the other the same way, as you are allowing EVERYTHING to hit the external host of 74.143.137.104. I do not see that host declare anywhere, so I am assuming that it is a static address that you assigned to something outside of your network, like a webserver or a router.
I see that you also have the following statement, which I don't even see how it works or what it is for:
static (inside,outside) tcp interface telnet 192.168.22.90 telnet netmask 255.255.255.255
Static's are used for one to one mappings (IDEALLY) for single host to host translations. The syntax for a static nat is (source int, dest int) mapped_ip, real_ip netmask xxx.xxx.xxx.xxx. Of course you can use it differently, but I don't even see an named interface of 'telnet'
If you need to get into a device on your network, then you would need to create an ACL that just permits a single IP address on the outside interface through to the inside interface over SSH.
Follow this link on how to configure SSH on an external interface:
https://www9.cisco.com/en/US/products/hw/vpndevc/ps2030/products_configuration_example09186a008069bf1b.shtml#c1
and just use local authentication.
When you use telnet, you are sending your username and password in plain, clear text. SOOO EASY to see and to hack. If you dare using telnet to an external interface then expect to be breached. When you use SSH it will be encrypted. You can get to the device by using a ssh client like putty.
HTH