A connection between two computers or other endpoints in which packets sent over a shared network, for example, the Internet, are automatically encrypted and decrypted by the endpoints. Although the packets are carried on a shared network, their contents are protected from unauthorized access between the endpoints. Virtual private networks are commonly used to connect branch offices to a headquarters when the cost of a physically separate communications link cannot be justified, or to allow workers to access their company network across the Internet when they are not on the premises. VPNs may use proprietary or standard protocols, for example IPSec; endpoints may be dedicated hardware devices or software installed on personal computers or routers.