VPN: To ensure data confidentiality, many VPN technologies need to use encryption and decryption technologies, such as IPsec VPN and SSL VPN.
IPv6: To prevent the device from being spoofed, secure neighbor discovery (SEND) router authorization can be configured on the device. The digital certificate technology can be used for selecting legitimate gateway devices.
HTTPS login: The administrator can use HTTPS to securely log in to the web UI of the HTTPS server and manage network devices. To improve security of SSL connections, the CA trusted by the web browser is configured to issue local certificates for the HTTPS client. Then the web browser can verify local certificates, avoiding malicious attacks and ensuring secure login.
System login authorization: A digest algorithm processes the user password to generate a digest, which is stored and compared with the user-supplied password the next time the user logs in.
The most important application scenario is VPN.
This course introduces several encrypted VPNs and some common VPN technologies.
Traditional VPN networking mainly uses the private line VPN and client device-based encrypted VPN. A private line VPN is a Layer 2 VPN constructed by renting digital data network (DDN) circuits, ATM permanent virtual circuits (PVCs), and frame relay (FR) PVCs. The backbone network is maintained by telecom carriers, and the customer is responsible for managing its own sites and routes. On a client device-based encrypted VPN, all VPN functions are implemented by the client device, and the VPN members are interconnected over the Internet (untrusted). The private line VPNs are costly and provide poor scalability, while client device-based encrypted VPNs pose high requirements on the user's device and skills.
According to the IETF draft, an IP-based VPN "is an emulation of a private Wide Area Network (WAN) facility using IP facilities." That is, it is a point-to-point private line emulated on the Internet using tunneling technologies. "Virtual" means that users use the toll lines of the Internet to set up their own private networks, without requiring dedicated physical toll lines. "Private network" means that users can customize a network best suited to their needs.
As IP data communication technologies continuously develop, IP-based VPN technologies become the mainstream in the VPN market. Because the IP VPN is carried by an IP network and carrier networks are gradually improved, the cost is low, the service quality meets customer requirements, and high scalability and manageability is provided. For this reason, a growing number of users are starting to select the IP VPN, and operators are building IP VPNs to attract more users.
L3VPN
- A L3VPN works at the network layer of the protocol stack. There are two major types of L3VPN:
- In an IPSec VPN, the IPsec header and IP header work at the same layer; packets are encapsulated in IP-in-IP mode, or the IPsec header and IP header encapsulate the payload at the same time.
- GRE VPN is another major type of L3VPN technology. GRE VPN emerged earlier and its implementation mechanism is simpler. A GRE VPN allows the packets of one protocol to be encapsulated in those of any other protocol. GRE VPN is less secure than IPsec VPN due to having limited, simple security mechanisms.
L2VPN
A L2VPN works at the data link layer of the protocol stack. Protocols used by L2VPN include the Point-to-Point Tunneling Protocol (PPTP), Layer 2 Forwarding (L2F, Layer 2 Forwarding), and Layer 2 Tunneling Protocol (L2TP, Layer 2 Tunneling Protocol).
L2TP
A tunneling protocol set for transparently transmitting PPP packets between a user and an enterprise server. It provides support for the tunnel transmission of packets at the PPP link layer.
Main Usage
Employees at enterprise branch offices and employees on the move can remotely access the headquarters through virtual tunnels over the Internet.
In a Client-Initiated VPN, a tunnel is established between each access user and the LNS. Each tunnel carries only one L2TP session and PPP connection.
L2TP dial-up procedure
- When a user initiates a connection to the LNS, the establishment of an L2TP tunnel between the LNS and the user is triggered.
- An L2TP session is created for the user in the tunnel established in step 1.
- The LNS authenticates the user.
- A PPP connection is set up between the user and the LNS.
- The user can access intranet resources through the PPP connection to the LNS.
When PC_A communicates with PC_B over the GRE tunnel, FW_A and FW_B forward packets as follows:
- After receiving the original packet sent by PC_A to PC_B, FW_A searches its routing table for a matching route.
- According to the search results, FW_A sends the packet to the tunnel interface for GRE encapsulation. The tunnel interface adds a GRE header and then a new outer IP header.
- FW_A searches its routing table again for a route to the destination address (2.2.2.2) in the new IP header of the GRE packet.
- FW_A forwards the GRE packet over the matching route.
- After receiving the GRE packet, FW_B determines whether or not the packet is a GRE packet. The new IP header in the GRE packet has the Protocol field. If the Protocol field value is 47, the packet is a GRE packet, in which case FW_B forwards the packet to the tunnel interface for decapsulation. The tunnel interface removes the outer IP header and GRE header to restore the original packet. If the packet is not a GRE packet, FW_B forwards the packet as a common packet.
- FW_B searches its routing table for a route to the destination address of the original packet and then forwards the packet over the route.
Both the L2TP VPN and GRE VPN transmit data in plaintext, failing to ensure security for users or enterprises.
IPsec can be deployed to protect IP packets transmitted over an insecure network to reduce the risk of information leakage.
AH provides data origin authentication, data integrity check, and anti-replay, but does not provide encryption.
ESP is mainly used to encrypt data, authenticate the origin of data, verify data integrity, and prevent packet replay.
Security functions provided by AH and ESP depend on the authentication and encryption algorithms used by IPsec.
The keys used for IPsec encryption and authentication can be manually configured or dynamically negotiated using the Internet Key Exchange (IKE) protocol. In this class, I will describe how to establish an IPsec tunnel manually.
An SA defines a set of parameters for data transmission between two IPsec peers, including the security protocol, characteristics of data flows to be protected, data encapsulation mode, encryption algorithm, authentication algorithm, key exchange method, IKE, and SA lifetime.
An SA is identified by three parameters: security parameter index (SPI), destination IP address, and security protocol ID (AH or ESP).
In transport mode, the IP header is not changed, so the source and destination addresses of an IPsec tunnel must be the same as those in the IP header. This encapsulation mode applies only to communication between two hosts or between a host and a VPN gateway.
Tunnel mode applies to communication between two VPN gateways or between a host and a VPN gateway.
The two encapsulation modes differ as follows:
- Tunnel mode is more secure than the transport mode. It can completely authenticate and encrypt original IP packets, hiding the IP addresses, protocol types, and port numbers in original IP packets.
- Tunnel mode occupies more bandwidth because of an extra IP header.
Internet Key Exchange (IKE) is based on the framework defined by Internet Security Association and Key Management Protocol (ISAKMP). It is a UDP-based application layer protocol that provides keys for data encryption. It simplifies the use, management, configuration, and maintenance of IPsec.
After an IKE SA is established between IPsec peers to complete identity authentication and key exchange, a pair of IPsec SAs is negotiated based on configured parameters, such as the AH or ESP protocol. Subsequently, data is encrypted and transmitted between the peers in an IPsec tunnel.
IPsec uses symmetric encryption algorithms to encrypt and decrypt data.
The authentication mechanism allows the data receiver to identify the data sender in IP communications and determines whether data is tampered with during transmission.
IPsec uses the Keyed-Hash Message Authentication Code (HMAC) function for authentication. The HMAC function verifies the integrity and authenticity of data packets by comparing digital signatures.
IPsec implements encryption for secure transmission. However, IPsec encryption and authentication have problems in some scenarios, for example, NAT traversal. Because of its unique attributes, the SSL VPN takes effect only at the application layer and does not require a user security VPN client. Therefore, its application scope is wider, and it is more convenient.
SSL provides secure connections for HTTP and is widely used in various fields, such as ecommerce and online banking, to ensure secure data transmission.
User authentication: The virtual gateway authenticates the client identity.
Web proxy: implements clientless web access, fully reflecting how easy the SSL VPN is to use and distinguishes the SSL VPN from other VPNs. It forwards the page request (HTTPS) of a remote browser to the web server, and then sends the response of the server to the end user. In this way, it implements URL permission control, (controlling access to a specific page). The implementation of the web proxy includes web rewriting and web link.
File sharing: enables users to access the shared resources on different server systems (such as Windows systems that support SMB and Linux systems that support NFS) through web pages. It supports the SMB (Windows) and NFS (Linux) protocols.
Port forwarding: used in scenarios (such as in the C/S architecture) where access using web technologies is not supported.
Network extension: assigns an intranet IP address to a remote client, allowing it to access any intranet resources as if it were on the intranet. Different access rights to the Internet and local subnets are provided in different access modes. Access modes include full tunnel, split tunnel, and manual tunnel.
In this example, the dial-up user name is user001 and the password is Admin@123.
After L2TP is configured, configure a security policy to allow users to communicate with intranet servers and allow L2TP packets to pass through.
Configure a security policy to allow Network 1 and Network 2 to communicate and allow GRE packets to pass through.
Configure FW_B with reference to FW_A.
Ref : [1]