Professional Documents
Culture Documents
CCNA Security
Major Concepts
Describe the purpose and operation of VPN types Describe the purpose and operation of GRE VPNs Describe the components and operations of IPsec VPNs Configure and verify a site-to-site IPsec VPN with preshared key authentication using CLI Configure and verify a site-to-site IPsec VPN with preshared key authentication using SDM Configure and verify a Remote Access VPN
Lesson Objectives
Upon completion of this lesson, the successful participant will be able to:
1. Describe the purpose and operation of VPNs 2. Differentiate between the various types of VPNs 3. Identify the Cisco VPN product line and the security features of these products 4. Configure a site-to-site VPN GRE tunnel 5. Describe the IPSec protocol and its basic functions 6. Differentiate between AH and ESP 7. Describe the IKE protocol and modes 8. Describe the five steps of IPSec operation
Lesson Objectives
9. Describe how to prepare IPSec by ensuring that ACLs are compatible with IPSec 10. Configure IKE policies using the CLI 11. Configure the IPSec transform sets using the CLI 12. Configure the crypto ACLs using the CLI 13. Configure and apply a crypto map using the CLI 14. Describe how to verify and troubleshoot the IPSec configuration 15. Describe how to configure IPSec using SDM 16. Configure a site-to-site VPN using the Quick Setup VPN Wizard in SDM 17. Configure a site-to-site VPN using the step-by-step VPN Wizard in SDM
Lesson Objectives
18. Verify, monitor and troubleshoot VPNs using SDM 19. Describe how an increasing number of organizations are offering telecommuting options to their employees 20. Differentiate between Remote Access IPSec VPN solutions and SSL VPNs 21. Describe how SSL is used to establish a secure VPN connection 22. Describe the Cisco Easy VPN feature 23. Configure a VPN Server using SDM 24. Connect a VPN client using the Cisco VPN Client software
What is a VPN?
Benefits of VPN
Cost savings:
VPNs eliminate expensive dedicated WAN links and modem banks. Additionally, with the advent of cost-effective, high-bandwidth technologies, such as DSL, organizations can use VPNs to reduce their connectivity costs while simultaneously increasing remote connection bandwidth.
Security:
Use advanced encryption and authentication protocols that protect data from unauthorized access.
Scalability
VPNs use the Internet infrastructure. So it is easy to add new users, corporations can add significant capacity without adding significant infrastructure
Layer 3 VPN
IPSec
VPN
Internet
IPSec
Generic routing encapsulation (GRE): point-to-point site connections Multiprotocol Label Switching (MPLS): they can establish any-to-any
connectivity to many sites. IPSec: point-to-point site connections
Layer 3 VPN
VPN can be made at either Layer 2 or Layer 3 of the OSI model. Establishing connectivity between sites over a Layer 2 or Layer 3 is the same. This chapter focuses on Layer 3 VPN technology. Layer 3 VPNs:
GRE: point-to-point site connections MPLS: any-to-any site connections IPsec: point-to-point site connections
Site-to-Site VPN
A site-to-site VPN is created when connection devices on both sides of the VPN connection are aware of the VPN configuration in advance. The VPN remains static, and internal hosts have no knowledge that a VPN exists. Frame Relay, ATM, GRE, and MPLS VPNs are examples of site-to-site VPNs.
In a site-to-site VPN, hosts send and receive normal TCP/IP traffic through a VPN gateway, which can be a router, firewall, Cisco VPN Concentrator, or Cisco ASA 5500 Series Adaptive Security Appliance. The VPN gateway is responsible for encapsulating and encrypting outbound traffic from a particular site and sending it through a VPN tunnel over the Internet to a peer VPN gateway at the target site. Upon receipt, the peer VPN gateway strips the headers, decrypts the content, and relays the packet toward the target host inside its private network
H c vi n cng ngh thng tin Bach Khoa - Website: www.bkacad.com
Remote-Access VPNs
A remote-access VPN is created when VPN information is not statically set up, but instead allows for dynamically changing information and can be enabled and disabled. Remote-access VPNs can support the needs of telecommuters, mobile users, and extranet consumer-to-business traffic. Remote-access VPNs support a client / server architecture where a VPN client (remote host) requires secure access to the enterprise network via a VPN server device at the network edge.
R1
R1-vpn-cluster.span.com
R1
In a remote-access VPN, each host typically has Cisco VPN Client software
H c vi n cng ngh thng tin Bach Khoa - Website: www.bkacad.com
Provides remote-access connectivity from almost any Internet-enabled host using a web browser and its native Secure Sockets Layer (SSL) encryption. Delivers two modes of access: Clientless:
A remote client needs only an SSL-enabled web browser to access HTTP- or HTTPSenabled web servers on the corporate LAN.
Thin client:
A remote client must download a small, Javabased applet for secure access of TCP applications that use static port numbers. UDP is not supported in a thin client environment.
SSL VPNs are appropriate for user populations that require per-application or per-server access control, or access from non-enterprise-owned desktops. SSL VPNs are not a complete replacement for IPsec VPNs.
H c vi n cng ngh thng tin Bach Khoa - Website: www.bkacad.com
Product Choice
Cisco VPN-Enabled Router
Remote-Access VPN
Secondary role
Site-to-Site VPN
Primary role
Cisco PIX 500 Series Security Appliances Cisco ASA 5500 Series Adaptive Security Appliances Cisco VPN 3000 Series Concentrators Home Routers (SOHO Routers)
Secondary role
Primary role
Primary role
Secondary role
Primary role
Secondary role
Primary role
Secondary role
VPN Solutions
Cisco provides a suite of VPNoptimized routers. Cisco IOS software for routers combines VPN services with routing services. The Cisco VPN software adds strong security using encryption and authentication The Cisco IOS feature sets incorporate many VPN features:
Voice and Video Enabled VPN (V3PN) Ipsec stateful failover Dynamic Multipoint Virtual Private Network (DMVPN) Ipsec and MPLS integration Cisco Easy VPN
H c vi n cng ngh thng tin Bach Khoa - Website: www.bkacad.com
VPN features
Voice and Video Enabled VPN (V3PN) - Integrates IP telephony, QoS, and IPsec, providing an end-to-end VPN service that helps ensure the timely delivery of latency-sensitive applications such as voice and video. IPsec stateful failover - Provides fast and scalable network resiliency for VPN sessions between remote and central sites. With both stateless and stateful failover solutions available, such as Hot Standby Router Protocol (HSRP), IPsec stateful failover ensures maximum uptime of mission-critical applications. Dynamic Multipoint Virtual Private Network (DMVPN) - Enables the auto-provisioning of site-to-site IPsec VPNs, combining three Cisco IOS software features: Next Hop Resolution Protocol (NHRP), multipoint GRE, and IPsec VPN. This combination eases the provisioning challenges for customers and provides secure connectivity between all locations.
VPN features
IPsec and MPLS integration Enables ISPs to map IPsec sessions directly into an MPLS VPN. This solution can be deployed on co-located edge routers that are connected to a Cisco IOS software MPLS provider edge (PE) network. Cisco Easy VPN Simplifies VPN deployment for remote offices and teleworkers. The Cisco Easy VPN solution centralizes VPN management across all Cisco VPN devices, thus reducing the management complexity of VPN deployments.
These are some of the features that Cisco ASA 5500 Series Adaptive Security Appliances provide:
Flexible platform Resilient clustering Cisco Easy VPN Automatic Cisco VPN Client updates Cisco IOS SSL VPN VPN infrastructure for contemporary applications Integrated web-based management
H c vi n cng ngh thng tin Bach Khoa - Website: www.bkacad.com
IPSec Clients
Cisco remote-access VPNs can use four IPsec clients: Certicom client: A wireless client that is loaded on to wireless personal digital assistants (PDAs) running the Palm or Microsoft Windows Mobile operating systems. Cisco VPN Client software: Loaded on the PC or laptop of an individual, the Cisco VPN Client allows organizations to establish end-toend, encrypted VPN tunnels for secure connectivity for mobile employees or teleworkers. Cisco Remote Router VPN Client : A Cisco remote router, configured as a VPN client, that connects small office, home office (SOHO) LANs to the VPN. Cisco AnyConnect VPN Client : Next-generation VPN client that provides remote users with secure VPN connections to the Cisco 5500 Series Adaptive Security Appliance running Cisco ASA 5500 Series Software Version 8.0 and higher or Cisco ASDM Version 6.0 and higher.
H c vi n cng ngh thng tin Bach Khoa - Website: www.bkacad.com
Cisco IPSec VPN Shared Port Adapter (SPA): Delivers scalable and
cost-effective VPN performance for Cisco Catalyst 6500 Series Switches and Cisco 7600 Series Routers.
The PIX Firewall VAC+ delivers hardware acceleration up to 425 Mb/s of DES, 3DES, or AES IPsec encryption throughput.
Encapsulation
Original IP Packet
Identify the source source serial 0/0 R2(configif)# tunnel tunnel interface
R2(configif)# tunnel destination 192.168.3.3
R2(configif)# tunnel mode gre ip Identify the destination of the tunnel R2(configif)# Configure what protocol GRE will encapsulate
Using GRE
GRE can be used to tunnel non-IP traffic over an IP network Ipsec only supports unicast traffic. GRE supports all types of traffic Routing Protocols are supported in GRE GRE does not provide encryption
H c vi n cng ngh thng tin Bach Khoa - Website: www.bkacad.com
IPSec Topology
Main Site
IPsec
Perimeter Router Legacy Legacy Cisco PIX Firewall Mobile Worker with a Cisco VPN Client on a Laptop Computer Corporate
POP ASA
Concentrator
IPSec Framework
Diffie-Hellman
DH7
Confidentiality
Confidentiality is achieved through
encryption of traffic as it travels down the VPN. The degree of security depends on the length of the key of the encryption algorithm. The following are some encryption algorithms and key lengths that VPNs use:
DES: Uses a 56-bit key. DES is a symmetric key cryptosystem. 3DES: A variant of DES. 3DES uses three independent 56-bit encryption keys per 64bit block. 3DES is a symmetric key cryptosystem. AES: Provides stronger security than DES and is computationally more efficient than 3DES. AES is a symmetric key cryptosystem. Software-Optimized Encryption Algorithm (SEAL): Uses a 160-bit key. SEAL is a symmetric key cryptosystem.
Integrity
Integrity
Integrity
There are two common HMAC algorithms:
HMAC - Message Digest 5 (HMACMD5): The variable-length message and 128-bit shared secret key are combined and run through the HMAC-MD5 hash algorithm. The output is a 128-bit hash. HMAC- Secure Hash Algorithm 1 (HMAC-SHA-1): The variable-length message and the 160-bit shared secret key are combined and run through the HMAC-SHA-1 hash algorithm. The output is a 160-bit hash.
HMAC-SHA-1 is considered cryptographically stronger than HMAC-MD5. It is recommended when slightly superior security is important.
H c vi n cng ngh thng tin Bach Khoa - Website: www.bkacad.com
Authentication
The device on the other end of the VPN tunnel must be authenticated
before the communication path is considered secure. There are two primary methods of configuring peer authentication.:
Pre-shared Keys (PSKs) - A pre-shared secret key value is entered into each peer manually and is used to authenticate the peer. RSA signatures - The exchange of digital certificates authenticates the peers
H c vi n cng ngh thng tin Bach Khoa - Website: www.bkacad.com
At the local device, the authentication key and the identity information (device-specific information) are sent through a hash algorithm to form hash_I. One-way authentication is established by sending Diffie-Hellman DH7 hash_I to the remote device. If the remote device can independently create the same hash, the local device is authenticated. The authentication process continues in the opposite direction. The remote device combines its identity information with the preshared-based authentication key and sends it through the hash algorithm to form hash_R. hash_R is sent to the local device. If the local device can independently create the same hash, the remote device is authenticated.
H c vi n cng ngh thng tin Bach Khoa - Website: www.bkacad.com
RSA Signatures
At the local device, the authentication key and identity information (device-specific information) are sent through the hash algorithm forming hash_I. hash_I is encrypted using the local device's private encryption key creating a digital signature. The digital signature and a digital certificate are forwarded to the remote device. The public encryption key for decrypting the signature is included in the digital certificate. The remote device verifies the digital signature by decrypting it using the public encryption key. The result is hash_I. Next, the remote device independently creates hash_I from stored information. If the calculated hash_I equals the decrypted hash_I, the local device is authenticated. After the remote device authenticates the local device, the authentication process begins in the opposite direction and all steps are repeated from the remote device to the local device.
Encryption algorithms (DES, 3DES) as well as the hashing algorithms (MD5, SHA) require a symmetric, shared secret key to perform encryption and decryption. How do the encrypting and decrypting devices get the shared secret key? The Diffie-Hellman (DH) key agreement is a public key exchange method that provides a way for two peers to establish a shared secret key that only they know. There are four DH groups: 1, 2, 5, and 7.
R2
R2
Authentication Header
Authentication Header
1. The IP Header and data payload are hashed
R2
AH
Data
Authentication Data
(00ABCDEF)
IP HDR
AH
Data
2. The hash builds a new AH header which is prepended R1 to the original packet
(00ABCDEF) 4. The peer router hashes the IP (00ABCDEF) header and data payload, extracts the transmitted hash and compares
ESP
Diffie-Hellman
DH7
Function of ESP
Internet Router
IP HDR Data
Router
IP HDR Data
New IP HDR
ESP HDR
IP HDR
Data
ESP Trailer
ESP Auth
Encrypted Authenticated
Provides confidentiality with encryption Provides integrity with authentication
Mode Types
Transport Mode: Protect the payload and transport layer but leave the original IP in plaintext. The original IP is used to route the packet through the Internet Work well with GRE Tunnel Mode: Protect complete original IP packet. The original IP packet is encrypted and then it is encapsulated in another IP packet. The packet is routed by outside IP address. Used in the Ipsec remote-access application.
Security Associations
The negotiated parameters between two devices are known as a security association (SA). A VPN has SA entries defining the IPsec encryption parameters as well as SA entries defining the key exchange parameters. Diffie-Hellman (DH) is used to create the shared secret key. IPsec uses the Internet Key Exchange (IKE) protocol to establish the key exchange process. IKE is layered on UDP and uses UDP port 500 to exchange IKE information
IKE Phases
Host A 10.0.1.3 IKE Phase 1 Exchange
1. Negotiate IKE policy sets
Policy 10 DES MD5 pre-share DH1 Policy 15 DES MD5 pre-share DH1 lifetime
R1
R2
Host B 10.0.2.3
2. DH key exchange
lifetime
2. DH key exchange
R2 Host B 10.0.2.3
Policy 15 DES
(YB ) mod p = K
XA
XB (YA )
mod p = K
Internet
HR Servers
Peer Authentication
IKE Phase 2
Host A 10.0.1.3
R1
R2
Host B 10.0.2.3
IKE Phase 2 performs the following functions: Negotiates IPsec security parameters, known as IPsec transform sets Establishes IPsec SAs Periodically renegotiates IPsec SAs to ensure security Optionally performs an additional DH exchange
1. 2.
Host A sends interesting traffic to Host B. R1 and R2 negotiate an IKE Phase 1 session. IKE SA
IKE Phase 1
IKE SA
3.
IPsec SA
4.
5.
Configuring IPsec
Site 1
10.0.1.0/24 10.0.1.3 R1
AH ESP IKE R2
Site 2
10.0.2.0/24 10.0.2.3
Internet
S0/0/0 172.30.1.2 S0/0/0 172.30.2.2
Ensure that protocols 50 (ESP), 51 (AH) and UDP port 500 (ISAKMP)
traffic are not blocked by incoming ACLs on interfaces used by IPsec.
Permitting Traffic
ISAKMP Parameters
Multiple Policies
Policy Negotiations
Sample Configuration
Transform Sets
Sample Configuration
Command Syntax
Defines the name assigned to the crypto map set or indicates the name of the crypto map to edit. The number assigned to the crypto map entry. Indicates that ISAKMP will not be used to establish the IPsec SAs. Indicates that ISAKMP will be used to establish the IPsec SAs. (Default value) Indicates that CET will be used instead of IPsec for protecting the traffic. (Optional) Specifies that this crypto map entry references a preexisting static crypto map. If this keyword is used, none of the crypto map configuration commands are available. (Optional) Specifies the name of the dynamic crypto map set that should be used as the policy template.
H c vi n cng ngh thng tin Bach Khoa - Website: www.bkacad.com
dynamic
dynamic-map-name
Command set peer [hostname | ipaddress] pfs [group1 | group2] transform-set [set_name(s)] security-association lifetime match address [accesslist-id | name] no exit
Description
Used with the peer, pfs, transform-set, and security-association commands. Specifies the allowed IPsec peer by IP address or hostname.
Specifies DH Group 1 or Group 2. Specify list of transform sets in priority order. When the ipsec-manual parameter is used with the crypto map command, then only one transform set can be defined. When the ipsec-isakmp parameter or the dynamic parameter is used with the crypto map command, up to six transform sets can be specified. Sets SA lifetime parameters in seconds or kilobytes. Identifies the extended ACL by its name or number. The value should match the access-list-number or name argument of a previously defined IP-extended ACL being matched. Used to delete commands entered with the set command. Exits crypto map configuration mode.
Sample Configuration
CLI Commands
Show Command show crypto map show crypto isakmp policy show crypto ipsec sa show crypto ipsec transform-set debug crypto isakmp debug crypto ipsec
Description
Displays configured crypto maps Displays configured IKE policies Displays established IPsec tunnels Displays configured IPsec transform sets Debugs IKE events Debugs IPsec events
3. Choose a wizard 4. Click the VPN implementation subtype VPN implementation 4 Subtypes. Vary based
On VPN wizard chosen.
VPN Components
VPN Wizards
SSL VPN parameters
Individual IPsec components used to build VPNs
VPN Components
Quick Setup
Configure the parameters Interface to use Peer identity information Authentication method Traffic to encrypt
Verify Parameters
Step-by-Step Wizard
Choose the outside interface that is used to connect to the IPSec peer 2 Specify the IP address of the peer 3 Choose the authentication method and specify the credentials 4 Click Next
H c vi n cng ngh thng tin Bach Khoa - Website: www.bkacad.com
3 Click Next
Click the ellipses button to choose an existing ACL or create a new one 2 3
To use an existing ACL, choose the Select an Existing Rule (ACL) option. To create a new ACL, choose the Create a New Rule (ACL) and Select option
H c vi n cng ngh thng tin Bach Khoa - Website: www.bkacad.com
Add a Rule
2 Click Add
2 Define the source hosts or networks in the Source Host/Network pane and the destination hosts or network in the Destination/Host Network pane 3
(Optional) To provide protection for specific protocols, choose the specific protocol radio box and desired port numbers
H c vi n cng ngh thng tin Bach Khoa - Website: www.bkacad.com
Configuration Summary
Click Back to modify the configuration. Click Finish to complete the configuration.
H c vi n cng ngh thng tin Bach Khoa - Website: www.bkacad.com
Monitor
Choose Monitor > VPN Status > IPSec Tunnels
Telecommuting
Flexibility in working location and working hours Employers save on realestate, utility and other overhead costs Succeeds if program is voluntary, subject to management discretion, and operationally feasible
Telecommuting Benefits
Organizational benefits:
Continuity of operations Increased responsiveness Secure, reliable, and manageable access to information Cost-effective integration of data, voice, video, and applications Increased employee productivity, satisfaction, and retention
Social benefits:
Increased employment opportunities for marginalized groups Less travel and commuter related stress
Environmental benefits:
Reduced carbon footprints, both for individual workers and organizations
Any Application
Anywhere Access
SSL-Based VPN
SSL Applications
Web-enabled applications, file sharing, e-mail
IPsec
All IP-based applications
Encryption
Moderate Key lengths from 40 bits to 128 bits Moderate One-way or two-way authentication
Stronger Key lengths from 56 bits to 256 bits Strong Two-way authentication using shared secrets or digital certificates Moderate Can be challenging to nontechnical users Strong Only specific devices with specific configurations can connect
Authentication
Ease of Use
Very high
Overall Security
SSL VPNs
Integrated security and routing Browser-based full network SSL VPN access SSL VPN
Internet
Headquarters
Types of Access
User makes a connection to TCP port 443 Router replies with a digitally signed public key User software creates a shared-secret key Shared-secret key, encrypted with public key of the server, is sent to the router Bulk encryption occurs using the shared-secret key with a symmetric encryption algorithm
Username/Password
5
Reverse Router Injection (RRI) adds a static route entry on the router for the remote clients IP address
1 4 3
Click Add
Click OK
3 1
2 4
Select the location where Easy VPN group policies can be stored
2 5
Click Add
Click Next
R1 R1
R1-vpn-cluster.span.com
R1-vpn-cluster.span.com
Establishes end-to-end, encrypted VPN tunnels for secure connectivity Compatible with all Cisco VPN products Supports the innovative Cisco Easy VPN capabilities
Establishing a Connection
R1-vpn-cluster.span.com
R1
R1-vpn-cluster.span.com
R1
Summary
A VPN is a private network that is created via tunneling over a public network, usually the Internet. There are site-to-site VPNs and remote access VPNs. VPNs require the use of modern encryption techniques to ensure secure transport of information.
H c vi n cng ngh thng tin Bach Khoa - Website: www.bkacad.com
Summary
Summary
IPsec is a framework of open standards that establishes the rules for secure communications. IPsec relies on existing algorithms to achieve encryption, authentication, and key exchange. IPsec can encapsulate a packet using either Authentication Header (AH) or the more secure Encapsulation Security Protocol (ESP). IPsec uses the Internet Key Exchange (IKE) protocol to establish the key exchange process.
Summary
Summary