static int oc_connect(struct connman_provider *provider,
struct connman_task *task, const char *if_name)
{
- const char *vpnhost, *vpncookie, *cafile, *mtu;
+ const char *vpnhost, *vpncookie, *cafile, *certsha1, *mtu;
int fd, err;
vpnhost = connman_provider_get_string(provider, "Host");
return -EINVAL;
}
+ certsha1 = connman_provider_get_string(provider,
+ "OpenConnect.ServerCert");
+ if (certsha1)
+ connman_task_add_argument(task, "--servercert",
+ (char *)certsha1);
+
cafile = connman_provider_get_string(provider, "OpenConnect.CACert");
mtu = connman_provider_get_string(provider, "VPN.MTU");
print "Attempting to connect service %s" % (sys.argv[3])
if sys.argv[1] == "openconnect":
- if (len(sys.argv) > 5):
+ if (len(sys.argv) > 6):
path = manager.ConnectProvider(({ "Type": "openconnect",
"Name": sys.argv[2],
"Host": sys.argv[3],
"VPN.Domain": sys.argv[4],
"OpenConnect.Cookie": sys.argv[5],
- "OpenConnect.CACert": sys.argv[6]}))
+ "OpenConnect.ServerCert": sys.argv[6]}))
else:
path = manager.ConnectProvider(({ "Type": "openconnect",
"Name": sys.argv[2],