Skip to content
This repository has been archived by the owner on Oct 11, 2023. It is now read-only.

Why does protonvpn fail to connect? #81

Open
tochk4 opened this issue Jul 4, 2022 · 3 comments
Open

Why does protonvpn fail to connect? #81

tochk4 opened this issue Jul 4, 2022 · 3 comments

Comments

@tochk4
Copy link

tochk4 commented Jul 4, 2022

from protonvpn-cli.log the error seems to be dbus not being authorized to perform an operation

-------------------------------------------------

-----------	Initialized protonvpn-cli	-----------

-------------------------------------------------
2022-07-04 06:22:11,659 — cli.py — INFO — __init__:29 — Proton VPN CLI v3.12.0 (protonvpn-nm-lib v3.11.0; proton-client v0.7.1)
2022-07-04 06:22:11,660 — cli.py — INFO — __init__:64 — CLI command: Namespace(command='c', version=False, help=False, get_logs=False)
2022-07-04 06:22:11,661 — cli.py — INFO — connect:128 — Options: Namespace(servername=None, fastest=False, random=False, cc=None, sc=False, p2p=False, tor=False, protocol=None, help=False)
2022-07-04 06:22:15,586 — cli_dialog.py — INFO — start:59 — Selected country: "Netherlands"
2022-07-04 06:22:17,047 — cli_dialog.py — INFO — start:63 — Selected server: "NL-FREE#1"
2022-07-04 06:22:17,807 — cli_dialog.py — INFO — start:67 — Selected protocol: "udp"
2022-07-04 06:22:18,794 — cli_wrapper.py — ERROR — connect:379 — org.freedesktop.NetworkManager.PermissionDenied: Not authorized to perform this operation
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/protonvpn_cli/cli_wrapper.py", line 277, in connect
    self.protonvpn.setup_connection(
  File "/usr/lib/python3/dist-packages/protonvpn_nm_lib/api.py", line 158, in setup_connection
    self._env.connection_backend.setup(**data)
  File "/usr/lib/python3/dist-packages/protonvpn_nm_lib/core/connection_backend/nm_client/nm_client.py", line 81, in setup
    self._pre_setup_connection(kwargs.get("entry_ip"))
  File "/usr/lib/python3/dist-packages/protonvpn_nm_lib/core/connection_backend/nm_client/nm_client.py", line 233, in _pre_setup_connection
    ipv6_lp.manage(KillSwitchActionEnum.ENABLE)
  File "/usr/lib/python3/dist-packages/protonvpn_nm_lib/core/killswitch/ipv6_leak_protection.py", line 55, in manage
    self._ensure_connectivity_check_is_disabled()
  File "/usr/lib/python3/dist-packages/protonvpn_nm_lib/core/killswitch/ipv6_leak_protection.py", line 226, in _ensure_connectivity_check_is_disabled
    self.disable_connectivity_check(
  File "/usr/lib/python3/dist-packages/protonvpn_nm_lib/core/killswitch/ipv6_leak_protection.py", line 273, in disable_connectivity_check
    nm_methods.Set(
  File "/usr/lib/python3/dist-packages/dbus/proxies.py", line 72, in __call__
    return self._proxy_method(*args, **keywords)
  File "/usr/lib/python3/dist-packages/dbus/proxies.py", line 141, in __call__
    return self._connection.call_blocking(self._named_service,
  File "/usr/lib/python3/dist-packages/dbus/connection.py", line 652, in call_blocking
    reply_message = self.send_message_with_reply_and_block(
dbus.exceptions.DBusException: org.freedesktop.NetworkManager.PermissionDenied: Not authorized to perform this operation

the output when using protonvpn-cli

Setting up Proton VPN.

An unknown error has occured. Please ensure that you have internet connectivity.
If the issue persists, please contact support.

I am running Ubuntu 22 with xfce environment

@drewwells
Copy link

I've run down a bunch of rabbit holes and can not get past this either. A wireguard client would be much preferable to all the nuances of how networkmanager is handling these operations.

@flufficat
Copy link

Hi, to let you know this has been fixed at least on my machine in the protonvpn-nm-lib 3.16.0 release. Despite mentioning this issue they have solved in the release notes, proton haven't commented on this issue so I thought I would.

I had to rebuild protonvpn once I had checked that version 3.16.0 was installed. I simply uninstalled it and then reinstalled it:
Uninstalling protonvpn* and installing protonvpn

Then it will be using the new version of the library. I would like to know if this has also fixed this issue on your machine as it seems to have completely solved it on mine. Best wishes

@cilles
Copy link

cilles commented Sep 22, 2023

Recently downloaded on Linux mint, experiencing this error when attempting to connect via GUI.

             ...-:::::-...                  
          .-MMMMMMMMMMMMMMM-.              ------------- 
      .-MMMM`..-:::::::-..`MMMM-.          OS: Linux Mint 21.2 x86_64 
    .:MMMM.:MMMMMMMMMMMMMMM:.MMMM:.        Host: SER 
   -MMM-M---MMMMMMMMMMMMMMMMMMM.MMM-       Kernel: 5.15.0-82-generic 
 `:MMM:MM`  :MMMM:....::-...-MMMM:MMM:`    Uptime: 14 days, 15 hours, 57 mins 
 :MMM:MMM`  :MM:`  ``    ``  `:MMM:MMM:    Packages: 2361 (dpkg) 
.MMM.MMMM`  :MM.  -MM.  .MM-  `MMMM.MMM.   Shell: bash 5.1.16 
:MMM:MMMM`  :MM.  -MM-  .MM:  `MMMM-MMM:   Resolution: 2560x1440 
:MMM:MMMM`  :MM.  -MM-  .MM:  `MMMM:MMM:   DE: Cinnamon 5.8.4 
:MMM:MMMM`  :MM.  -MM-  .MM:  `MMMM-MMM:   WM: Mutter (Muffin) 
.MMM.MMMM`  :MM:--:MM:--:MM:  `MMMM.MMM.   WM Theme: Mint-Y-Dark (Mint-Y) 
 :MMM:MMM-  `-MMMMMMMMMMMM-`  -MMM-MMM:    Theme: Mint-Y-Dark [GTK2/3] 
  :MMM:MMM:`                `:MMM:MMM:     Icons: Mint-Y [GTK2/3] 
   .MMM.MMMM:--------------:MMMM.MMM.      Terminal: gnome-terminal 
     '-MMMM.-MMMMMMMMMMMMMMM-.MMMM-'       CPU: AMD Ryzen 5 5600H with Radeon Graphics (12) @ 3.300GHz 
       '.-MMMM``--:::::--``MMMM-.'         GPU: AMD ATI 04:00.0 Cezanne 
            '-MMMMMMMMMMMMM-'              Memory: 3917MiB / 28968MiB 
               ``-:::::-``

I have version 3.16.0-1 of python3-protonvpn-nm-lib, and I did try removing and reinstalling (sudo apt remove protonvpn; sudo apt install protonvpn) but still no luck.

$ sudo apt list | grep protonvpn

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

protonvpn-cli/unknown,now 3.13.0-1 all [installed]
protonvpn-gui/unknown,now 1.12.0-1 all [installed,automatic]
protonvpn-stable-release/unknown,now 1.0.3-2 all [installed]
protonvpn/unknown,now 1.0.0-3 all [installed]
python3-protonvpn-nm-lib/unknown,now 3.16.0-1 all [installed,automatic]
$ 

protonvpn-gui.log:

-------------------------------------------------

-----------	Initialized protonvpn	-----------

-------------------------------------------------
2023-09-22 03:08:50,549 — main.py — INFO —do_startup:87 — Proton VPN v1.12.0 (protonvpn-nm-lib v3.16.0; proton-client v0.7.1)
2023-09-22 03:08:50,565 — main.py — INFO —do_startup:109 — Startup successful
2023-09-22 03:08:50,779 — dashboard.py — INFO —setup_icons_images:385 — Setting up dashboard images and icons
2023-09-22 03:08:50,783 — dashboard.py — INFO —setup_css:424 — Setting up css
2023-09-22 03:08:50,785 — dashboard.py — INFO —setup_actions:454 — Setting up actions
2023-09-22 03:08:50,787 — main.py — INFO —do_activate:275 — Window to display <dashboard.DashboardView object at 0x7ff2303a79c0 (DashboardView at 0x560c448142c0)>
2023-09-22 03:09:06,293 — dashboard.py — INFO —on_click_quick_connect:244 — Clicked on quick connect.
2023-09-22 03:09:06,294 — dashboard.py — INFO —on_quick_connect:316 — Preparing to quick connect
2023-09-22 03:09:06,295 — dashboard.py — INFO —connect:386 — Setting up connection
2023-09-22 03:09:06,713 — dashboard.py — ERROR —connect:460 — org.freedesktop.NetworkManager.PermissionDenied: Not authorized to perform this operation
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/protonvpn_gui/view_model/dashboard.py", line 395, in connect
    server = protonvpn.setup_connection(
  File "/usr/lib/python3/dist-packages/protonvpn_nm_lib/api.py", line 158, in setup_connection
    self._env.connection_backend.setup(**data)
  File "/usr/lib/python3/dist-packages/protonvpn_nm_lib/core/connection_backend/nm_client/nm_client.py", line 81, in setup
    self._pre_setup_connection(kwargs.get("entry_ip"))
  File "/usr/lib/python3/dist-packages/protonvpn_nm_lib/core/connection_backend/nm_client/nm_client.py", line 233, in _pre_setup_connection
    ipv6_lp.manage(KillSwitchActionEnum.ENABLE)
  File "/usr/lib/python3/dist-packages/protonvpn_nm_lib/core/killswitch/ipv6_leak_protection.py", line 55, in manage
    self._ensure_connectivity_check_is_disabled()
  File "/usr/lib/python3/dist-packages/protonvpn_nm_lib/core/killswitch/ipv6_leak_protection.py", line 226, in _ensure_connectivity_check_is_disabled
    self.disable_connectivity_check(
  File "/usr/lib/python3/dist-packages/protonvpn_nm_lib/core/killswitch/ipv6_leak_protection.py", line 273, in disable_connectivity_check
    nm_methods.Set(
  File "/usr/lib/python3/dist-packages/dbus/proxies.py", line 72, in __call__
    return self._proxy_method(*args, **keywords)
  File "/usr/lib/python3/dist-packages/dbus/proxies.py", line 141, in __call__
    return self._connection.call_blocking(self._named_service,
  File "/usr/lib/python3/dist-packages/dbus/connection.py", line 652, in call_blocking
    reply_message = self.send_message_with_reply_and_block(
dbus.exceptions.DBusException: org.freedesktop.NetworkManager.PermissionDenied: Not authorized to perform this operation

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants