kayrus / gof5

Open Source F5 BIG-IP VPN client for Linux, MacOS, FreeBSD and Windows
Apache License 2.0
140 stars 25 forks source link

pppd command-line options renamed #3

Closed leonbreedt closed 4 years ago

leonbreedt commented 4 years ago

I am not sure when this happened, but on my version of pppd (2.4.7), ipv6cp-accept-local and ipv6cp-accept-remote do not exist.

However, ipcp-accept-local and ipcp-accept-remote seem to work fine after patching pkg/client.go.

Not sure what the best resolution is, trying to parse output of pppd --version as a version seems hacky.

diff --git a/pkg/client.go b/pkg/client.go
index 269c21c..85e6435 100644
--- a/pkg/client.go
+++ b/pkg/client.go
@@ -241,8 +241,8 @@ func Connect(server, username, password string, closeSession bool) error {
                // VPN
                if favorite.Object.IPv6 {
                        config.PPPdArgs = append(config.PPPdArgs,
-                               "ipv6cp-accept-local",
-                               "ipv6cp-accept-remote",
+                               "ipcp-accept-local",
+                               "ipcp-accept-remote",
                                "+ipv6",
                        )
                } else {
kayrus commented 4 years ago

@leonbreedt I'm working on removing the pppd dependency.

kayrus commented 4 years ago

@leonbreedt you can try to test gof5 in Linux with the following config option:

hdlc: false
leonbreedt commented 4 years ago

@kayrus I tried latest master. Good news is that I could open a connection, but its still a bit flaky (paniced a few times), so I'm probably going to go back to a commit that still uses pppd, since I use this VPN for work :)

kayrus commented 4 years ago

@leonbreedt can you share the panic trace?

leonbreedt commented 4 years ago

@kayrus I think I was on a slightly old master, I can't reproduce it, and somehow, a commit which I had locally (with a different commit message to the one it has now) has vanished. Did you force push at some point? There was a commit 84376ad84df3fa56b06e303818cba3726ee54b4e, but now it's gone.

Also, a tonne of debug output along with the raw bytes dumped, whereas on refreshed master (@ 369fe4cf600e010c08acf0757810f056edd7cadb), I just see periodic ping/pong messages.

The crash was preceded by a message like 2020/05/07 20:01:29 Fatal write to tun: write tun: invalid argument.

I still see that message from time to time, but no crash now. If I see a crash again I'll open a new issue.

Thanks!

kayrus commented 4 years ago

@leonbreedt the work is still in progress and the project is far away to the first release. I completely refactored and amended the https://github.com/kayrus/gof5/commit/84376ad84df3fa56b06e303818cba3726ee54b4e because it was way too bad.

leonbreedt commented 4 years ago

@kayrus your work is much appreciated. using gof5 connecting to VPN is <5 seconds vs 30-60 seconds with the official F5 tools and the overcomplicated setup from corporate IT. it is already a big improvement to my life :beers:.

kayrus commented 4 years ago

Consider closed, when pppd is not used.