Policy > Networking > Network Services > VPN > IPSEC > Sessions

Create or patch an IPSec VPN session (Deprecated)

Create or patch an IPSec VPN session for a given locale
service under Tier-1.
This API is deprecated. Please use PATCH /infra/tier-1s/<tier-1-id>/ipsec-vpn-services/<service-id>/sessions/<session-id> instead.
Note:
Please note that request is validated and any error messages returned from validation may include the new VPN path
instead of the deprecated path. Both new path and old path refer to same resource.
Also VPN path returned in the Alarm, GPRR payload may include the new VPN path

Request:

Method:
PATCH
URI Path(s):
/policy/api/v1/infra/tier-1s/<tier-1-id>/locale-services/<locale-service-id>/ipsec-vpn-services/<service-id>/sessions/<session-id>
Request Headers:
n/a
Query Parameters:
n/a
Request Body:
PolicyBasedIPSecVpnSession+
RouteBasedIPSecVpnSession+

Example Request:

PATCH https://<policy-mgr>/policy/api/v1/infra/tier-1s/int_net/locale-services/default/ipsec-vpn-services/default/sessions/pbs-1 { "resource_type": "PolicyBasedIPSecVpnSession", "description": "Policy based vpn session 1", "display_name": "pbs-1", "enabled" : true, "connection_initiation_mode" : "INITIATOR", "authentication_mode" : "PSK", "tunnel_profile_path" : "/infra/ipsec-vpn-tunnel-profiles/custom-tunnel-profile", "dpd_profile_path" : "/infra/ipsec-vpn-dpd-profiles/custom-dpd-profile", "ike_profile_path" : "/infra/ipsec-vpn-ike-profiles/custom-ike-profile", "local_endpoint_path" : "/infra/tier-1s/int_net/locale-services/default/ipsec-vpn-services/default/local-endpoints/default-le", "psk" : "test", "peer_address" : "2.1.4.1", "peer_id" : "2.1.4.1", "rules" : [ { "resource_type": "IPSecVpnRule", "id": "custom-rule-1", "sources": [ { "subnet" : "10.0.2.0/24" }, { "subnet" : "10.0.1.0/24" } ], "destinations" : [ { "subnet" : "10.1.1.0/24" } ], "enabled" : true, "logged" : true, "action": "PROTECT" } ] }

Successful Response:

Response Code:
200 OK
Response Headers:
n/a
Response Body:
n/a

Required Permissions:

crud

Feature:

policy_vpn

Additional Errors: