Imported Upstream version 1.35
[platform/upstream/connman.git] / doc / connman-vpn-provider.config.5.in
1 .\" connman-vpn-provider.config(5) manual page
2 .\"
3 .\" Copyright (C) 2015 Intel Corporation
4 .\"
5 .TH "connection_name.config" "5" "2015-10-15" ""
6 .SH NAME
7 connection_name.config \- ConnMan vpn connection provisioning file
8 .SH SYNOPSIS
9 .B @vpn_storagedir@/\fIconnection-name\fB.config
10 .SH DESCRIPTION
11 .P
12 \fIConnMan\fP's vpn connections are configured with so called
13 "\fBprovisioning files\fP" which reside under \fI@vpn_storagedir@/\fP.
14 The files can be named anything, as long as they contain only printable
15 ascii characers, for example letters, numbers and underscores. The file
16 must end with \fB.config\fP. Each VPN connection requires a provisioning
17 file, but multiple connections can be specified in the same file.
18 .SH "FILE FORMAT"
19 .P
20 The configuration file format is key file format.
21 It consists of sections (groups) of key-value pairs.
22 Lines beginning with a '#' and blank lines are considered comments.
23 Sections are started by a header line containing the section enclosed
24 in '[' and ']', and ended implicitly by the start of the next section
25 or the end of the file. Each key-value pair must be contained in a section.
26 .P
27 Description of sections and available keys follows:
28 .SS [global]
29 This section is optional, and can be used to describe the actual file. The
30 two allowed fields for this section are:
31 .TP
32 .BI Name= name
33 Name of the network.
34 .TP
35 .BI Description= description
36 Description of the network.
37 .SS [provider_*]
38 Each provisioned connection must start with a [provider_*] tag,
39 with * replaced by an unique name within the file.
40 The following fields are mandatory:
41 .TP
42 .B Type=OpenConnect \fR|\fB OpenVPN \fR|\fB VPNC \fR|\fB L2TP \fR|\fB PPTP
43 Specifies the VPN type.
44 .TP
45 .BI Host= IP
46 VPN server IP address.
47 .TP
48 .BI Domain= domain
49 Domain name for the VPN service.
50 .TP
51 The following field is optional:
52 .TP
53 .BI Networks= network / netmask / gateway [,...]
54 Networks behind the VPN. If all traffic should go through the VPN, this
55 field can be left out. The gateway can be left out. For IPv6 addresses,
56 only the prefix length is accepted as the netmask.
57 .SS OpenConnect
58 The following keys can be used for \fBopenconnect\fP(8) networks:
59 .TP
60 .BI OpenConnect.ServerCert= cert
61 SHA1 fingerprint of the VPN server's certificate.
62 .TP
63 .BI OpenConnect.CACert= cert
64 File containing additional CA certificates in addition to the system
65 trusted certificate authorities.
66 .TP
67 .BI OpenConnect.ClientCert= cert
68 Client certificate, if needed by web authentication.
69 .TP
70 .BI OpenConnect.MTU= mtu
71 Request \fImtu\fP from the server as the MTU of the tunnel.
72 .TP
73 .BI OpenConnect.Cookie= cookie
74 The resulting cookie of the authentication process. As the cookie lifetime
75 can be very limited, it does not usually make sense to add it into the
76 configuration file.
77 .TP
78 .BI OpenConnect.VPNHost= host
79 The final VPN server to use after completing the web authentication. Only
80 usable for extremely simple VPN configurations and should normally be set
81 only via the VPN Agent API.
82 .PP
83 If \fBOpenConnect.Cookie\fP, \fBOpenConnect.VPNHost\fP or
84 \fBOpenConnect.ServerCert\fP are missing, the VPN Agent will be contacted
85 to supply the information.
86 .SS OpenVPN
87 The following keys are mandatory for \fBopenvpn\fP(8) networks:
88 .TP
89 .BI OpenVPN.CACert= cert
90 Certificate authority file.
91 .TP
92 .BI OpenVPN.Cert= cert
93 Local peer's signed certificate.
94 .TP
95 .BI OpenVPN.Cert= cert
96 Local peer's signed certificate.
97 .TP
98 .BI OpenVPN.Key= key
99 Local peer's private key.
100 .TP
101 The following keys are optional for \fBopenvpn\fP(8) networks:
102 .TP
103 .BI OpenVPN.MTU= mtu
104 MTU of the tunnel.
105 .TP
106 .B OpenVPN.NSCertType=client \fR|\fB server
107 Peer certificate type, either \fBclient\fP or \fBserver\fP.
108 .TP
109 .BI OpenVPN.Protocol= protocol
110 Use \fIprotocol\fP.
111 .TP
112 .BI OpenVPN.Port= port
113 TCP/UDP port number.
114 .TP
115 .B OpenVPN.AuthUserPass=true \fR|\fB false
116 Authenticate on the server using username/password.
117 .TP
118 .BI OpenVPN.AskPass= file
119 Get certificate password from \fIfile\fP.
120 .TP
121 .B OpenVPN.AuthNoCache=true \fR|\fB false
122 Don't cache AskPass or AuthUserPass value.
123 .TP
124 .BI OpenVPN.TLSRemote= name
125 Accept connections only from a host with X509 name or common
126 name equal to \fIname\fP.
127 .TP
128 .BI OpenVPN.TLSAuth= file
129 Use \fIfile\fP for HMAC authentication.
130 .TP
131 .BI OpenVPN.TLSAuthDir= direction
132 Use \fIdirection\fP for HMAC authentication direction.
133 .TP
134 .BI OpenVPN.Cipher= cipher
135 Use \fIcipher\fP as the cipher.
136 .TP
137 .B OpenVPN.Auth=true \fR|\fB false
138 Use HMAC authentication.
139 .TP
140 .B OpenVPN.CompLZO=yes \fR|\fB no \fR|\fB adaptive
141 Use fast LZO compression.
142 .TP
143 .B OpenVPN.RemoteCertTls=client \fR|\fB server
144 Require that remote certificate is signed based on RFC3280 TLS rules.
145 .TP
146 .BI OpenVPN.ConfigFile= file
147 OpenVPN config file for extra options not supported by the OpenVPN plugin.
148 .TP
149 .BI OpenVPN.DeviceType= tun \fR|\fB tap
150 Whether the VPN should use a tun (OSI layer 3) or tap (OSI layer 2) device.
151 Defaults to tun if omitted.
152 .SS VPNC
153 The following key is mandatory for \fBvpnc\fP(8) networks:
154 .TP
155 .BI VPNC.IPSec.ID= id
156 Group username.
157 .TP
158 The following keys are optional for \fBvpnc\fP(8) networks:
159 .TP
160 .BI VPNC.IPSec.Secret= secret
161 Group password.
162 .TP
163 .BI VPNC.XAuth.Username= username
164 Username.
165 .TP
166 .BI VPNC.XAuth.Password= password
167 Password.
168 .TP
169 .BI VPNC.IKE.Authmode= mode
170 IKE authentication mode.
171 .TP
172 .BI VPNC.IKE.DHGroup= group
173 IKE DH group name.
174 .TP
175 .BI VPNC.PFS= group
176 Diffie-Hellman group for perfect forward secrecy.
177 .TP
178 .BI VPNC.Domain= domain
179 Domain name for authentication.
180 .TP
181 .BI VPNC.Vendor= vendor
182 Vendor of the IPSec gateway.
183 .TP
184 .BI VPNC.LocalPort= port
185 Local ISAKMP port number to use.
186 .TP
187 .BI VPNC.CiscoPort= port
188 Cisco UDP Encapsulation Port.
189 .TP
190 .BI VPNC.AppVersion= version
191 Application version to report.
192 .TP
193 .BI VPNC.NATTMode= mode
194 NAT-Traversal Method to use.
195 .TP
196 .BI VPNC.DPDTimeout= timeout
197 DPD idle timeout.
198 .TP
199 .B VPNC.SingleDES=true \fR|\fB false
200 Enable single DES encryption.
201 .TP
202 .B VPNC.NoEncryption=true \fR|\fB false
203 Enable usage of no encryption for data traffic.
204 .TP
205 .BI VPNC.DeviceType= tun \fR|\fB tap
206 Whether the VPN should use a tun (OSI layer 3) or tap (OSI layer 2) device.
207 Defaults to tun if omitted.
208 .SS L2TP
209 The following keys are optional for l2tp (\fBxl2tp.conf\fP(5), \fBpppd\fP(8))
210 networks:
211 .TP
212 .BI L2TP.User= user
213 L2TP username.
214 .TP
215 .BI L2TP.Password= password
216 L2TP password.
217 .TP
218 .BI L2TP.BPS= bps
219 Max bandwidth to use.
220 .TP
221 .BI L2TP.TXBPS= bps
222 Max transmit bandwidth to use.
223 .TP
224 .BI L2TP.RXBPS= bps
225 Max receive bandwidth to use.
226 .TP
227 .B L2TP.LengthBit=yes \fR|\fB no
228 Use length bit.
229 .TP
230 .B L2TP.Challenge=yes \fR|\fB no
231 Use challenge authentication.
232 .TP
233 .BI L2TP.DefaultRoute= route
234 Add \fIroute\fP to the routing tables.
235 .TP
236 .B L2TP.FlowBit=yes \fR|\fB no
237 Use seq numbers.
238 .TP
239 .BI L2TP.TunnelRWS= size
240 Window size.
241 .TP
242 .B L2TP.Exclusive=yes \fR|\fB no
243 Use only one control channel.
244 .TP
245 .B L2TP.Redial=yes \fR|\fB no
246 Redial if disconnected.
247 .TP
248 .BI L2TP.RedialTimeout= timeout
249 Redial timeout.
250 .TP
251 .BI L2TP.MaxRedials= count
252 Maximum amount of redial tries.
253 .TP
254 .B L2TP.RequirePAP=yes \fR|\fB no
255 Require PAP.
256 .TP
257 .B L2TP.RequireCHAP=yes \fR|\fB no
258 Require CHAP.
259 .TP
260 .B L2TP.ReqAuth=yes \fR|\fB no
261 Require authentication.
262 .TP
263 .B L2TP.AccessControl=yes \fR|\fB no
264 Use access control.
265 .TP
266 .BI L2TP.AuthFile= file
267 Authentication file location.
268 .TP
269 .BI L2TP.ListenAddr= address
270 Listen address.
271 .TP
272 .B L2TP.IPSecSaref=yes \fR|\fB no
273 Listen address.
274 .TP
275 .BI L2TP.Port= port
276 UDP port used.
277 .TP
278 .BI PPPD.EchoFailure= count
279 Echo failure count.
280 .TP
281 .BI PPPD.EchoFailure= count
282 Dead peer check count.
283 .TP
284 .BI PPPD.EchoInterval= interval
285 Dead peer check interval.
286 .TP
287 .BI PPPD.Debug= level
288 Debug level.
289 .TP
290 .B PPPD.RefuseEAP=true \fR|\fB false
291 Refuse EAP authentication.
292 .TP
293 .B PPPD.RefusePAP=true \fR|\fB false
294 Refuse PAP authentication.
295 .TP
296 .B PPPD.RefuseCHAP=true \fR|\fB false
297 Refuse CHAP authentication.
298 .TP
299 .B PPPD.RefuseMSCHAP=true \fR|\fB false
300 Refuse MSCHAP authentication.
301 .TP
302 .B PPPD.RefuseMSCHAP2=true \fR|\fB false
303 Refuse MSCHAPv2 authentication.
304 .TP
305 .B PPPD.NoBSDComp=true \fR|\fB false
306 Disable BSD compression.
307 .TP
308 .B PPPD.NoPcomp=true \fR|\fB false
309 Disable protocol compression.
310 .TP
311 .B PPPD.UseAccomp=true \fR|\fB false
312 Disable Access/Control compression.
313 .TP
314 .B PPPD.NoDeflate=true \fR|\fB false
315 Disable deflate compression.
316 .TP
317 .B PPPD.ReqMPPE=true \fR|\fB false
318 Require the use of MPPE.
319 .TP
320 .B PPPD.ReqMPPE40=true \fR|\fB false
321 Require the use of MPPE 40 bit.
322 .TP
323 .B PPPD.ReqMPPE128=true \fR|\fB false
324 Require the use of MPPE 128 bit.
325 .TP
326 .B PPPD.ReqMPPEStateful=true \fR|\fB false
327 Allow MPPE to use stateful mode.
328 .TP
329 .B PPPD.NoVJ=true \fR|\fB false
330 No Van Jacobson compression.
331 .SS PPTP
332 The following keys are optional for \fBpptp\fP(8) (see also \fBpppd\fP(8))
333 networks:
334 .TP
335 .BI PPTP.User= username
336 Username.
337 .TP
338 .BI PPTP.Password= password
339 Password.
340 .TP
341 .BI PPPD.EchoFailure= count
342 Echo failure count.
343 .TP
344 .BI PPPD.EchoFailure= count
345 Dead peer check count.
346 .TP
347 .BI PPPD.EchoInterval= interval
348 Dead peer check interval.
349 .TP
350 .BI PPPD.Debug= level
351 Debug level.
352 .TP
353 .B PPPD.RefuseEAP=true \fR|\fB false
354 Refuse EAP authentication.
355 .TP
356 .B PPPD.RefusePAP=true \fR|\fB false
357 Refuse PAP authentication.
358 .TP
359 .B PPPD.RefuseCHAP=true \fR|\fB false
360 Refuse CHAP authentication.
361 .TP
362 .B PPPD.RefuseMSCHAP=true \fR|\fB false
363 Refuse MSCHAP authentication.
364 .TP
365 .B PPPD.RefuseMSCHAP2=true \fR|\fB false
366 Refuse MSCHAPv2 authentication.
367 .TP
368 .B PPPD.NoBSDComp=true \fR|\fB false
369 Disable BSD compression.
370 .TP
371 .B PPPD.NoPcomp=true \fR|\fB false
372 Disable protocol compression.
373 .TP
374 .B PPPD.UseAccomp=true \fR|\fB false
375 Disable Access/Control compression.
376 .TP
377 .B PPPD.NoDeflate=true \fR|\fB false
378 Disable deflate compression.
379 .TP
380 .B PPPD.ReqMPPE=true \fR|\fB false
381 Require the use of MPPE.
382 .TP
383 .B PPPD.ReqMPPE40=true \fR|\fB false
384 Require the use of MPPE 40 bit.
385 .TP
386 .B PPPD.ReqMPPE128=true \fR|\fB false
387 Require the use of MPPE 128 bit.
388 .TP
389 .B PPPD.ReqMPPEStateful=true \fR|\fB false
390 Allow MPPE to use stateful mode.
391 .TP
392 .B PPPD.NoVJ=true \fR|\fB false
393 No Van Jacobson compression.
394
395 .SH "EXAMPLE"
396 This is a configuration file for a VPN providing L2TP, OpenVPN and
397 OpenConnect services. It could, for example, be in the file
398 .B @vpn_storagedir@/example.config\fR.
399 .PP
400 .nf
401 [global]
402 Name = Example
403 Description = Example VPN configuration
404
405 [provider_l2tp]
406 Type = L2TP
407 Name = Connection to corporate network
408 Host = 1.2.3.4
409 Domain = corporate.com
410 Networks = 10.10.30.0/24
411 L2TP.User = username
412
413 [provider_openconnect]
414 Type = OpenConnect
415 Name = Connection to corporate network using Cisco VPN
416 Host = 7.6.5.4
417 Domain = corporate.com
418 Networks = 10.10.20.0/255.255.255.0/10.20.1.5,192.168.99.1/24,2001:db8::1/64
419 OpenConnect.ServerCert = 263AFAB4CB2E6621D12E90182008AEF44AEFA031
420 OpenConnect.CACert = /etc/certs/certificate.p12
421
422 [provider_openvpn]
423 Type = OpenVPN
424 Name = Connection to corporate network using OpenVPN
425 Host = 3.2.5.6
426 Domain = my.home.network
427 OpenVPN.CACert = /etc/certs/cacert.pem
428 OpenVPN.Cert = /etc/certs/cert.pem
429 OpenVPN.Key = /etc/certs/cert.key
430 .fi
431 .SH "SEE ALSO"
432 .BR connmanctl (1),\  connman (8),\  connman-vpn (8)