AH
Authentication Header
Protocol Guarantes integrity (connectionless) and authentication of the source of the data. Does not guarantee confidentiality.
SPI: Security assaciation for this datagram (session id and how to verify signature)
Is inserted between IP header and payload.
Routers process datagrams as always, but NAT has problems with it.

ESP
Encapsulating Security Payload
Guarantees authenticity of source, integrity and privacy to IP packets: authenticates and encrypts packet payload.

IKE
Internet Key Exchange Protocol
A IKE SA must be established between A and B to negotiate about the secret keys used in the child SA.
IKE allows preshared secret keys or certificates.
ISAKMP
Internet Security Association Key Management Protocol
It’s an IKE sub-protocol to rinegotiate secrets keys periodically in a secure way.
IPSec VPNs
IPsec tunnel between VPN gateways.
Provides encryption, authentication, encapsulation.
Modes of operation:
IPsec does not define which algorithms should be used to authenticate and encrypt the connection, the two parties agree upon the above negotiating.

Why VPN?
Virtual Private Networks reduce costs:
VPN enables selective and flexible access tocorporate network (services):
Access/Remote/Dial-in VPN
One of two VPN flavors.
Authentication/Authorization: performed by vpn gw; policies and info of the corp. network.
Address allocation: corp. addr. dynamically allocated, same address as when directly connected.
Security: by vpn gateway if customer provisioned, by provider otherwise.
Site-to-Site VPN
One of two VPN flavors.
Intranet VPN
One of two deployment scenarios.
Interconnection of corporate headquarters, remote offices, branch offices, telecommuter, traveling employee

Extranet VPN
One of two deployment scenarios.
Interconnection of customers, suppliers, partners, or communities of interest to a corporate intranet

Extranet VPN specific issues
Centralized internet access
Remote branches/users access public IP network only to reach headquarters.
Internet access only from HQ.
VPN carries also traffic to and from the internet.
Centralized access control (firewall)

Distributed internet access
Remote branches/users access the internet through their ip network connection.
VPN is deployed only for corporate traffic.

Deployment models
Internet Access types
VPN Flavors
Deployment Scenarios
Overlay Model
Deployment model.
The public network does not participate in realizing the VPN, it just provides means of communication between them.
Each VPN GW knows every other VPN GW.
Routing is performed by the VPN Gateways.
Peer Model
Each VPN gateway interacts with a public router (its peer):

VPN Provision
Customer Provisioned
Customer (from SP POV), builds and manages the VPN by theirself, tunnels are instantiated between Customer Edges (CE).

Provider Provisioned
Provider implements the solution: owns, configures, mangages devices implementing vpn functionalities.
Traffic belonging to different vpns is separated by the provider devices.
CE may behave as if they were connected to a private network.
PE terminates tunnels.

VPN Components

VPN Topologies
Hub and spoke:
Mesh: