openconnect 8.02 can't connect to Cisco RV340 VPN SSL - Failed to read from SSL socket: Success
I try to connect to a VPN SSL on our Cisco RV340 Router.
I also downloaded the official Cisco Anyconnect Client and I am ablt to connect with the same settings I am using for the connection with openconnect.
I am using the following openconnect version:
openconnect -V
OpenConnect version v8.02-1build1
Using GnuTLS. Features present: TPMv2, PKCS#11, RSA software token, HOTP software token, TOTP software token, Yubikey OATH, System keys, DTLS, ESP
Supported protocols: anyconnect (default), nc, gp
My System is a Ubuntu 19.10
uname -a
Linux XPS-15-9570 5.3.0-19-generic #20-Ubuntu SMP Fri Oct 18 09:04:39 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
When I try to connect I always get the error
Failed to read from SSL socket: Success.
Error fetching HTTPS
Failed to obtain WebVPN cookie
Here is the complete output. Confidential data is masked
openconnect -b -vvvvv --dump-http-traffic --user=XXXX https://myserver.com:8443
POST https://myserver.com:8443/
Attempting to connect to server myserver.com:8443
Connected to myserver.com:8443
SSL negotiation with myserver.com
Server certificate verify failed: signer not found
Certificate from VPN server "myserver.com" failed verification.
Reason: signer not found
To trust this server in future, perhaps add this to your command line:
--servercert pin-sha256:jOfIpq4BtLnaNQ9/I3hyRsZiVvutHo4rcsRCipmlm7Y=
Enter 'yes' to accept, 'no' to abort; anything else to view: yes
Connected to HTTPS on myserver.com
> POST / HTTP/1.1
> Host: myserver.com:8443
> User-Agent: Open AnyConnect VPN Agent v8.02-1build1
> Accept: */*
> Accept-Encoding: identity
> X-Transcend-Version: 1
> X-Aggregate-Auth: 1
> X-AnyConnect-Platform: linux-64
> X-Support-HTTP-Auth: true
> X-Pad: 000000000000000000000000000000000000
> Content-Type: application/x-www-form-urlencoded
> Content-Length: 220
>
> <?xml version="1.0" encoding="UTF-8"?>
> <config-auth client="vpn" type="init"><version who="vpn">v8.02-1build1</version><device-id>linux-64</device-id><group-access>https://myserver.com:8443</group-access></config-auth>
Got HTTP response: HTTP/1.1 303 See Other
Content-Type: text/html
Content-Length: 0
Location: https://myserver.com:8443/webvpn.html
Set-Cookie: webvpncontext=00000@SSLContext; path=/
Connection: Keep-Alive
HTTP body length: (0)
GET https://myserver.com:8443/
Attempting to connect to server myserver.com:8443
Connected to myserver.com:8443
SSL negotiation with myserver.com
Server certificate verify failed: signer not found
Connected to HTTPS on myserver.com
> GET / HTTP/1.1
> Host: myserver.com:8443
> User-Agent: Open AnyConnect VPN Agent v8.02-1build1
> Cookie: webvpncontext=00000@SSLContext
> Accept: */*
> Accept-Encoding: identity
> X-Transcend-Version: 1
> X-Support-HTTP-Auth: true
>
Got HTTP response: HTTP/1.1 200 OK
Cache-Control: max-age=0
Content-Type: text/html
Set-Cookie: webvpn=; expires=Thu, 01 Jan 1970 22:00:00 GMT; path=/
Set-Cookie: webvpncontext=00000@SSLContext; path=/
X-Transcend-Version: 1
Content-Length: 472
Connection: Keep-Alive
HTTP body length: (472)
< <?xml version="1.0" encoding="UTF-8"?>
< <auth id="main">
< <title>Default Customization</title>
< <message>Please enter your username and password.</message>
< <form method="post" action="webvpn.html">
< <input type="text" label="USERNAME:" name="username" value="" />
< <input type="password" label="PASSWORD:" name="password" value="" />
< <input type="submit" name="Login" value="Login" />
< <input type="reset" name="Clear" value="Clear" />
< </form>
< </auth>
Please enter your username and password.
PASSWORD:
POST https://myserver.com:8443/webvpn.html
> POST /webvpn.html HTTP/1.1
> Host: myserver.com:8443
> User-Agent: Open AnyConnect VPN Agent v8.02-1build1
> Cookie: webvpncontext=00000@SSLContext
> Accept: */*
> Accept-Encoding: identity
> X-Transcend-Version: 1
> X-Support-HTTP-Auth: true
> X-Pad: 0000000000000000000000000000000
> Content-Type: application/x-www-form-urlencoded
> Content-Length: 33
>
> username=XXXX&password=YYYY
Failed to read from SSL socket: Success.
Error fetching HTTPS response
Failed to obtain WebVPN cookie
What can I do to use openconnect to connect with my Cisco RV340?
Thanks for your help.