Openconnect works fine via the command line.
$ sudo openconnect foo.com/bar POST https://foo.com/bar Attempting to connect to server 18.104.22.168:443 Connected to 22.214.171.124:443 SSL negotiation with foo.com Connected to HTTPS on foo.com Got HTTP response: HTTP/1.1 200 OK Content-Type: text/html; charset=utf-8 Transfer-Encoding: chunked Cache-Control: no-cache Pragma: no-cache Connection: Keep-Alive Date: Fri, 04 Aug 2017 08:28:32 GMT X-Frame-Options: SAMEORIGIN X-Aggregate-Auth: 1 HTTP body chunked (-2) XML POST enabled Please enter your username and password. Username:baz Password:
However, it fails via network manager. I click to connect to the VPN, which brings up a window. I then click the "connect" icon again, and I'm presented with
Failed to find or parse web form in login page. The log is as follows.
GET https://foo.com/bar Attempting to connect to server 126.96.36.199:443 Connected to 188.8.131.52:443 SSL negotiation with foo.com Connected to HTTPS on foo.com Got HTTP response: HTTP/1.0 200 OK Content-Length: 110 Cache-Control: no-cache Pragma: no-cache Connection: Close Date: Fri, 04 Aug 2017 08:31:22 GMT HTTP body length: (110) Failed to find or parse web form in login page
There are a few differences, e.g.
Content-Type. I'm not sure if this is important. Here is the NetworkManager config file:
$ sudo cat /etc/NetworkManager/system-connections/foo_VPN [connection] id=foo_VPN uuid=<random string> type=vpn permissions=user:sparhawk:; [vpn] autoconnect-flags=0 certsigs-flags=0 cookie-flags=2 enable_csd_trojan=no gateway=foo.cam/bar gateway-flags=2 gwcert-flags=2 lasthost-flags=0 pem_passphrase_fsid=no protocol=nc xmlconfig-flags=0 service-type=org.freedesktop.NetworkManager.openconnect [ipv4] dns-search= method=auto [ipv6] addr-gen-mode=stable-privacy dns-search= method=auto
I'm using an up-to-date Arch Linux, with
networkmanager-openconnect installed. I'm using KDE Plasma, if relevant.