SSL VPNs are often deployed to allow access to a company's intranet, Microsoft SharePoint, or web mail. The SSL VPN enables users to connect from a handheld device (smartphone or PDA), a public Internet cafe, or a corporate laptop. Users within these environments usually are just opening calendar, editing a document or reading email within a web page.
When preparing to deploy a basic clientless SSL VPN, a few key items must be completed (in order) before you can test the access and move on to providing for advanced features:
Step 1 - IP addressing: It is important to know the IP addressing plan for the site on which you are installing the ASA because you need and IP address for the external interface (the one closest to VPN clients and terminating SSL VPN sessions).
Step 2 - Configure a hostname, domain name, and Domain Name System (DNS): Before publishing the relevant SSL VPN URLs to users, you configure your ASA with a hostname and a domain name. You also enter the addresses of any internal and external DNS servers to allow user access to any bookmarks or external URLs they browse to using your SSL VPN.
Step 3 - Enroll with a CA and become a member of a PKI: Because users will be accessing the device externally over an SSL connection, a device certificate is required for successful authentication of the ASA. Another option is to use a locally generated self-signed certificate.
Step 4 - Enable relevant interfaces for SSL VPN access: Before SSL VPN access can occur, you need to specify which interface the service will be available on.
Step 5 - Create LOCAL user accounts: Because this is a basic SSL VPN, you use LOCAL authentication for user access. Doing so requires that you to create the user accounts on the ASA device.
Step 6: Create a Connection Profile (optional but recommended so that the DefaultWEBVPNGroup is not used): In this step, create a new connection profile and map it to users through group policies or user attributes. A connection profile is used for prelogin settings such as authentication method, DNS servers and domain name, and portal customization.
ciscoasa(config)# hostname MY-ASA-FW // CONFIGURE HOSTNAME AND DNS FOR CA CERTIFICATE
MY-ASA-FW(config)# domain-name local.com
MY-ASA-FW(config)# dns domain-lookup inside
MY-ASA-FW(config)# dns domain-lookup outside
MY-ASA-FW(config)# dns name-server 8.8.8.8
MY-ASA-FW(config)# dns server-group MY-DNS-GRP
MY-ASA-FW(config-dns-server-group)# name-server 8.8.8.8
MY-ASA-FW(config)# crypto key generate rsa label SSLVPN // MANUALLY CREATE SELF-SIGNED CERTIFICATE
INFO: The name for the keys will be: SSLVPN
Keypair generation process begin. Please wait...
MY-ASA-FW(config)# crypto ca trustpoint ?
configure mode commands/options:
WORD < 65 char Trustpoint Name
MY-ASA-FW(config)# crypto ca trustpoint TPLOCAL
MY-ASA-FW(config-ca-trustpoint)# ?
crypto ca trustpoint configuration commands:
accept-subordinates Accept subordinate CA certificates
client-types Specifies the client connection types for which this
trustpoint can be used to validate the certificates
associated with a user connection
crl CRL options
default Return all enrollment parameters to their default
values
email Email Address
enrollment Enrollment parameters
exit Exit from certificate authority trustpoint entry mode
fqdn include fully-qualified domain name
help Help for crypto ca trustpoint configuration commands
id-cert-issuer Accept ID certificates
id-usage Specifies how the device identity represented by this
trustpoint can be used
ignore-ipsec-keyusage Suppress Key Usage checking on IPSec client
certificates
ignore-ssl-keyusage Suppress Key Usage checking on SSL client certificates
ip-address include ip address
keypair Specify the key pair whose public key is to be
certified
match Match a certificate map
no Negate a command or set its defaults
ocsp OCSP parameters
password revocation password
proxy-ldc-issuer An issuer for TLS proxy local dynamic certificates
revocation-check Revocation checking options
serial-number include serial number
subject-name Subject Name
MY-ASA-FW(config-ca-trustpoint)# enrollment ?
crypto-ca-trustpoint mode commands/options:
retry Polling parameters
self Enrollment will generate a self-signed certificate
terminal Enroll via the terminal (cut-and-paste)
url CA server enrollment URL
MY-ASA-FW(config-ca-trustpoint)# enrollment self
MY-ASA-FW(config-ca-trustpoint)# exit
MY-ASA-FW(config)# crypto ca ?
configure mode commands/options:
authenticate Get the CA certificate
certificate Actions on certificates
crl Actions on certificate revocation lists
enroll Request a certificate from a CA
export Export a trustpoint configuration with all associated keys and
certificates in PKCS12 format, or export the identity
certificate in PEM format
import Import certificate or pkcs-12 data
server Define Local Certificate Server
trustpoint Define a CA trustpoint
exec mode commands/options:
server Local Certificate Server commands
MY-ASA-FW(config)# crypto ca enroll ?
configure mode commands/options:
WORD < 65 char Trustpoint Name
MY-ASA-FW(config)# crypto ca enroll TPLOCAL
% The fully-qualified domain name in the certificate will be: MY-ASA-FW.local.com
% Include the device serial number in the subject name? [yes/no]: no
Generate Self-Signed Certificate? [yes/no]: yes
MY-ASA-FW(config)# ssl ?
configure mode commands/options:
certificate-authentication Enable client certificate authentication
client-version The SSL/TLS protocol version to use when acting
as a client
encryption This is the encryption method(s) used with ssl.
The ordering of the algorithms specifies the
preference.
server-version The SSL/TLS protocol version to use when acting
as a server
trust-point Configure the ssl certificate trustpoint
MY-ASA-FW(config)# ssl trust-point ?
configure mode commands/options:
Available configured trustpoints:
TPLOCAL
MY-ASA-FW(config)# ssl trust-point TPLOCAL ?
configure mode commands/options:
An entry without the interface being specified represents the
fallback trustpoint which will be used on all interfaces not
associated with a trustpoint of their own.
Available interfaces for the trust point / SSL certificate association:
inside Name of interface GigabitEthernet1
outside Name of interface GigabitEthernet0
<cr>
MY-ASA-FW(config)# ssl trust-point TPLOCAL outside
MY-ASA-FW(config)# webvpn
MY-ASA-FW(config-webvpn)# ?
WebVPN commands:
anyconnect AnyConnect configuration parameters
anyconnect-essentials Enable/Disable AnyConnect Essentials
apcf Load Aplication Profile Customization Framework
(APCF) profile
auto-signon Configure auto-sign to allow login to certain
applications using the WebVPN session credentials
cache Configure WebVPN cache
certificate-group-map Associate a tunnel-group with a certificate map rule
character-encoding Configures the character encoding for WebVPN portal
pages
csd This specifies whether Cisco Secure Desktop is
enabled and the package file name to be used.
default-idle-timeout This is the default idle timeout in seconds
default-language Default language to use
dtls Configure DTLS for WebVPN
enable Enable WebVPN on the specified interface
error-recovery Contact TAC before using this command
exit Exit from WebVPN configuration mode
file-encoding Configures the file encoding for a file sharing
server
help Help for WebVPN commands
http-proxy This is the proxy server to use for HTTP requests
https-proxy This is the proxy server to use for HTTPS requests
internal-password Adds an option to input a different password for
accessing internal servers
java-trustpoint Configure WebVPN java trustpoint
kcd-server Configure an KCD-Server
keepout Shows Web page when the login is disabled
memory-size Configure WebVPN memory size. CHECK MEMORY USAGE
BEFORE APPLYING THIS COMMAND. USE ONLY IF ADVISED BY
CISCO
mobile-device Configure access from mobile devices
mus Configure Mobile User Security
no Remove a WebVPN command or set to its default
onscreen-keyboard Adds WebVPN onscreen keyboard for typing password on
the WebVPN logon page and internal pages requiring
authentication
port WebVPN should listen for connections on the
specified port
port-forward Configure the port-forward list for WebVPN
portal-access-rule Configuration related to portal access rules
proxy-bypass Configure proxy bypass
rewrite Configure content rewriting rule
smart-tunnel Configure a list of programs to use smart tunnel
sso-server Configure an SSO Server
tunnel-group-list Configure WebVPN group list dropdown in login page
tunnel-group-preference Enable/Disable Tunnel Group Preference
MY-ASA-FW(config-webvpn)# enable ?
webvpn mode commands/options:
Current available interface(s):
inside Name of interface GigabitEthernet1
outside Name of interface GigabitEthernet0
configure mode commands/options:
password Configure password for the enable command
MY-ASA-FW(config-webvpn)# enable outside // ENABLE SSL VPN ON THE OUTSIDE INTERFACE
INFO: WebVPN and DTLS are enabled on 'outside'.
MY-ASA-FW(config)# group-policy ?
configure mode commands/options:
WORD < 65 char Enter the name of the group policy
MY-ASA-FW(config)# group-policy Sales ?
configure mode commands/options:
external Enter this keyword to specify an external group policy
internal Enter this keyword to specify an internal group policy
MY-ASA-FW(config)# group-policy Sales internal // CONFIGURE GROUP POLICY
MY-ASA-FW(config)# group-policy Engineering internal
MY-ASA-FW(config-group-policy)# ?
group_policy configuration commands:
address-pools Configure list of up to 6 address pools to
assign addresses from
backup-servers Configure list of backup servers to be used
by the remote client
banner Configure a banner, or welcome text to be
displayed on the VPN remote client
client-access-rule Specify rules permitting/denying access to
specific client types and versions.
client-firewall Configure the firewall requirements for
users in this group-policy
default-domain Configure default domain name given to
users of this group
dhcp-network-scope Specify the range of IP addresses to
indicate to the DHCP server for address
assignment
dns-server Configure the primary and secondary DNS
servers
exit Exit from group-policy configuration mode
group-lock Enter name of an existing tunnel-group that
users are required to connect with
help Help for group_policy configuration
commands
intercept-dhcp Enable this command to use group policy for
clients requesting Microsoft DHCP
ip-comp Enter this command to enable IP compression
(LZS)
ip-phone-bypass Configure to allow Cisco IP phones behind
Hardware clients to bypass the Individual
User Authentication process.
ipsec-udp Enter this command to allow a client to
operate through a NAT device using UDP
encapsulation
ipsec-udp-port Enter the UDP port to be used by the client
for IPSec through NAT
ipv6-address-pools Configure list of up to 6 ipv6 address
pools to assign addresses from
ipv6-vpn-filter Enter name of a configured IPv6 ACL to
apply to users
leap-bypass Enable/disable LEAP packets from Cisco
wireless devices to bypass the individual
user authentication process. This setting
applies only to HW clients.
msie-proxy Enter this command to configure MSIE
Browser Proxy settings for a client system
nac-settings Configured the name of the nac-policy
nem Configure hardware clients to use network
extension mode. This setting applies only
to HW clients.
no Remove an attribute value pair
password-storage Enable/disable storage of the login
password on the client system
pfs Enter this command to indicate that the
remote client needs to perform PFS
re-xauth Enter this command to enable
reauthentication of the user on IKE rekey
scep-forwarding-url Configure CA SCEP URL to forward the SCEP
messages.
secure-unit-authentication Configure interactive authentication. This
setting applies only to HW clients.
smartcard-removal-disconnect Configure client action for smart card
removal
split-dns Configure list of domains to be resolved
through the Split Tunnel
split-tunnel-all-dns Select the option to indicate how the
client should handle DNS queries when
split-tunneling is enabled
split-tunnel-network-list Configure name of access-list for split
tunnel configuration
split-tunnel-policy Select the split tunneling method to be
used by the remote client
user-authentication Configure individual user authentication.
This setting applies only to HW clients.
user-authentication-idle-timeout Configure the idle timeout period in
minutes. If there is no communication in
this period, the system terminates the
connection. This setting applies only to HW
clients.
vlan Specify the VLAN onto which VPN traffic for
this group will be forwarded.
vpn-access-hours Enter name of a configured time-range
policy
vpn-filter Enter name of a configured ACL to apply to
users
vpn-idle-timeout Enter idle timeout period in minutes, enter
none to disable
vpn-session-timeout Enter maximum user connection time in
minutes, enter none for unlimited time
vpn-simultaneous-logins Enter maximum number of simultaneous logins
allowed
vpn-tunnel-protocol Enter permitted tunneling protocols
webvpn Configure group policy for WebVPN
wins-server Configure the primary and secondary WINS
servers
MY-ASA-FW(config-group-policy)# vpn-tunnel-protocol ?
username mode commands/options:
ikev1 IKEv1
ikev2 IKEv2
l2tp-ipsec L2TP using IPSec for security
ssl-client SSL VPN Client
ssl-clientless SSL Clientless VPN
MY-ASA-FW(config-group-policy)# vpn-tunnel-protocol ssl-clientless
MY-ASA-FW(config)# username John password cisco // CREATE LOCAL USER
MY-ASA-FW(config)# username John ?
configure mode commands/options:
attributes Enter the attributes sub-command mode for the specified user
nopassword Indicates that this user has no password
password The password for this user
MY-ASA-FW(config)# username John attributes
MY-ASA-FW(config-username)# ?
username configuration commands:
exit Exit from username attribute configuration mode
group-lock Enter name of an existing tunnel-group that the user
is required to connect with
help Help for username configuration commands
ipv6-vpn-filter Enter name of user specific ACL
memberof Enter a comma separated list of group-names that
this user is a member of.
no Remove an attribute value pair
password-storage Enable/disable storage of the login password on the
client system
service-type Select service type for this user.
vpn-access-hours Enter name of a configured time-range policy
vpn-filter Enter name of user specific ACL
vpn-framed-ip-address Enter the IP address and the net mask to be assigned
to the client
vpn-group-policy Enter name of a group-policy to inherit attributes
from
vpn-idle-timeout Enter idle timeout period in minutes, enter none to
disable
vpn-session-timeout Enter maximum user connection time in minutes, enter
none for unlimited time
vpn-simultaneous-logins Enter maximum number of simultaneous logins allowed
vpn-tunnel-protocol Enter permitted tunneling protocols
webvpn Configure user policy for WebVPN
MY-ASA-FW(config-username)# vpn-group-policy ?
username mode commands/options:
WORD Name of a group-policy to inherit attributes from
MY-ASA-FW(config-username)# vpn-group-policy Engineering // APPLY A GROUP POLICY
MY-ASA-FW(config)# tunnel-group ?
configure mode commands/options:
WORD < 65 char Enter the name of the tunnel group
MY-ASA-FW(config)# tunnel-group Engineering ?
configure mode commands/options:
general-attributes Enter the general-attributes sub command mode
ipsec-attributes Enter the ipsec-attributes sub command mode
ppp-attributes Enter the ppp-attributes sub command mode
webvpn-attributes Enter the webvpn-attributes sub command mode
MY-ASA-FW(config)# tunnel-group Engineering general-attributes // CONFIGURE CONNECTION PROFILE
MY-ASA-FW(config-tunnel-general)# ?
tunnel-group configuration commands:
accounting-server-group Enter name of the accounting server
group
address-pool Enter a list of address pools to
assign addresses from
annotation Specify annotation text - to be used
by ASDM only
authenticated-session-username Specify the authenticated username
will be associated with the session
authentication-attr-from-server Specify the authentication server that
provides authorization attribute for
the session
authentication-server-group Enter name of the authentication
server group
authorization-required Require users to authorize
successfully in order to connect
authorization-server-group Enter name of the authorization server
group
default-group-policy Enter name of the default group policy
dhcp-server Enter IP address or name of the DHCP
server
exit Exit from tunnel-group general
attribute configuration mode
help Help for tunnel group configuration
commands
ipv6-address-pool Enter a list of IPv6 address pools to
assign addresses from
no Remove an attribute value pair
override-account-disable Override account disabled from AAA
server
password-management Enable password management
scep-enrollment Enable SCEP proxy enrollment
secondary-authentication-server-group Enter name of the secondary
authentication server group
secondary-username-from-certificate The DN of the peer certificate used as
secondary username for authorization
strip-group Enable strip-group processing
strip-realm Enable strip-realm processing
username-from-certificate The DN of the peer certificate used as
username for authorization and/or
authentication
MY-ASA-FW(config-tunnel-general)# default-group-policy ?
tunnel-group-general mode commands/options:
WORD < 65 char Name of the default group policy
MY-ASA-FW(config-tunnel-general)# default-group-policy Engineering
MY-ASA-FW(config-tunnel-general)# exit
MY-ASA-FW(config)# tunnel-group Engineering webvpn-attributes
MY-ASA-FW(config-tunnel-webvpn)# ?
tunnel-group configuration commands:
authentication This is the authentication method(s) used with
WebVPN
customization Specify a customization object
dns-group Enter DNS Group name
exit Exit from tunnel-group WebVPN attribute
configuration mode
group-alias Enter name of the Group Alias
group-url Enter Group URL
help Help for tunnel group configuration commands
nbns-server This is the NBNS (NetBIOS Name Service) server
for CIFS name resolution
no Remove an attribute value pair
override-svc-download Override downloading the SVC to the client
pre-fill-username Configure username to certificate binding on
this tunnel-group.
proxy-auth Flags this tunnel-group as a specific proxy
authen tunnel group.
radius-reject-message Enable the display of Radius Reject-Message on
the login screen when Authentication is Rejected
secondary-pre-fill-username Configure secondary username to certificate
binding on this tunnel-group.
without-csd Disable CSD for a tunnel group
MY-ASA-FW(config-tunnel-webvpn)# group-alias ?
tunnel-group-webvpn mode commands/options:
WORD < 32 char Name of the Group Alias. A maximum of 32 characters is
allowed.
MY-ASA-FW(config-tunnel-webvpn)# group-alias Engineering ?
tunnel-group-webvpn mode commands/options:
disable Enter this keyword to disable the alias
enable Enter this keyword to enable the alias
<cr>
MY-ASA-FW(config-tunnel-webvpn)# group-alias Engineering enable
ERROR: Group already exists
MY-ASA-FW(config-tunnel-webvpn)# group-url ?
tunnel-group-webvpn mode commands/options:
WORD Group URL (supported types: http:// or https://)
MY-ASA-FW(config-tunnel-webvpn)# group-url https://200.1.1.1/Enginering ?
tunnel-group-webvpn mode commands/options:
disable Enter this keyword to disable the url
enable Enter this keyword to enable the url
<cr>
MY-ASA-FW(config-tunnel-webvpn)# group-url https://200.1.1.1/Enginering enable
MY-ASA-FW# show vpn-sessiondb detail
---------------------------------------------------------------------------
VPN Session Summary
---------------------------------------------------------------------------
Active : Cumulative : Peak Concur : Inactive
----------------------------------------------
Clientless VPN : 1 : 1 : 1
Browser : 1 : 1 : 1
---------------------------------------------------------------------------
Total Active and Inactive : 1 Total Cumulative : 1
Device Total VPN Capacity : 0
Device Load : 0%
***!! WARNING: Platform capacity exceeded !!***
---------------------------------------------------------------------------
---------------------------------------------------------------------------
Tunnels Summary
---------------------------------------------------------------------------
Active : Cumulative : Peak Concurrent
----------------------------------------------
Clientless : 1 : 1 : 1
---------------------------------------------------------------------------
Totals : 1 : 1
---------------------------------------------------------------------------
MY-ASA-FW# show vpn-sessiondb detail webvpn
Session Type: WebVPN Detailed
Username : John Index : 1
Public IP : 200.1.1.2
Protocol : Clientless
License : AnyConnect Premium
Encryption : RC4 Hashing : SHA1
Bytes Tx : 9485 Bytes Rx : 16571
Pkts Tx : 5 Pkts Rx : 1
Pkts Tx Drop : 0 Pkts Rx Drop : 0
Group Policy : Engineering Tunnel Group : Engineering
Login Time : 21:42:47 UTC Mon Feb 17 2014
Duration : 0h:02m:44s
Inactivity : 0h:00m:00s
NAC Result : Unknown
VLAN Mapping : N/A VLAN : none
Clientless Tunnels: 1
Clientless:
Tunnel ID : 1.1
Public IP : 200.1.1.2
Encryption : RC4 Hashing : SHA1
Encapsulation: TLSv1.0 TCP Dst Port : 443
Auth Mode : userPassword
Idle Time Out: 30 Minutes Idle TO Left : 27 Minutes
Client Type : Web Browser
Client Ver : Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.1; Trident/6.0)
Bytes Tx : 9485 Bytes Rx : 16571
NAC:
Reval Int (T): 0 Seconds Reval Left(T): 0 Seconds
SQ Int (T) : 0 Seconds EoU Age(T) : 165 Seconds
Hold Left (T): 0 Seconds Posture Token:
Redirect URL :
Here are the screenshots on how to configure via ASDM:
Here's what the SSL VPN login page looks like. We can select the tunnel group or connection profile from a drop-down list.
We can also monitor and get more details of the SSL VPN client session in ASDM. We can also create a clientless SSL VPN using a VPN Wizard.
Saturday, March 1, 2014
Sunday, February 16, 2014
Starting My VPN (642-648)
I finally got my Cisco Firewall Security Specialist cert after finishing the FIREWALL (642-618) exam a couple of months ago. I noticed that Cisco Specialist cert is good for 2 years not unlike the 640-xxx Associate or 642-xxx Professional level certs, which are valid for 3 years.
I started studying for VPN (642-648) but also recently found out that Cisco revised their CCNP Security track and retiring the Security Specialist certs. So I got until April 2014 to finish VPN and get my ASA Specialist cert (combination of FIREWALL and VPN certs).
I put some screenshots taken from Cisco's website since the URL sometimes changes or becomes unavailable later on.
I was able to confirm with the folks from Cisco Learning Network (CLN) that my SECURE, FIREWALL, VPN and SITCS will qualify me to become CCNP Security certified. Here's the CCNP Security certification exam migration path.
I started studying for VPN (642-648) but also recently found out that Cisco revised their CCNP Security track and retiring the Security Specialist certs. So I got until April 2014 to finish VPN and get my ASA Specialist cert (combination of FIREWALL and VPN certs).
I put some screenshots taken from Cisco's website since the URL sometimes changes or becomes unavailable later on.
I was able to confirm with the folks from Cisco Learning Network (CLN) that my SECURE, FIREWALL, VPN and SITCS will qualify me to become CCNP Security certified. Here's the CCNP Security certification exam migration path.
Saturday, January 11, 2014
Using Packet Capture on an ASA
You can use the packet capture feature to collect a copy of packets as they enter and exit ASA interfaces. You can define one or more capture sessions on an ASA, each operating independently. Captured packets are stored in a memory buffer and can be viewed much like a protocol analyzer or sniffer trace. You can also copy the buffer contents onto an external device for viewing and analysis.
Begin by defining an access list that will be used to identify the traffic to be captured. You can set up a capture session that doesn't use an access list at all, but it will capture all traffic passing through. The access list is used to flag packets for capature and not to permit or deny them from passing through the interface. Therefore, only the permit keyword is useful here. An implicit deny statement is at the end of the access list, which causes all other traffic to pass without being captured.
ciscoasa(config)# access-list CAPTURE1 permit tcp any any eq https
ciscoasa(config)# exit
ciscoasa# capture SAMPLE access-list ?
WORD Access-list name
ciscoasa# capture SAMPLE access-list CAPTURE1 ?
buffer Configure size of capture buffer, default is 512 KB
circular-buffer Overwrite buffer from beginning when full, default is
non-circular
ethernet-type Capture Ethernet packets of a particular type, default is IP
headers-only Capture only L2, L3 and L4 headers of packet without data in
them
interface Capture packets on a specific interface
packet-length Configure maximum length to save from each packet, default
is 1518 bytes
real-time Display captured packets in real-time. Warning: using this
option with a slow console connection may result in an
excessive amount of non-displayed packets due to performance
limitations.
trace Trace the captured packets
<cr>
ciscoasa# capture SAMPLE access-list CAPTURE1 interface ?
asa_dataplane Capture packets on dataplane interface
cplane Capture packets on controlplane interface
Available interfaces to listen:
inside Name of interface GigabitEthernet0
outside Name of interface GigabitEthernet1
ciscoasa# capture SAMPLE access-list CAPTURE1 interface outside
ciscoasa# show capture
capture SAMPLE type raw-data interface outside [Capturing - 732 bytes]
ciscoasa# show capture SAMPLE
5 packets captured
1: 09:52:20.111612 802.3 encap packet
2: 09:53:18.806659 802.3 encap packet
3: 09:54:18.421044 802.3 encap packet
4: 09:54:32.083613 c200.1bb8.0000 ab00.0002.0000 0x6002 77:
3d00 0700 0000 0100 0303 0000 0200 0221
0003 0006 0000 0000 0000 0400 023c 0005
0002 d805 0600 0200 0107 0006 c200 1bb8
0000 6400 0179 9001 0101 9101 02ee 05
5: 09:55:19.448035 802.3 encap packet
5 packets shown
The Packet Capture Wizard sets up two separate capture sessions: one on an ingress interface and one on an egress interface. Each session captures traffic in both directions, collecting packets as they enter and exit the ASA.
To use the ASDM Packet Capture Wizard, choose Wizard > Packet Capture Wizard. A window describing the five steps of the wizard will appear. Click the Next button.
Sometimes you might find that viewing the contents of a capature buffer from a command line interface becomes too cumbersome or confusing. This can happen when the capture buffer becomes very large to navigate with CLI commands or display filters.
At other times, the capture buffer might contain useful information that deserves further review. For example, you might have a PC-based tool that can import captured data for viewing and analysis. You also might want to archive the capture buffer for future use.
ciscoasa# copy capture:SAMPLE flash:sample
Source capture name [SAMPLE]?
Destination filename [sample]?
!
12 packets copied in 0.10 secs
You can also use a web browser to display a capture buffer as if you had used the show capture command. You also can download the capture buffer in PCAP format and save it as a file - all without leaving your web browser and without needing a TFTP server running on your PC.
Begin by defining an access list that will be used to identify the traffic to be captured. You can set up a capture session that doesn't use an access list at all, but it will capture all traffic passing through. The access list is used to flag packets for capature and not to permit or deny them from passing through the interface. Therefore, only the permit keyword is useful here. An implicit deny statement is at the end of the access list, which causes all other traffic to pass without being captured.
ciscoasa(config)# access-list CAPTURE1 permit tcp any any eq https
ciscoasa(config)# exit
ciscoasa# capture SAMPLE access-list ?
WORD Access-list name
ciscoasa# capture SAMPLE access-list CAPTURE1 ?
buffer Configure size of capture buffer, default is 512 KB
circular-buffer Overwrite buffer from beginning when full, default is
non-circular
ethernet-type Capture Ethernet packets of a particular type, default is IP
headers-only Capture only L2, L3 and L4 headers of packet without data in
them
interface Capture packets on a specific interface
packet-length Configure maximum length to save from each packet, default
is 1518 bytes
real-time Display captured packets in real-time. Warning: using this
option with a slow console connection may result in an
excessive amount of non-displayed packets due to performance
limitations.
trace Trace the captured packets
<cr>
ciscoasa# capture SAMPLE access-list CAPTURE1 interface ?
asa_dataplane Capture packets on dataplane interface
cplane Capture packets on controlplane interface
Available interfaces to listen:
inside Name of interface GigabitEthernet0
outside Name of interface GigabitEthernet1
ciscoasa# capture SAMPLE access-list CAPTURE1 interface outside
ciscoasa# show capture
capture SAMPLE type raw-data interface outside [Capturing - 732 bytes]
ciscoasa# show capture SAMPLE
5 packets captured
1: 09:52:20.111612 802.3 encap packet
2: 09:53:18.806659 802.3 encap packet
3: 09:54:18.421044 802.3 encap packet
4: 09:54:32.083613 c200.1bb8.0000 ab00.0002.0000 0x6002 77:
3d00 0700 0000 0100 0303 0000 0200 0221
0003 0006 0000 0000 0000 0400 023c 0005
0002 d805 0600 0200 0107 0006 c200 1bb8
0000 6400 0179 9001 0101 9101 02ee 05
5: 09:55:19.448035 802.3 encap packet
5 packets shown
The Packet Capture Wizard sets up two separate capture sessions: one on an ingress interface and one on an egress interface. Each session captures traffic in both directions, collecting packets as they enter and exit the ASA.
To use the ASDM Packet Capture Wizard, choose Wizard > Packet Capture Wizard. A window describing the five steps of the wizard will appear. Click the Next button.
Sometimes you might find that viewing the contents of a capature buffer from a command line interface becomes too cumbersome or confusing. This can happen when the capture buffer becomes very large to navigate with CLI commands or display filters.
At other times, the capture buffer might contain useful information that deserves further review. For example, you might have a PC-based tool that can import captured data for viewing and analysis. You also might want to archive the capture buffer for future use.
ciscoasa# copy capture:SAMPLE flash:sample
Source capture name [SAMPLE]?
Destination filename [sample]?
!
12 packets copied in 0.10 secs
You can also use a web browser to display a capture buffer as if you had used the show capture command. You also can download the capture buffer in PCAP format and save it as a file - all without leaving your web browser and without needing a TFTP server running on your PC.
Saturday, December 28, 2013
Using Packet Tracer on an ASA
You can use the Packet Tracer feature to verify many of the ASA security mechanisms as a packet moves from one ASA interface to another. A typical series of security features tested might look like the following:
* Flow lookup: Checks for existing xlate and conn entries.
* UN-NAT: Checks for address translation entries.
* Access list lookup: Checks for any applicable ACL entries.
* IP options lookup: Checks handling of IP options in the ingress packet.
* NAT: Checks the Reverse Path Forwarding (RPF) information.
* NAT: Checks for host connection limits.
* IP options lookup: Checks handling of IP options in egress packet.
* Flow creation: Creates new xlate and conn entries, if needed.
* Route lookup: Checks for a router to the destination address.
Packet Tracer uses a virtual or synthetic packet that is injected into the data stream on an ingress interface. The virtual packet is passed through each of the ASA functions, as if a real packet were being handled. This means that you will even see actual syslog information being generated on the ASA as the tracer progresses. The ASA will remove the virtual packet once it is queued in the egress interface buffer for transmission so that it neve appears on the network.
You can use Packet Tracer from ASDM by selecting Tools > Packet Tracer.
A new Packet Tracer window will appear, containing a string of symbols representing each ASA function that will be tested. Enter the following information to define the test packet:
* Choose the ingress interface, where the packet will enter the firewall; at the upper-left corner of
the window, select an interface name from the drop-down menu.
* Select the Packet Type, either TCP, UDP, ICMP, or IP, from the list across the top of the window.
* Enter the Source IP Address and Source Port.
* Enter the Destination IP address and Destination Port.
Click the Start button. Packet Tracer will animate a packet as it moves from function to function. When the trace is complete, the results will be shown in the bottom half of the window. Be aware that the animation causes the step-by-step progression to appear rather slowly. You can speed up the trace by unchecking the Show Animation check box.
You can also use Packet Tracer from the command-line interface (CLI) by entering the following command:
ciscoasa# packet-tracer ?
input Ingress interface on which to trace packet
ciscoasa# packet-tracer input ?
Current available interface(s):
inside Name of interface GigabitEthernet0
outside Name of interface GigabitEthernet1
ciscoasa# packet-tracer input outside ?
icmp Enter this keyword if the trace packet is ICMP
rawip Enter this keyword if the trace packet is RAW IP
tcp Enter this keyword if the trace packet is TCP
udp Enter this keyword if the trace packet is UDP
ciscoasa# packet-tracer input outside tcp ?
A.B.C.D Enter the Source address if ipv4
X:X:X:X::X Enter the Source address if ipv6
fqdn Enter this keyword if an FQDN is specified as source address
user Enter this keyword if a user is specified as source address
ciscoasa# packet-tracer input outside tcp 8.8.8.8 ?
<0-65535> Enter port number (0 - 65535)
aol
bgp
chargen
cifs
citrix-ica
cmd
ctiqbe
daytime
discard
domain
echo
exec
finger
ftp
ftp-data
gopher
h323
hostname
http
https
ident
imap4
irc
ciscoasa# packet-tracer input outside tcp 8.8.8.8 12345 ?
A.B.C.D Enter the destination ipv4 address
fqdn Enter this keyword if an FQDN is specified as destination address
ciscoasa# packet-tracer input outside tcp 8.8.8.8 12345 192.168.1.50 ?
<0-65535> Enter port number (0 - 65535)
aol
bgp
chargen
cifs
citrix-ica
cmd
ctiqbe
daytime
discard
domain
echo
exec
finger
ftp
ftp-data
gopher
h323
hostname
http
https
ident
imap4
irc
ciscoasa# packet-tracer input outside tcp 8.8.8.8 12345 192.168.1.50 http ?
detailed Dump more detailed information
xml Output in xml format
<cr>
ciscoasa# packet-tracer input outside tcp 8.8.8.8 12345 192.168.1.50 http
Phase: 1
Type: ROUTE-LOOKUP
Subtype: input
Result: ALLOW
Config:
Additional Information:
in 192.168.1.0 255.255.255.0 inside
Phase: 2
Type: ACCESS-LIST
Subtype: log
Result: ALLOW
Config:
access-group outside_access_in in interface outside
access-list outside_access_in extended permit tcp any 192.168.1.0 255.255.255.0 eq www
Additional Information:
Phase: 3
Type: IP-OPTIONS
Subtype:
Result: ALLOW
Config:
Additional Information:
Phase: 4
Type: IP-OPTIONS
Subtype:
Result: ALLOW
Config:
Additional Information:
Phase: 5
Type: FLOW-CREATION
Subtype:
Result: ALLOW
Config:
Additional Information:
New flow created with id 100, packet dispatched to next module
Result:
input-interface: outside
input-status: up
input-line-status: up
output-interface: inside
output-status: up
output-line-status: up
Action: allow
* Flow lookup: Checks for existing xlate and conn entries.
* UN-NAT: Checks for address translation entries.
* Access list lookup: Checks for any applicable ACL entries.
* IP options lookup: Checks handling of IP options in the ingress packet.
* NAT: Checks the Reverse Path Forwarding (RPF) information.
* NAT: Checks for host connection limits.
* IP options lookup: Checks handling of IP options in egress packet.
* Flow creation: Creates new xlate and conn entries, if needed.
* Route lookup: Checks for a router to the destination address.
Packet Tracer uses a virtual or synthetic packet that is injected into the data stream on an ingress interface. The virtual packet is passed through each of the ASA functions, as if a real packet were being handled. This means that you will even see actual syslog information being generated on the ASA as the tracer progresses. The ASA will remove the virtual packet once it is queued in the egress interface buffer for transmission so that it neve appears on the network.
You can use Packet Tracer from ASDM by selecting Tools > Packet Tracer.
A new Packet Tracer window will appear, containing a string of symbols representing each ASA function that will be tested. Enter the following information to define the test packet:
* Choose the ingress interface, where the packet will enter the firewall; at the upper-left corner of
the window, select an interface name from the drop-down menu.
* Select the Packet Type, either TCP, UDP, ICMP, or IP, from the list across the top of the window.
* Enter the Source IP Address and Source Port.
* Enter the Destination IP address and Destination Port.
Click the Start button. Packet Tracer will animate a packet as it moves from function to function. When the trace is complete, the results will be shown in the bottom half of the window. Be aware that the animation causes the step-by-step progression to appear rather slowly. You can speed up the trace by unchecking the Show Animation check box.
Notice the virtual packet was denied or drop due to an implicit deny rule under the "global" access list. We correct it by adding a rule allowing HTTP traffic/TCP port 80 from the Internet (any) going towards the inside network 192.168.1.0/24 coming in from the outside interface.
You can also use Packet Tracer from the command-line interface (CLI) by entering the following command:
ciscoasa# packet-tracer ?
input Ingress interface on which to trace packet
ciscoasa# packet-tracer input ?
Current available interface(s):
inside Name of interface GigabitEthernet0
outside Name of interface GigabitEthernet1
ciscoasa# packet-tracer input outside ?
icmp Enter this keyword if the trace packet is ICMP
rawip Enter this keyword if the trace packet is RAW IP
tcp Enter this keyword if the trace packet is TCP
udp Enter this keyword if the trace packet is UDP
ciscoasa# packet-tracer input outside tcp ?
A.B.C.D Enter the Source address if ipv4
X:X:X:X::X Enter the Source address if ipv6
fqdn Enter this keyword if an FQDN is specified as source address
user Enter this keyword if a user is specified as source address
ciscoasa# packet-tracer input outside tcp 8.8.8.8 ?
<0-65535> Enter port number (0 - 65535)
aol
bgp
chargen
cifs
citrix-ica
cmd
ctiqbe
daytime
discard
domain
echo
exec
finger
ftp
ftp-data
gopher
h323
hostname
http
https
ident
imap4
irc
ciscoasa# packet-tracer input outside tcp 8.8.8.8 12345 ?
A.B.C.D Enter the destination ipv4 address
fqdn Enter this keyword if an FQDN is specified as destination address
ciscoasa# packet-tracer input outside tcp 8.8.8.8 12345 192.168.1.50 ?
<0-65535> Enter port number (0 - 65535)
aol
bgp
chargen
cifs
citrix-ica
cmd
ctiqbe
daytime
discard
domain
echo
exec
finger
ftp
ftp-data
gopher
h323
hostname
http
https
ident
imap4
irc
ciscoasa# packet-tracer input outside tcp 8.8.8.8 12345 192.168.1.50 http ?
detailed Dump more detailed information
xml Output in xml format
<cr>
ciscoasa# packet-tracer input outside tcp 8.8.8.8 12345 192.168.1.50 http
Phase: 1
Type: ROUTE-LOOKUP
Subtype: input
Result: ALLOW
Config:
Additional Information:
in 192.168.1.0 255.255.255.0 inside
Phase: 2
Type: ACCESS-LIST
Subtype: log
Result: ALLOW
Config:
access-group outside_access_in in interface outside
access-list outside_access_in extended permit tcp any 192.168.1.0 255.255.255.0 eq www
Additional Information:
Phase: 3
Type: IP-OPTIONS
Subtype:
Result: ALLOW
Config:
Additional Information:
Phase: 4
Type: IP-OPTIONS
Subtype:
Result: ALLOW
Config:
Additional Information:
Phase: 5
Type: FLOW-CREATION
Subtype:
Result: ALLOW
Config:
Additional Information:
New flow created with id 100, packet dispatched to next module
Result:
input-interface: outside
input-status: up
input-line-status: up
output-interface: inside
output-status: up
output-line-status: up
Action: allow
Saturday, December 21, 2013
Active-Active Failover on an ASA
When the ASAs are running multiple security contexts, the contexts can be organized into groups. Both ASAs are actively involved in providing security functions, but not in the same security context simultaneously. The active-active failover mode provides both device redundancy and load balancing across contexts.
Configuring active-active failover is similar to configuring active-standby mode. The two failover units need the same LAN failover and stateful failover link configurations, and the same active and standby addresses on each interface. However, each ASA must be assigned its primary and secondary role in each of the two failover groups. As well, each security context must be assigned to a failover group.
ASA1# show mode
Security context mode: multiple
ASA1# show context // ALL CONTEXTS NEEDS TO BE DONE IN ASA1
Context Name Class Interfaces URL
*admin default GigabitEthernet0 disk0:/admin.cfg
CONTEXT-A default GigabitEthernet1, disk0:/CONTEXT-A.cfg
GigabitEthernet2
CONTEXT-B default GigabitEthernet1, disk0:/CONTEXT-B.cfg
GigabitEthernet2
Total active Security Contexts: 3
ASA1# configure terminal
ASA1(config)# failover ?
configure mode commands/options:
group Configure/Enable failover group
interface Configure the IP address to be used for failover and/or
stateful update information
interface-policy Set the policy for failover due to interface failures
key Configure the failover shared secret or key
lan Specify the unit as primary or secondary or configure the
interface and vlan to be used for failover communication
link Configure the interface and vlan to be used as a link for
stateful update information
mac Specify the virtual mac address for a physical interface
polltime Configure failover poll interval
replication Enable HTTP (port 80) connection replication
timeout Specify the failover reconnect timeout value for
asymmetrically routed sessions
<cr>
exec mode commands/options:
active Make this system to be the active unit of the failover pair
exec Execute command on the designated unit
reload-standby Force standby unit to reboot
reset Force an unit or failover group to an unfailed state
ASA1(config)# failover group ?
configure mode commands/options:
<1-2> group number
ASA1(config)# failover group 1 // CONFIGURE FAILOVER GROUP UNDER SYSTEM CONTEXT
ASA1(config-fover-group)# ?
Failover User Group configuration mode:
help Help for user Failover Group configuration commands
interface-policy Set the policy for failover due to interface failures
mac Specify the virtual mac address for a physical interface
no Remove user failover group configuration
polltime Configure failover interface polling interval
preempt Allow preemption of lower priority active unit
primary Primary unit has higher priority
replication Configure the replication option
secondary Secondary unit has higher priority
<cr>
ASA1(config-fover-group)# primary
ASA1(config-fover-group)# preempt ?
fover-group mode commands/options:
<1-1200> Preemption hold-down delay in seconds
<cr>
ASA1(config-fover-group)# preempt 120
ASA1(config-fover-group)# exit
ASA1(config)# failover group 2
ASA1(config-fover-group)# secondary
ASA1(config-fover-group)# preempt 120
ASA1(config-fover-group)# exit
ASA1(config)# context ?
configure mode commands/options:
WORD Symbolic name of the context
ASA1(config)# context admin
ASA1(config-ctx)# ?
Context configuration commands:
allocate-interface Allocate interface to context
allocate-ips Allocate IPS virtual sensor to context
config-url Configure URL for a context configuration
description Provide a description of the context
exit Exit from context configuration mode
help Interactive help for context subcommands
join-failover-group Join a context to a failover group
member Configure class membership for a context
no Negate a command
ASA1(config-ctx)# join-failover-group ?
context mode commands/options:
<1-2> Failover group number
ASA1(config-ctx)# join-failover-group 1 // ALL CONTEXTS ARE UNDER FAILOVER GROUP 1 BY DEFAULT
ASA1(config-ctx)# exit
ASA1(config)# context CONTEXT-A
ASA1(config-ctx)# join-failover-group 1
ASA1(config-ctx)# exit
ASA1(config)# context CONTEXT-B
ASA1(config-ctx)# join-failover-group 2
ASA1(config-ctx)# exit
ASA1(config)# failover lan unit primary
ASA1(config)# failover lan interface LAN-FAILOVER gigabitethernet4
INFO: Non-failover interface config is cleared on GigabitEthernet4 and its sub-interfaces
ASA1(config)# failover link STATEFUL-FAILOVER gigabitethernet5
INFO: Non-failover interface config is cleared on GigabitEthernet5 and its sub-interfaces
ASA1(config)# failover interface ip LAN-FAILOVER 1.1.1.1 255.255.255.252 standby 1.1.1.2
ASA1(config)# failover interface ip STATEFUL-FAILOVER 2.2.2.1 255.255.255.252 standby 2.2.2.2
ASA1(config)# prompt hostname context
ASA1(config)# changeto context admin
ASA1/admin(config)# interface ?
configure mode commands/options:
GigabitEthernet Prefix of interface GigabitEthernet0
ASA1/admin(config)# interface GigabitEthernet0
ASA1/admin(config-if)# ip address 192.168.1.1 255.255.255.0 standby 192.168.1.10
ASA1/admin(config-if)# nameif inside
INFO: Security level for "inside" set to 100 by default.
ASA1(config)# changeto context CONTEXT-A
ASA1/CONTEXT-A(config)# interface ?
configure mode commands/options:
GigabitEthernet Prefix of interface GigabitEthernet1, 2
ASA1/CONTEXT-A(config)# interface GigabitEthernet1
ASA1/CONTEXT-A(config-if)# ip address 10.1.1.1 255.255.255.0 standby 10.1.1.2
ASA1/CONTEXT-A(config-if)# nameif inside
INFO: Security level for "inside" set to 100 by default.
ASA1/CONTEXT-A(config-if)# interface GigabitEthernet2
ASA1/CONTEXT-A(config-if)# ip address 100.1.1.1 255.255.255.0 standby 100.1.1.10
ASA1/CONTEXT-A(config-if)# nameif outside
INFO: Security level for "outside" set to 0 by default.
ASA1/CONTEXT-A(config-if)# changeto context CONTEXT-B
ASA1/CONTEXT-B(config)# interface ?
configure mode commands/options:
GigabitEthernet Prefix of interface GigabitEthernet1, 2
ASA1/CONTEXT-B(config)# interface GigabitEthernet1
ASA1/CONTEXT-B(config-if)# ip address 10.2.2.1 255.255.255.0 standby 10.2.2.2
ASA1/CONTEXT-B(config-if)# nameif inside
INFO: Security level for "inside" set to 100 by default.
ASA1/CONTEXT-B(config-if)# interface GigabitEthernet2
ASA1/CONTEXT-B(config-if)# ip address 100.1.1.2 255.255.255.0 standby 100.1.1.20
ASA1/CONTEXT-B(config-if)# nameif outside
INFO: Security level for "outside" set to 0 by default.
ASA1/admin(config-if)# changeto system
ASA1(config)# failover // TURN ON FAILOVER
ASA1(config)# write memory ?
exec mode commands/options:
all Save active configuration of all contexts
<cr>
ASA1(config)# write memory all // SAVES THE SYSTEM AND ALL CONTEXT CONFIG
Building configuration...
Saving context : system : (000/003 Contexts saved)
Cryptochecksum: e2069dad 2bdfd7b9 72185fee ec97e572
1676 bytes copied in 2.900 secs (838 bytes/sec)
Saving context : admin : (001/003 Contexts saved)
Cryptochecksum: 0c6c2cb2 f1e5ef63 2311e990 0e51dd35
1663 bytes copied in 6.60 secs (277 bytes/sec)
Saving context : CONTEXT-A : (002/003 Contexts saved)
Cryptochecksum: 1f6496fd 95ddb896 1163aca7 84e63309
1716 bytes copied in 2.800 secs (858 bytes/sec)
Saving context : CONTEXT-B : (003/003 Contexts saved)
Cryptochecksum: adbc43d2 a55eee49 870d28ba 6f058996
1716 bytes copied in 2.220 secs (858 bytes/sec)
[OK]
ASA1(config)# .
No Response from Mate // ASA2 ISN'T CONFIGURED YET
Group 1 No Response from Mate, Switch to Active
Group 2 No Response from Mate, Switch to Active
ASA1(config)# show failover
Failover On
Failover unit Primary
Failover LAN Interface: LAN-FAILOVER GigabitEthernet4 (up)
Unit Poll frequency 1 seconds, holdtime 15 seconds
Interface Poll frequency 5 seconds, holdtime 25 seconds
Interface Policy 1
Monitored Interfaces 5 of 60 maximum
Version: Ours 8.4(2), Mate Unknown
Group 1 last failover at: 10:11:48 UTC Nov 3 2013
Group 2 last failover at: 10:11:48 UTC Nov 3 2013
This host: Primary
Group 1 State: Active
Active time: 106 (sec)
Group 2 State: Active
Active time: 106 (sec)
admin Interface inside (192.168.1.1): Normal (Waiting)
CONTEXT-A Interface inside (10.1.1.1): Normal (Waiting)
CONTEXT-A Interface outside (100.1.1.1): Normal (Waiting)
CONTEXT-B Interface inside (10.2.2.1): Normal (Waiting)
CONTEXT-B Interface outside (100.1.1.2): Normal (Waiting)
Other host: Secondary
Group 1 State: Failed
Active time: 0 (sec)
Group 2 State: Failed
Active time: 0 (sec)
admin Interface inside (192.168.1.10): Unknown (Waiting)
CONTEXT-A Interface inside (10.1.1.2): Unknown (Waiting)
CONTEXT-A Interface outside (100.1.1.10): Unknown (Waiting)
CONTEXT-B Interface inside (10.2.2.2): Unknown (Waiting)
CONTEXT-B Interface outside (100.1.1.20): Unknown (Waiting)
Stateful Failover Logical Update Statistics
Link : STATEFUL-FAILOVER GigabitEthernet5 (up)
Stateful Obj xmit xerr rcv rerr
General 0 0 0 0
sys cmd 0 0 0 0
up time 0 0 0 0
RPC services 0 0 0 0
TCP conn 0 0 0 0
UDP conn 0 0 0 0
ARP tbl 0 0 0 0
Xlate_Timeout 0 0 0 0
IPv6 ND tbl 0 0 0 0
SIP Session 0 0 0 0
Route Session 0 0 0 0
User-Identity 0 0 0 0
Logical Update Queue Information
Cur Max Total
Recv Q: 0 0 0
Xmit Q: 0 0 0
ASA1(config)# show failover state
State Last Failure Reason Date/Time
This host - Primary
Group 1 Active None
Group 2 Active None
Other host - Secondary
Group 1 Failed Comm Failure 10:12:05 UTC Nov 3 2013
Group 2 Failed Comm Failure 10:12:05 UTC Nov 3 2013
====Configuration State===
====Communication State===
----
ASA2# show mode
Security context mode: multiple
ASA2# dir *.cfg
Directory of disk0:/*.cfg
89 -rwx 2146 09:09:26 Nov 03 2013 old_running.cfg
90 -rwx 1417 09:09:28 Nov 03 2013 admin.cfg
268136448 bytes total (267481088 bytes free)
ASA2# delete *.cfg // DELETE CONFIG FILES BEFORE FAILOVER/REPLICATION FROM ASA1
Delete filename [*.cfg]?
Delete disk0:/old_running.cfg? [confirm]
Delete disk0:/admin.cfg? [confirm]
ASA2(config)# interface gigabitethernet4
ASA2(config-if)# no shutdown
ASA2(config-if)# interface gigabitethernet5
ASA2(config-if)# no shutdown
ASA2(config-if)# exit
ASA2(config)# failover lan interface LAN-FAILOVER gigabitethernet4
INFO: Non-failover interface config is cleared on GigabitEthernet4 and its sub-interfaces
ASA2(config)# failover interface ip LAN-FAILOVER 1.1.1.1 255.255.255.252 standby 1.1.1.2
ASA2(config)# failover
ASA2(config)# .
Detected an Active mate
Beginning configuration replication from mate.
ERROR: Password recovery was not changed, unable to access
the configuration register.
Removing context 'admin' (1)... Done
COREDUMP UPDATE: open message queue fail: No such file or directory/2
INFO: Admin context is required to get the interfaces
Creating context 'admin'... Done. (2)
WARNING: Skip fetching the URL disk0:/admin.cfg
INFO: Creating context with default config
INFO: Admin context will take some time to come up .... please wait.
Creating context 'CONTEXT-A'... Done. (3)
WARNING: Skip fetching the URL disk0:/CONTEXT-A.cfg
INFO: Creating context with default config
Creating context 'CONTEXT-B'... Done. (4)
WARNING: Skip fetching the URL disk0:/CONTEXT-B.cfg
INFO: Creating context with default config
Crashinfo is NOT enabled on Full Distribution Environment
Group 1 Detected Active mate
Group 2 Detected Active mate
End configuration replication from mate.
ASA1(config)# show context
Context Name Class Interfaces URL
*admin default GigabitEthernet0 disk0:/admin.cfg
CONTEXT-A default GigabitEthernet1, disk0:/CONTEXT-A.cfg
GigabitEthernet2
CONTEXT-B default GigabitEthernet1, disk0:/CONTEXT-B.cfg
GigabitEthernet2
Total active Security Contexts: 3
ASA1(config)# show failover state
State Last Failure Reason Date/Time
This host - Secondary
Group 1 Standby Ready None
Group 2 Standby Ready None
Other host - Primary
Group 1 Active None
Group 2 Active None
====Configuration State===
Sync Done - STANDBY
====Communication State===
Mac set
ASA1(config)#
Group 2 preempt mate // AFTER 120 SECONDS
ASA1(config)# show failover state
State Last Failure Reason Date/Time
This host - Secondary
Group 1 Standby Ready None
Group 2 Active None
Other host - Primary
Group 1 Active None
Group 2 Standby Ready None
====Configuration State===
Sync Done - STANDBY
====Communication State===
Mac set
----
ASA1(config)# Beginning configuration replication: Sending to mate.
INFO: Issuing "tls-proxy maximum-sessions 10000" command due to license change
INFO: "tls-proxy maximum-sessions" config is changed, please save the running-config before system
reboot
End Configuration Replication to mate
ASA1(config)# prompt hostname priority context state // TELL CLI PROMPT TO INDICATE
PRIMARY/SECONDARY, CONTEXT AND ACTIVE/STANDBY STATE
ASA1/pri/act(config)# changeto context admin
ASA1/pri/admin/act(config)# http server enable // ENABLE ASDM/HTTPS ACCESS
ASA1/pri/admin/act(config)# http 0 0 inside
----
ASA1/pri/act(config)# no failover active // ASA2 WILL BE THE ACTIVE FIREWALL FOR BOTH GROUP 1 AND 2
ASA1/pri/stby(config)# show failover state
State Last Failure Reason Date/Time
This host - Primary
Group 1 Standby Ready None
Group 2 Standby Ready None
Other host - Secondary
Group 1 Active Comm Failure 10:12:05 UTC Nov 3 2013
Group 2 Active Comm Failure 10:12:05 UTC Nov 3 2013
====Configuration State===
Sync Done
====Communication State===
Mac set
As with active-standby failover, you can use the ASDM High Availability and Scalability Wizard to configure both the primary and secondary ASAs from the primary unit. To do that, double-click the System context in the device list. Then navigate to Configuration > Device Management > High Availability and select HA/Scalability Wizard.
Otherwise, you can configure active-active failover on the primary and secondary units manually. On the primary unit, double-click the System context in the device list, and then navigate to Configuration > Device Management > High Availability and select Failover.
Configuring active-active failover is similar to configuring active-standby mode. The two failover units need the same LAN failover and stateful failover link configurations, and the same active and standby addresses on each interface. However, each ASA must be assigned its primary and secondary role in each of the two failover groups. As well, each security context must be assigned to a failover group.
ASA1# show mode
Security context mode: multiple
ASA1# show context // ALL CONTEXTS NEEDS TO BE DONE IN ASA1
Context Name Class Interfaces URL
*admin default GigabitEthernet0 disk0:/admin.cfg
CONTEXT-A default GigabitEthernet1, disk0:/CONTEXT-A.cfg
GigabitEthernet2
CONTEXT-B default GigabitEthernet1, disk0:/CONTEXT-B.cfg
GigabitEthernet2
Total active Security Contexts: 3
ASA1# configure terminal
ASA1(config)# failover ?
configure mode commands/options:
group Configure/Enable failover group
interface Configure the IP address to be used for failover and/or
stateful update information
interface-policy Set the policy for failover due to interface failures
key Configure the failover shared secret or key
lan Specify the unit as primary or secondary or configure the
interface and vlan to be used for failover communication
link Configure the interface and vlan to be used as a link for
stateful update information
mac Specify the virtual mac address for a physical interface
polltime Configure failover poll interval
replication Enable HTTP (port 80) connection replication
timeout Specify the failover reconnect timeout value for
asymmetrically routed sessions
<cr>
exec mode commands/options:
active Make this system to be the active unit of the failover pair
exec Execute command on the designated unit
reload-standby Force standby unit to reboot
reset Force an unit or failover group to an unfailed state
ASA1(config)# failover group ?
configure mode commands/options:
<1-2> group number
ASA1(config)# failover group 1 // CONFIGURE FAILOVER GROUP UNDER SYSTEM CONTEXT
ASA1(config-fover-group)# ?
Failover User Group configuration mode:
help Help for user Failover Group configuration commands
interface-policy Set the policy for failover due to interface failures
mac Specify the virtual mac address for a physical interface
no Remove user failover group configuration
polltime Configure failover interface polling interval
preempt Allow preemption of lower priority active unit
primary Primary unit has higher priority
replication Configure the replication option
secondary Secondary unit has higher priority
<cr>
ASA1(config-fover-group)# primary
ASA1(config-fover-group)# preempt ?
fover-group mode commands/options:
<1-1200> Preemption hold-down delay in seconds
<cr>
ASA1(config-fover-group)# preempt 120
ASA1(config-fover-group)# exit
ASA1(config)# failover group 2
ASA1(config-fover-group)# secondary
ASA1(config-fover-group)# preempt 120
ASA1(config-fover-group)# exit
ASA1(config)# context ?
configure mode commands/options:
WORD Symbolic name of the context
ASA1(config)# context admin
ASA1(config-ctx)# ?
Context configuration commands:
allocate-interface Allocate interface to context
allocate-ips Allocate IPS virtual sensor to context
config-url Configure URL for a context configuration
description Provide a description of the context
exit Exit from context configuration mode
help Interactive help for context subcommands
join-failover-group Join a context to a failover group
member Configure class membership for a context
no Negate a command
ASA1(config-ctx)# join-failover-group ?
context mode commands/options:
<1-2> Failover group number
ASA1(config-ctx)# join-failover-group 1 // ALL CONTEXTS ARE UNDER FAILOVER GROUP 1 BY DEFAULT
ASA1(config-ctx)# exit
ASA1(config)# context CONTEXT-A
ASA1(config-ctx)# join-failover-group 1
ASA1(config-ctx)# exit
ASA1(config)# context CONTEXT-B
ASA1(config-ctx)# join-failover-group 2
ASA1(config-ctx)# exit
ASA1(config)# failover lan unit primary
ASA1(config)# failover lan interface LAN-FAILOVER gigabitethernet4
INFO: Non-failover interface config is cleared on GigabitEthernet4 and its sub-interfaces
ASA1(config)# failover link STATEFUL-FAILOVER gigabitethernet5
INFO: Non-failover interface config is cleared on GigabitEthernet5 and its sub-interfaces
ASA1(config)# failover interface ip LAN-FAILOVER 1.1.1.1 255.255.255.252 standby 1.1.1.2
ASA1(config)# failover interface ip STATEFUL-FAILOVER 2.2.2.1 255.255.255.252 standby 2.2.2.2
ASA1(config)# prompt hostname context
ASA1(config)# changeto context admin
ASA1/admin(config)# interface ?
configure mode commands/options:
GigabitEthernet Prefix of interface GigabitEthernet0
ASA1/admin(config)# interface GigabitEthernet0
ASA1/admin(config-if)# ip address 192.168.1.1 255.255.255.0 standby 192.168.1.10
ASA1/admin(config-if)# nameif inside
INFO: Security level for "inside" set to 100 by default.
ASA1(config)# changeto context CONTEXT-A
ASA1/CONTEXT-A(config)# interface ?
configure mode commands/options:
GigabitEthernet Prefix of interface GigabitEthernet1, 2
ASA1/CONTEXT-A(config)# interface GigabitEthernet1
ASA1/CONTEXT-A(config-if)# ip address 10.1.1.1 255.255.255.0 standby 10.1.1.2
ASA1/CONTEXT-A(config-if)# nameif inside
INFO: Security level for "inside" set to 100 by default.
ASA1/CONTEXT-A(config-if)# interface GigabitEthernet2
ASA1/CONTEXT-A(config-if)# ip address 100.1.1.1 255.255.255.0 standby 100.1.1.10
ASA1/CONTEXT-A(config-if)# nameif outside
INFO: Security level for "outside" set to 0 by default.
ASA1/CONTEXT-A(config-if)# changeto context CONTEXT-B
ASA1/CONTEXT-B(config)# interface ?
configure mode commands/options:
GigabitEthernet Prefix of interface GigabitEthernet1, 2
ASA1/CONTEXT-B(config)# interface GigabitEthernet1
ASA1/CONTEXT-B(config-if)# ip address 10.2.2.1 255.255.255.0 standby 10.2.2.2
ASA1/CONTEXT-B(config-if)# nameif inside
INFO: Security level for "inside" set to 100 by default.
ASA1/CONTEXT-B(config-if)# interface GigabitEthernet2
ASA1/CONTEXT-B(config-if)# ip address 100.1.1.2 255.255.255.0 standby 100.1.1.20
ASA1/CONTEXT-B(config-if)# nameif outside
INFO: Security level for "outside" set to 0 by default.
ASA1/admin(config-if)# changeto system
ASA1(config)# failover // TURN ON FAILOVER
ASA1(config)# write memory ?
exec mode commands/options:
all Save active configuration of all contexts
<cr>
ASA1(config)# write memory all // SAVES THE SYSTEM AND ALL CONTEXT CONFIG
Building configuration...
Saving context : system : (000/003 Contexts saved)
Cryptochecksum: e2069dad 2bdfd7b9 72185fee ec97e572
1676 bytes copied in 2.900 secs (838 bytes/sec)
Saving context : admin : (001/003 Contexts saved)
Cryptochecksum: 0c6c2cb2 f1e5ef63 2311e990 0e51dd35
1663 bytes copied in 6.60 secs (277 bytes/sec)
Saving context : CONTEXT-A : (002/003 Contexts saved)
Cryptochecksum: 1f6496fd 95ddb896 1163aca7 84e63309
1716 bytes copied in 2.800 secs (858 bytes/sec)
Saving context : CONTEXT-B : (003/003 Contexts saved)
Cryptochecksum: adbc43d2 a55eee49 870d28ba 6f058996
1716 bytes copied in 2.220 secs (858 bytes/sec)
[OK]
ASA1(config)# .
No Response from Mate // ASA2 ISN'T CONFIGURED YET
Group 1 No Response from Mate, Switch to Active
Group 2 No Response from Mate, Switch to Active
ASA1(config)# show failover
Failover On
Failover unit Primary
Failover LAN Interface: LAN-FAILOVER GigabitEthernet4 (up)
Unit Poll frequency 1 seconds, holdtime 15 seconds
Interface Poll frequency 5 seconds, holdtime 25 seconds
Interface Policy 1
Monitored Interfaces 5 of 60 maximum
Version: Ours 8.4(2), Mate Unknown
Group 1 last failover at: 10:11:48 UTC Nov 3 2013
Group 2 last failover at: 10:11:48 UTC Nov 3 2013
This host: Primary
Group 1 State: Active
Active time: 106 (sec)
Group 2 State: Active
Active time: 106 (sec)
admin Interface inside (192.168.1.1): Normal (Waiting)
CONTEXT-A Interface inside (10.1.1.1): Normal (Waiting)
CONTEXT-A Interface outside (100.1.1.1): Normal (Waiting)
CONTEXT-B Interface inside (10.2.2.1): Normal (Waiting)
CONTEXT-B Interface outside (100.1.1.2): Normal (Waiting)
Other host: Secondary
Group 1 State: Failed
Active time: 0 (sec)
Group 2 State: Failed
Active time: 0 (sec)
admin Interface inside (192.168.1.10): Unknown (Waiting)
CONTEXT-A Interface inside (10.1.1.2): Unknown (Waiting)
CONTEXT-A Interface outside (100.1.1.10): Unknown (Waiting)
CONTEXT-B Interface inside (10.2.2.2): Unknown (Waiting)
CONTEXT-B Interface outside (100.1.1.20): Unknown (Waiting)
Stateful Failover Logical Update Statistics
Link : STATEFUL-FAILOVER GigabitEthernet5 (up)
Stateful Obj xmit xerr rcv rerr
General 0 0 0 0
sys cmd 0 0 0 0
up time 0 0 0 0
RPC services 0 0 0 0
TCP conn 0 0 0 0
UDP conn 0 0 0 0
ARP tbl 0 0 0 0
Xlate_Timeout 0 0 0 0
IPv6 ND tbl 0 0 0 0
SIP Session 0 0 0 0
Route Session 0 0 0 0
User-Identity 0 0 0 0
Logical Update Queue Information
Cur Max Total
Recv Q: 0 0 0
Xmit Q: 0 0 0
ASA1(config)# show failover state
State Last Failure Reason Date/Time
This host - Primary
Group 1 Active None
Group 2 Active None
Other host - Secondary
Group 1 Failed Comm Failure 10:12:05 UTC Nov 3 2013
Group 2 Failed Comm Failure 10:12:05 UTC Nov 3 2013
====Configuration State===
====Communication State===
----
ASA2# show mode
Security context mode: multiple
ASA2# dir *.cfg
Directory of disk0:/*.cfg
89 -rwx 2146 09:09:26 Nov 03 2013 old_running.cfg
90 -rwx 1417 09:09:28 Nov 03 2013 admin.cfg
268136448 bytes total (267481088 bytes free)
ASA2# delete *.cfg // DELETE CONFIG FILES BEFORE FAILOVER/REPLICATION FROM ASA1
Delete filename [*.cfg]?
Delete disk0:/old_running.cfg? [confirm]
Delete disk0:/admin.cfg? [confirm]
ASA2(config)# interface gigabitethernet4
ASA2(config-if)# no shutdown
ASA2(config-if)# interface gigabitethernet5
ASA2(config-if)# no shutdown
ASA2(config-if)# exit
ASA2(config)# failover lan interface LAN-FAILOVER gigabitethernet4
INFO: Non-failover interface config is cleared on GigabitEthernet4 and its sub-interfaces
ASA2(config)# failover interface ip LAN-FAILOVER 1.1.1.1 255.255.255.252 standby 1.1.1.2
ASA2(config)# failover
ASA2(config)# .
Detected an Active mate
Beginning configuration replication from mate.
ERROR: Password recovery was not changed, unable to access
the configuration register.
Removing context 'admin' (1)... Done
COREDUMP UPDATE: open message queue fail: No such file or directory/2
INFO: Admin context is required to get the interfaces
Creating context 'admin'... Done. (2)
WARNING: Skip fetching the URL disk0:/admin.cfg
INFO: Creating context with default config
INFO: Admin context will take some time to come up .... please wait.
Creating context 'CONTEXT-A'... Done. (3)
WARNING: Skip fetching the URL disk0:/CONTEXT-A.cfg
INFO: Creating context with default config
Creating context 'CONTEXT-B'... Done. (4)
WARNING: Skip fetching the URL disk0:/CONTEXT-B.cfg
INFO: Creating context with default config
Crashinfo is NOT enabled on Full Distribution Environment
Group 1 Detected Active mate
Group 2 Detected Active mate
End configuration replication from mate.
ASA1(config)# show context
Context Name Class Interfaces URL
*admin default GigabitEthernet0 disk0:/admin.cfg
CONTEXT-A default GigabitEthernet1, disk0:/CONTEXT-A.cfg
GigabitEthernet2
CONTEXT-B default GigabitEthernet1, disk0:/CONTEXT-B.cfg
GigabitEthernet2
Total active Security Contexts: 3
ASA1(config)# show failover state
State Last Failure Reason Date/Time
This host - Secondary
Group 1 Standby Ready None
Group 2 Standby Ready None
Other host - Primary
Group 1 Active None
Group 2 Active None
====Configuration State===
Sync Done - STANDBY
====Communication State===
Mac set
ASA1(config)#
Group 2 preempt mate // AFTER 120 SECONDS
ASA1(config)# show failover state
State Last Failure Reason Date/Time
This host - Secondary
Group 1 Standby Ready None
Group 2 Active None
Other host - Primary
Group 1 Active None
Group 2 Standby Ready None
====Configuration State===
Sync Done - STANDBY
====Communication State===
Mac set
----
ASA1(config)# Beginning configuration replication: Sending to mate.
INFO: Issuing "tls-proxy maximum-sessions 10000" command due to license change
INFO: "tls-proxy maximum-sessions" config is changed, please save the running-config before system
reboot
End Configuration Replication to mate
ASA1(config)# prompt hostname priority context state // TELL CLI PROMPT TO INDICATE
PRIMARY/SECONDARY, CONTEXT AND ACTIVE/STANDBY STATE
ASA1/pri/act(config)# changeto context admin
ASA1/pri/admin/act(config)# http server enable // ENABLE ASDM/HTTPS ACCESS
ASA1/pri/admin/act(config)# http 0 0 inside
----
ASA1/pri/act(config)# no failover active // ASA2 WILL BE THE ACTIVE FIREWALL FOR BOTH GROUP 1 AND 2
ASA1/pri/stby(config)# show failover state
State Last Failure Reason Date/Time
This host - Primary
Group 1 Standby Ready None
Group 2 Standby Ready None
Other host - Secondary
Group 1 Active Comm Failure 10:12:05 UTC Nov 3 2013
Group 2 Active Comm Failure 10:12:05 UTC Nov 3 2013
====Configuration State===
Sync Done
====Communication State===
Mac set
As with active-standby failover, you can use the ASDM High Availability and Scalability Wizard to configure both the primary and secondary ASAs from the primary unit. To do that, double-click the System context in the device list. Then navigate to Configuration > Device Management > High Availability and select HA/Scalability Wizard.
Otherwise, you can configure active-active failover on the primary and secondary units manually. On the primary unit, double-click the System context in the device list, and then navigate to Configuration > Device Management > High Availability and select Failover.
Subscribe to:
Posts (Atom)











































