org.freedesktop.NetworkManager.VPN.Plugin

org.freedesktop.NetworkManager.VPN.Plugin — VPN Service

Methods

Connect            (IN  a{sa{sv}} connection);
ConnectInteractive (IN  a{sa{sv}} connection,
                    IN  a{sv}     details);
NeedSecrets        (IN  a{sa{sv}} settings,
                    OUT s         setting_name);
Disconnect         ();
SetConfig          (IN  a{sv}     config);
SetIp4Config       (IN  a{sv}     config);
SetIp6Config       (IN  a{sv}     config);
SetFailure         (IN  s         reason);
NewSecrets         (IN  a{sa{sv}} connection);

Signals

StateChanged    (u     state);
SecretsRequired (s     message,
                 as    secrets);
Config          (a{sv} config);
Ip4Config       (a{sv} ip4config);
Ip6Config       (a{sv} ip6config);
LoginBanner     (s     banner);
Failure         (u     reason);

Properties

State  readable   u

Description

This interface is provided by plugins providing VPN services to the NetworkManager daemon.

Method Details

The Connect() method

Connect (IN  a{sa{sv}} connection);

Tells the plugin to connect. Interactive secrets requests (eg, emitting the SecretsRequired signal) are not allowed.

IN a{sa{sv}} connection:

Describes the connection to be established.


The ConnectInteractive() method

ConnectInteractive (IN  a{sa{sv}} connection,
                    IN  a{sv}     details);

Tells the plugin to connect, allowing interactive secrets requests (eg the plugin is allowed to emit the SecretsRequired signal if the VPN service indicates that it needs additional secrets during the connect process).

IN a{sa{sv}} connection:

Describes the connection to be established.

IN a{sv} details:

Additional details about the Connect process.


The NeedSecrets() method

NeedSecrets (IN  a{sa{sv}} settings,
             OUT s         setting_name);

Asks the plugin whether the provided connection will require secrets to connect successfully.

IN a{sa{sv}} settings:

Describes the connection that may need secrets.

OUT s setting_name:

The setting name within the provided connection that requires secrets, if any.


The Disconnect() method

Disconnect ();

Disconnect the plugin.


The SetConfig() method

SetConfig (IN  a{sv} config);

Set generic connection details on the connection.

IN a{sv} config:

Generic configuration details for the connection.


The SetIp4Config() method

SetIp4Config (IN  a{sv} config);

Set IPv4 details on the connection.

IN a{sv} config:

Ip4Config details for the connection. You must call SetConfig() before calling this.


The SetIp6Config() method

SetIp6Config (IN  a{sv} config);

Set IPv6 details on the connection.

IN a{sv} config:

Ip6Config details for the connection. You must call SetConfig() before calling this.


The SetFailure() method

SetFailure (IN  s reason);

Indicate a failure to the plugin.

IN s reason:

The reason for the failure.


The NewSecrets() method

NewSecrets (IN  a{sa{sv}} connection);

Called in response to a SecretsRequired signal to deliver updated secrets or other information to the plugin.

IN a{sa{sv}} connection:

Describes the connection including the new secrets.

Signal Details

The "StateChanged" signal

StateChanged (u state);

Emitted when the plugin state changes.

u state:

(NMVpnServiceState) The new state of the plugin.


The "SecretsRequired" signal

SecretsRequired (s  message,
                 as secrets);

Emitted during an ongoing ConnectInteractive() request when the plugin has determined that new secrets are required. NetworkManager will then call the NewSecrets() method with a connection hash including the new secrets.

s message:

Informational message, if any, about the request. For example, if a second PIN is required, could indicate to the user to wait for the token code to change until entering the next PIN.

as secrets:

Array of strings of VPN secret names which the plugin thinks secrets may be required for, or other VPN-specific data to be processed by the VPN's front-end.


The "Config" signal

Config (a{sv} config);

The plugin obtained generic configuration information.

a{sv} config:

The configuration information.


The "Ip4Config" signal

Ip4Config (a{sv} ip4config);

The plugin obtained an IPv4 configuration.

a{sv} ip4config:

The IPv4 configuration.


The "Ip6Config" signal

Ip6Config (a{sv} ip6config);

The plugin obtained an IPv6 configuration.

a{sv} ip6config:

The IPv6 configuration.


The "LoginBanner" signal

LoginBanner (s banner);

Emitted when the plugin receives a login banner from the VPN service.

s banner:

The login banner string.


The "Failure" signal

Failure (u reason);

Emitted when a failure in the VPN plugin occurs.

u reason:

(NMVpnPluginFailure) Reason code for the failure.

Property Details

The "State" property

State  readable   u

The state of the plugin.

Returns: NMVpnServiceState