doc: Clarify UserRoutes and ServerRoutes documentation
[platform/upstream/connman.git] / doc / vpn-connection-api.txt
1 vpn connection
2 ==============
3
4 Service         net.connman.vpn
5 Interface       net.connman.vpn.Connection
6 Object path     [variable prefix]/{connection0,connection1,...}
7
8 Method          void SetProperty(string name, variant value) [experimental]
9
10                         Changes the value of the specified property. Only
11                         properties that are listed as read-write are
12                         changeable. On success a PropertyChanged signal
13                         will be emitted.
14
15                         Possible Errors: [connection].Error.InvalidArguments
16                                          [connection].Error.InvalidProperty
17
18                 void ClearProperty(string name) [experimental]
19
20                         Clears the value of the specified property.
21
22                         Possible Errors: [connection].Error.InvalidArguments
23                                          [connection].Error.InvalidProperty
24
25                 void Connect() [experimental]
26
27                         Connect this VPN connection. It will attempt to connect
28                         to the VPN connection. The Connect() will wait until
29                         the connection is created or there is an error. The
30                         error description is returned in dbus error.
31
32                         Possible Errors: [connection].Error.InvalidArguments
33                                         [connection].Error.InProgress
34
35                 void Disconnect() [experimental]
36
37                         Disconnect this VPN connection. If the connection is
38                         not connected an error message will be generated.
39
40                         Possible Errors: [connection].Error.InvalidArguments
41
42 Signals         PropertyChanged(string name, variant value) [experimental]
43
44                         This signal indicates a changed value of the given
45                         property.
46
47 Properties      string State [readonly]
48
49                         The connection state information.
50
51                         Valid states are "idle", "failure", "configuration",
52                         "ready", "disconnect".
53
54                 string Type [readonly]
55
56                         The VPN type (for example "openvpn", "vpnc" etc.)
57
58                 string Name [readonly]
59
60                         The VPN name.
61
62                 string Domain [readonly]
63
64                         The domain name used behind the VPN connection.
65                         This is optional for most VPN technologies.
66
67                 string Host [readonly]
68
69                        The VPN host (server) address.
70
71                 int Index [readonly]
72
73                         The index of the VPN network tunneling interface.
74                         If there is no tunneling device, then this value
75                         is not returned.
76
77                 dict IPv4 [readonly]
78
79                         string Address
80
81                                 The current configured IPv4 address.
82
83                         string Netmask
84
85                                The current configured IPv4 netmask.
86
87                         string Gateway
88
89                                The current configured IPv4 gateway.
90
91                         string Peer
92
93                                The current configured VPN tunnel endpoint
94                                IPv4 address.
95
96                 dict IPv6 [readonly]
97
98                         string Address
99
100                                 The current configured IPv6 address.
101
102                         string PrefixLength
103
104                                The prefix length of the IPv6 address.
105
106                         string Gateway
107
108                                The current configured IPv6 gateway.
109
110                         string Peer
111
112                                The current configured VPN tunnel endpoint
113                                IPv6 address.
114
115                 array{string} Nameservers [readonly]
116
117                         The list of nameservers set by VPN.
118
119                 array{dict} UserRoutes [readwrite]
120
121                         int ProtocolFamily
122
123                                 Protocol family of the route. Set to 4
124                                 if IPv4 and 6 if IPv6 route.
125
126                         string Network
127
128                                 The network part of the route.
129
130                         string Netmask
131
132                                 The netmask of the route.
133
134                         string Gateway
135
136                                 Gateway address of the route.
137
138                         The list of currently active user activated
139                         routes.
140
141                 array{dict} ServerRoutes [readonly]
142
143                         int ProtocolFamily
144
145                                 Protocol family of the route. Set to 4
146                                 if IPv4 and 6 if IPv6 route.
147
148                         string Network
149
150                                 The network part of the route.
151
152                         string Netmask
153
154                                 The netmask of the route.
155
156                         string Gateway
157
158                                 Gateway address of the route.
159
160                         The VPN server activated route. These routes
161                         are pushed to connman by VPN server.
162
163                 There can be other properties also but as the VPN
164                 technologies are so different, they have different
165                 kind of options that they need, so not all options
166                 are mentioned in this document.