OpenVPN / openvpn3-linux

OpenVPN 3 Linux client
GNU Affero General Public License v3.0
554 stars 148 forks source link

openvpn3-service-configmgr crashed with SIGABRT #17

Closed OriBenHur closed 4 years ago

OriBenHur commented 4 years ago

OS: ubuntu 20.04 This is what i see on journalctl

Aug 7 01:11:39 Oris-Laptop dbus-daemon[959]: [system] Activating service name='net.openvpn.v3.configuration' requested by ':1.1442' (uid=1000 pid=19388 comm="openvpn3 config-import --config /home/ori/Download" label="unconfined") (using servicehelper) Aug 7 01:11:39 Oris-Laptop net.openvpn.v3.configuration[19392]: OpenVPN 3/Linux v10_beta (openvpn3-service-configmgr) Aug 7 01:11:39 Oris-Laptop net.openvpn.v3.configuration[19392]: OpenVPN core 3.git:HEAD:bf9f309f linux x86_64 64-bit Aug 7 01:11:39 Oris-Laptop net.openvpn.v3.configuration[19392]: Copyright (C) 2012-2020 OpenVPN Inc. All rights reserved. Aug 7 01:11:39 Oris-Laptop net.openvpn.v3.log[6307]: Logger VERB2: Attached: {tag:8095744316103647505} [:1.1443/net.openvpn.v3.configuration] Aug 7 01:11:39 Oris-Laptop dbus-daemon[959]: [system] Successfully activated service 'net.openvpn.v3.configuration' Aug 7 01:11:39 Oris-Laptop net.openvpn.v3.configuration[19392]: terminate called after throwing an instance of 'openvpn::option_error' Aug 7 01:11:39 Oris-Laptop net.openvpn.v3.configuration[19392]: what(): option_error: option was not properly closed out

OriBenHur commented 4 years ago

removing the json file from /var/lib/openvpn3/configs fixed the issue

dsommers commented 4 years ago

Hey, thanks for this report. Could you please enlighten a bit more what was wrong in the configuration file?

I'm re-opening this ticket, because program termination due to an error in a saved configuration file is a real issue which should be fixed. But having more details on how you made it crash would be really good.

OriBenHur commented 4 years ago

i have no idea really, haven't using it for a while, the only new thing I've tried was switching to ovpn file for openvpn cloud. BTW after removing the file, no new file was created. if it's worth something I'm using zsh although i don't think it's related.

one last thing i don't know if it's related but I've also noticed that the shell auto compilation doesn't work but it might be because I'm using zsh.

dsommers commented 4 years ago

Configuration files in /var/lib/openvpn3/configs appears only when you use openvpn3 config-import --persistent. Otherwise configuration files are only temporarily stored in memory.

The completion scripts packaged targets bash, and is normally installed under /usr/share/bash-completion/completions/ (look for openvpn* files). These scripts should work with zsh as well, but I have no experience how to enable bash-completion support under zsh.

For the OpenVPN Cloud integration, I recommend you to install the python3-openvpn-connector-setup package and use the setup-token available in the OpenVPN Cloud admin interface. This ensures a proper configuration file to be downloaded and installed properly in a simple way. If you do not want this connection to start automatically, add the --no-systemd argument when running the openvpn-connector-setup utility.

schwabe commented 4 years ago

We have that as comment in that file :)

#         Also works with zsh after loading bascomphinit
#         (autoload -U +X bashcompinit && bashcompinit)

and iirc you need then do source thatfile

dsommers commented 4 years ago

This issue should be resolved with commit 67070ff056bc6003a3c16f97278456ff2f61775f. This will be part of the next release.

OriBenHur commented 4 years ago

Great thank you :)