yuezk / GlobalProtect-openconnect

A GlobalProtect VPN client for Linux, written in Rust, based on OpenConnect and Tauri, supports SSO with MFA, Yubikey, and client certificate authentication, etc.
GNU General Public License v3.0
1.3k stars 150 forks source link

How to vpn-slice parameters in 2x? #308

Closed EmptyVisual closed 5 months ago

EmptyVisual commented 7 months ago

Previously on 1x I had modified the config /etc/gpservice/gp.conf with my script parameters. How do you do this in the 2.x version?

I'd like to know how to parse script parameters via the gpclient 2.x CLI

My config was like the below:

[vpn.company.com]
openconnect-args=--script "vpn-slice -K {subdomain1,subdomain2,subdomain3}.domain.com"
yuezk commented 7 months ago

You could try to put the script content in a separate script file, say, vpn-slice.sh, make it executable, and then you can set its absolute path to the VPNC script field.

image

I will support this case in the next release so you don't have to create a separate file.

EmptyVisual commented 7 months ago

You could try to put the script content in a separate script file, say, vpn-slice.sh, make it executable, and then you can set its absolute path to the VPNC script field.

image

I will support this case in the next release so you don't have to create a separate file.

Thank you. I’m running this on a headless server so I don’t have access to the UI. I have reverted to 1.x for now.

yuranos commented 7 months ago

I have a similar question. How do you pass --csd-wrapper now for example. Autoupdate to 2.X caused me a lot of stress today. I will probably also have to revert for now.

yuezk commented 7 months ago

Both vpnc-slice and csd-wrapper can be configured in settings, or passed via the cli parameter, see gpclient connect -h for details.

image