]> www.infradead.org Git - users/dwmw2/openconnect.git/commitdiff
Fortinet: explain to the user if connecting to an ancient server that doesn't support...
authorDaniel Lenski <dlenski@gmail.com>
Thu, 4 Feb 2021 01:58:00 +0000 (17:58 -0800)
committerDaniel Lenski <dlenski@gmail.com>
Mon, 29 Mar 2021 03:13:30 +0000 (20:13 -0700)
Signed-off-by: Daniel Lenski <dlenski@gmail.com>
fortinet.c

index 126324e765420d09e98013c94ee85c2db45fd054..b5aa42fee5960e89b3f29db1748899fc79b8e520 100644 (file)
@@ -294,8 +294,12 @@ int fortinet_connect(struct openconnect_info *vpninfo)
        free(vpninfo->urlpath);
        vpninfo->urlpath = strdup("remote/fortisslvpn_xml");
        ret = do_https_request(vpninfo, "GET", NULL, NULL, &res_buf, 0);
-       if (ret < 0)
+       if (ret < 0) {
+               if (ret == -EPERM)
+                       vpn_progress(vpninfo, PRG_ERR,
+                                    _("Server doesn't support XML config format, only ancient HTML. Not currently implemented.\n"));
                goto out;
+       }
 
        ret = parse_fortinet_xml_config(vpninfo, res_buf, ret, &ipv4, &ipv6);
        if (ret)