Fix version used.

It seems like using an older version breaks things, as the server will
only return AUTH_FAILED.

Making a bigger channel so the tool does not block after the preflight
query.
This commit is contained in:
Patrick MARIE 2023-02-09 18:19:36 +01:00
parent 8f793ab586
commit 66f02634ab

View File

@ -75,13 +75,13 @@ func localServer(tokenChannel chan<- Token) {
func main() {
flag.Parse()
fmt.Println("Hello World!")
if checkOpenVPNFile() != nil {
return
}
tokenChannel := make(chan Token)
// Make a some big room for the channel.
tokenChannel := make(chan Token, 65535)
// Open a quick local httpd before redirecting user to go to saml auth page.
go localServer(tokenChannel)
@ -103,7 +103,7 @@ func main() {
"--config", ovpnFile,
"--auth-user-pass", tmpCredentialsFile,
"--script-security", "2", "--up-restart", "--up", "scripts/linux.sh", "--down", "scripts/linux.sh",
"--setenv", "IV_PLAT", "linux", "--setenv", "IV_GUI_VER", "AVPNC-2.14.14", "--push-peer-info", "--log", logFile,
"--setenv", "IV_PLAT", "linux", "--setenv", "IV_GUI_VER", "AVPNC-2.16.42", "--push-peer-info", "--log", logFile,
)
err = cmd.Run()