---
title: NEVPNProtocol
framework: networkextension
role: symbol
role_heading: Class
path: networkextension/nevpnprotocol
---

# NEVPNProtocol

Settings common to both IKEv2 and IPsec VPN configurations.

## Declaration

```swift
class NEVPNProtocol
```

## Mentioned in

Routing your VPN network traffic

## Overview

Overview The NEVPNProtocol class is an abstract base class with one subclass for each type of supported VPN configuration. This class provides properties for configuring the VPN, authenticating network connections, and routing network traffic. You can include all network traffic, with some exceptions, and selectively exclude types of network traffic. Instances of this class are thread-safe.

## Topics

### Configuring the VPN

- [serverAddress](networkextension/nevpnprotocol/serveraddress.md)
- [disconnectOnSleep](networkextension/nevpnprotocol/disconnectonsleep.md)
- [proxySettings](networkextension/nevpnprotocol/proxysettings.md)

### Authenticating the user

- [username](networkextension/nevpnprotocol/username.md)
- [passwordReference](networkextension/nevpnprotocol/passwordreference.md)
- [identityReference](networkextension/nevpnprotocol/identityreference.md)
- [identityData](networkextension/nevpnprotocol/identitydata.md)
- [identityDataPassword](networkextension/nevpnprotocol/identitydatapassword.md)

### Routing network traffic

- [includeAllNetworks](networkextension/nevpnprotocol/includeallnetworks.md)
- [excludeAPNs](networkextension/nevpnprotocol/excludeapns.md)
- [excludeCellularServices](networkextension/nevpnprotocol/excludecellularservices.md)
- [excludeLocalNetworks](networkextension/nevpnprotocol/excludelocalnetworks.md)
- [enforceRoutes](networkextension/nevpnprotocol/enforceroutes.md)

### Instance Properties

- [excludeDeviceCommunication](networkextension/nevpnprotocol/excludedevicecommunication.md)
- [sliceUUID](networkextension/nevpnprotocol/sliceuuid.md)

## Relationships

### Inherits From

- [NSObject](objectivec/nsobject-swift.class.md)

### Inherited By

- [NEDNSProxyProviderProtocol](networkextension/nednsproxyproviderprotocol.md)
- [NETunnelProviderProtocol](networkextension/netunnelproviderprotocol.md)
- [NEVPNProtocolIPSec](networkextension/nevpnprotocolipsec.md)

### Conforms To

- [CVarArg](swift/cvararg.md)
- [CustomDebugStringConvertible](swift/customdebugstringconvertible.md)
- [CustomStringConvertible](swift/customstringconvertible.md)
- [Equatable](swift/equatable.md)
- [Hashable](swift/hashable.md)
- [NSCoding](foundation/nscoding.md)
- [NSCopying](foundation/nscopying.md)
- [NSObjectProtocol](objectivec/nsobjectprotocol.md)
- [NSSecureCoding](foundation/nssecurecoding.md)

## See Also

### VPN configuration

- [NEVPNManager](networkextension/nevpnmanager.md)
- [NEVPNProtocolIKEv2](networkextension/nevpnprotocolikev2.md)
- [NEVPNProtocolIPSec](networkextension/nevpnprotocolipsec.md)
- [VPN On Demand Rules](networkextension/vpn-on-demand-rules.md)
