LinuxCommandLibrary

protonvpn

Connect to ProtonVPN servers

TLDR

Initialize ProtonVPN profile

$ protonvpn init
copy

Connect to ProtonVPN interactively
$ protonvpn [c|connect]
copy

Display connection status
$ protonvpn [s|status]
copy

Disconnect from ProtonVPN
$ protonvpn [d|disconnect]
copy

Reconnect or connect to the last server used
$ protonvpn [r|reconnect]
copy

Refresh OpenVPN configuration and server data
$ protonvpn refresh
copy

Display help for a subcommand
$ protonvpn [subcommand] --help
copy

SYNOPSIS

protonvpn [GLOBAL_OPTIONS] COMMAND [COMMAND_OPTIONS]

PARAMETERS

-h, --help
    Displays the help message for the protonvpn command or a specific subcommand.

--version
    Shows the installed version of the Proton VPN CLI client.

init
    Initializes the Proton VPN CLI client, guiding through the login and setup process.

connect [location|server_name|server_id]
    Connects to a Proton VPN server. Can connect to the fastest available, a specific location, or a specific server.

disconnect
    Disconnects from the currently active Proton VPN connection.

reconnect
    Reconnects to the last used Proton VPN server.

status
    Displays the current connection status, including server details, protocol, and duration.

refresh
    Refreshes the local server list cache, ensuring up-to-date server information.

configure
    Allows configuration of general client settings, such as default protocol or DNS management.

locations
    Lists all available Proton VPN server locations.

servers [location]
    Lists available servers within a specified location or all servers if no location is given.

server [server_id]
    Displays information about a specific server or connects to it.

schemes
    Lists available VPN protocols (e.g., OpenVPN UDP, OpenVPN TCP, WireGuard).

set <setting> <value>
    Sets a specific client configuration option, such as protocol, DNS, or kill switch status.

get <setting>
    Retrieves the current value of a specific client configuration option.

disable <feature>
    Disables a specific feature, such as the Kill Switch or Network Lock.

enable <feature>
    Enables a specific feature, such as the Kill Switch or Network Lock.

killswitch [status]
    Manages the Kill Switch feature, which blocks all network traffic if the VPN connection drops.

ns
    Manages the Network Lock (equivalent to Kill Switch for DNS and routing), preventing leaks.

dns
    Manages DNS resolution settings, allowing for custom DNS or Proton VPN's secure DNS.

logs
    Displays recent logs from the Proton VPN client for troubleshooting.

r
    Runs a speed test to Proton VPN servers to find the fastest connection.

upgrade
    Upgrades the Proton VPN CLI client to the latest available version.

DESCRIPTION

The protonvpn command is the official command-line interface (CLI) for Proton VPN on Linux systems. It provides a comprehensive set of tools to manage your VPN connection, configure settings, and interact with the Proton VPN service directly from the terminal. This client is ideal for users who prefer a minimalist interface, need to automate VPN connections via scripts, or manage their VPN on a headless server.

It supports various VPN protocols, including OpenVPN and WireGuard, and allows access to Proton VPN's extensive global server network, including specialized servers for Secure Core, P2P file sharing, and streaming. Key features configurable via the CLI include the Kill Switch (network lock), DNS management, and protocol selection. It's designed to offer a robust and secure VPN experience for advanced Linux users.

CAVEATS

Using the protonvpn CLI client typically requires root or sudo privileges for network configuration changes. A valid Proton VPN subscription is necessary to utilize the service. Ensure your system's network manager (e.g., NetworkManager or systemd-networkd) is compatible and properly configured, as the client interacts with it to manage network interfaces and routing tables. The client also manages DNS settings, which might override local configurations.

PROTOCOL SUPPORT

The protonvpn CLI client supports multiple VPN protocols, primarily OpenVPN (UDP and TCP) and WireGuard. Users can easily switch between these protocols using the set protocol command to optimize for speed or reliability depending on their network conditions.

SECURE CORE AND P2P SERVERS

The client allows direct connection to Proton VPN's specialized servers. Secure Core servers route traffic through multiple secure locations to mitigate advanced network attacks. P2P-optimized servers provide enhanced performance for peer-to-peer file sharing. These can be selected during the connection process or specified using location/server commands.

HISTORY

Proton VPN, founded by scientists who met at CERN, launched its VPN service following the success of ProtonMail, emphasizing privacy and security. The Linux CLI client was developed to cater to the significant portion of their user base on Linux systems, providing a native, robust, and scriptable alternative to GUI applications. Its development has focused on integrating deeply with Linux networking, supporting modern protocols, and offering advanced features like Kill Switch and Secure Core from the command line, reflecting a commitment to open-source and privacy-conscious users.

SEE ALSO

openvpn(8), wireguard(8), nmcli(1), ip(8), systemctl(1)

Copied to clipboard