*
*/
+#define VPN_FLAG_NO_TUN 1
+
enum vpn_state {
VPN_STATE_UNKNOWN = 0,
VPN_STATE_IDLE = 1,
VPN_STATE_READY = 3,
VPN_STATE_DISCONNECT = 4,
VPN_STATE_FAILURE = 5,
+ VPN_STATE_AUTH_FAILURE = 6,
};
struct vpn_driver {
+ int flags;
int (*notify) (DBusMessage *msg, struct connman_provider *provider);
int (*connect) (struct connman_provider *provider,
struct connman_task *task, const char *if_name);
void (*disconnect) (void);
+ int (*error_code) (int exit_code);
+ int (*save) (struct connman_provider *provider, GKeyFile *keyfile);
};
int vpn_register(const char *name, struct vpn_driver *driver,
const char *program);
void vpn_unregister(const char *provider_name);
-void vpn_died(struct connman_task *task, void *user_data);
+void vpn_died(struct connman_task *task, int exit_code, void *user_data);
+int vpn_set_ifname(struct connman_provider *provider, const char *ifname);