Internet protocol security (IPSec) is a protocol suite that authenticates and encrypts IP packets between communicating devices. It operates at the network layer and is transparent to applications. IPSec uses two security protocols: the Authentication Header protocol (AH) which provides data integrity and authentication, and the Encapsulating Security Payload (ESP) protocol which provides confidentiality, integrity, and authentication. IPSec can operate in either transport mode between hosts or tunnel mode between gateways to provide a virtual private network.