VPN Look-Out Applet

UUID: vpnLookOut@claudiux
Last edited:
5 months ago 2024-07-06, 18:04
Last commit: [1d41b646] Add Catalan translations (#6189)

A Cinnamon applet that watches over the VPN link, displays its status, allows to connect at start-up to the last VPN used, allows to reconnect the VPN link if it incidentally drops, and can stop or restart VPN-related apps according to the state of the VPN.

README

Close

VPN Look-Out Applet

Important!

In order to be sure to download the latest version of VPN Lookout, use this link rather than the Download button at the top of this page.

Summary

This is a simple applet that I wrote because I often saw too late that my VPN (Virtual Private Network) was shut down.

This applet shows the state of the VPN (connected or disconnected) using colored icons. It can be used on horizontal or vertical panel.

But also, it can:

  • try to restart the VPN link when it shuts down incidentally,
  • close the VPN-related apps (like Transmission, qBittorrent, Deluge...) when your VPN shuts down, and restart them when your VPN link becomes active again,
  • quickly close a VPN-related app if it is started when the VPN is idle.

Status

Fully supported by Author, under continuing development and in continuous use on several machines, running with Linux Mint, Fedora or Archlinux.

Features

The VPN Look-Out Applet normally shows an icon that changes color depending on the state of the VPN connection :

  • Green: the VPN is connected.
  • Red: the VPN is disconnected.
  • Grey: waiting for VPN status (only when the applet starts, for a few seconds, or if it is misconfigured).

When hovering over or click on the icon, the status of the VPN is displayed with, between brackets, the name of the connection and the network interface used. By example:

VPN: Connected (Amsterdam / tun0)

The most important settings are accessible by the menu (by left or right click on applet icon) ; they are shown in bold in the list below. For all of them, see Settings in the Right Click Menu.

Settings :

  • VPN Network Interface (default: tun0).
  • VPN Name (name of the connection, automatically filled in, you can change for other existing connection name).
  • Try (or don't try) to connect to VPN when this applet starts.
  • Deactivate this applet at startup (only if the previous option is unchecked). This saves resources, but your connections and applications are no longer monitored. You can activate vpnLookOut from its menu, or using keyboard shortcut, or middle-clicking on its icon.
  • Try (or don't try) to reconnect to VPN when it shuts down incidentally.
  • Refresh Interval for Display (from 1 to 60 seconds).
  • Type of Display : Icon, with or without text 'VPN'.
  • Emit (or don't emit) a sound alert when VPN shuts down.
  • Emit (or don't emit) this sound alert when this Applet starts, if VPN is down.
  • Shut down (or not) properly Transmission as soon as VPN falls. (Cinnamon 2.8 to 3.6.)
  • Try (or don't try) to restart Transmission as soon as VPN restarts. (Cinnamon 2.8 to 3.6.)
  • Manage VPN-related Apps. (Cinnamon 3.8 and over.)
  • Log the status of the VPN link, and the status of the VPN-related Apps.

The left click menu also contains:

  • A button to connect to (or disconnect from) the last VPN used. This button appears only if the option "Try to reconnect to VPN when it shuts down incidentally" is unchecked.
  • A list of all VPN connections available. Click on one of them to change of VPN connection ; it disconnects from actual (if any) and connects to new.

A middle-click on the icon of this applet, or the keyboard shortcut v (which you can personalize), is a quick way to:

  • connect to the last VPN used if it is "off";
  • disconnect from the VPN if it is "on".

Translations

The vpnLookOut applet is designed to allow translations of messages (initially in English). A vpnLookOut.pot template file is available, you can use it with software such as poedit to translate these messages.

Languages already available: English, French, Spanish, Italian, Danish, Swedish.

The installation of the available languages is done automatically.

Translations are usually provided by people who are fluent in the language.

Any new translation will be welcome.

Users, please note that I will not be able to take responsibility for the accuracy of translations that I would not have done myself!

Contributions

While comments and suggestions are always welcome, any contributions considered should be discussed. Changes can have many unintended consequences and the integrity of the applet is paramount. Unsolicited pull requests will never be allowed with the exception of urgent and critical bug fixes from the Cinnamon team.

Requirements:

For full facilities including notifications and audible alerts the zenity, sox, libsox-fmt-mp3 and xdg-utils libraries must be installed. They can be installed wih the Synaptic Package Manager or using the following terminal command:

  • LinuxMint: apt update && apt install zenity sox libsox-fmt-mp3 xdg-utils
  • Fedora: sudo dnf update && sudo dnf install zenity sox xdg-utils
  • Archlinux: sudo pacman -Syu zenity sox xdg-utils

Note that this applet helps you to install these dependencies, if any.

Preconizations:

Transfere the /tmp directory into memory (Useless for Arch)

It is recommended to transfere the /tmp directory into memory, for two reasons:

  • Make applet execution faster.
  • Reduce hard disk wear (especially if it's a SSD).

To do this, add this line at the end of the file /etc/fstab; then, restart the computer: tmpfs /tmp tmpfs defaults,size=500M 0 0 (Beware to put the final character 's' at the 'defaults' word. In the size parameter, 'M' is for MB, 'G' is for GB; be careful, the memory allocated for /tmp is no longer available for the rest.)

Install at least Transmission

You can install (or re-install) Transmission (torrent client): apt install transmission transmission-gtk

Automatic Installation

Use the Applets menu in Cinnamon Settings, or Add Applets to Panel in the context menu (right-click) of your panel.

Manual Installation:

  • Install the additional programs required.
  • Download the VPN Look-Out Applet from the Spices Web Site.
  • Unzip and extract folder vpnLookOut@claudiux to ~/.local/share/cinnamon/applets/
  • Enable the applet in System Settings -> Applets.
  • You can also access the Settings Screen from System Settings -> Applets, or from the Applets Context menu.

CHANGELOG

Open

Log In To Comment!

66 Comments

claudiux
claudiux-1 year ago
Dear users of VPN LookOut, I wrote a new applet to manage many kinds of VPN : VPN-Sentinel https://cinnamon-spices.linuxmint.com/applets/view/368 VPN-Sentinel aims to replace this one. I have been using it for several months without problems. Thanks for trying it.
darkguset
darkguset-1 year ago
It used to work fine with NordVPN, but since some updates it is not showing the status anymore (Connected/Disconnected). Not interested in getting it working to control the VPN, just to show the status. I am on Linux Mint 21.1 Cinnamon.
thestevew
thestevew-2 years ago
Hi claudiux - just installed/tested VPN Lookout on Linux Mint 20.3. Works just as described - excellent documentation too! My only problem is that I'm almost totally colour blind so I can't see when the icon colour changes - tho the sound is good if it happens when I'm around. Could you add an option to either add a symbol, e.g. "!" or warning triangle, or use more distinct colours (like Wordle does). With somewhere around 10% of all men being red/green colour blind, lots of us have problems with stop/go good/bad yes/no indicators every day. So, if you could remove this one you would be doing something good for humanity :-\ ! Thanks for the applet.
claudiux
claudiux-2 years ago
Thank you for your complimentary comments. I am sensitive to your request, knowing the problems of color blind people. I take it into account for the new applet which will replace this one. Personal difficulties have prevented me from devoting time to its development, but it should be able to resume soon.
mikewesten
mikewesten-2 years ago
It works reasonably well with my OpenVPN UDP & TCP connections. However it seems unable to recognize PTPP connections, it fails to recognize them as being VPN connections at all.
leodawson
leodawson-2 years ago
How do I completely uninstall this? I cant find it in synaptic package manager or the linux mint software manager
claudiux
claudiux-2 years ago
Right-click on a panel, then choose Applets in the contextual menu. Select this applet in the list and click on the 'Uninstall' button.
cjnslm
cjnslm-3 years ago
Hi claudiux, I was wondering if it is possible to support several VPN connections in your applet. I use two or more simmultaneous vpn connections to diferent providers and the problem i'm having witgh nm applet is that i can't disconnect a specific vpn. It always disconnects the last one i connected to. I use tun0 through tun2 and by now i use terminal window only to manage these. Also can i add specific command line options to a connection in your applet? I know its a lot but i found that your applet is a lot more on the target for what i need professionaly. Thanks. Carlos
snakyjake1
snakyjake1-4 years ago
Use applet specific TMPFS file instead of System? Might it be a better idea to use a specific tmpfs for this applet, instead of the global/system temporary file? Why? Because I have very limited RAM. I prefer to have slowly changing data temporary stored to disk, while frequent changing data stored to RAM. Thanks. Applet version/Build date (to be found in "About.." or in "metadata.json") Version 3.5.1 (2020-08-10 14:00:43)
PLowran
PLowran-4 years ago
This Looks Awesome! I'm gonna install it when I get Home!!!
wyattb
wyattb-4 years ago
Works great on LM20. I am using NordVPN. Is there a way to see which country or city it's connecting to? Right now it shows VPN: Connected ( NordVPN/tun0)
claudiux
claudiux-4 years ago
Not yet; but soon. For now, you can also use the 'IP indicator' applet: https://cinnamon-spices.linuxmint.com/applets/view/300
casswarry0
casswarry0-4 years ago
First off I'd like to mention that I like the Applet and that I can confirm that it doesn't work with Wireguard. Because I really want to use it with Wireguard I will open an issue at Github with some of my findings why it doesn't work. Hopefully you can integrate the findings. Thank you for your effort.
Casey
Casey-4 years ago
As of Cinnamon 4.6 this applet is incompatible per lookingglass. (I'm betting there is a .json version line that needs adjusting.)
Paul
Paul-4 years ago
I have this on Linux Mint 19.3 So far everything appears to be working fine except the actual app kill switch! So, I added Brave Browser to the apps manager and told it to shut down if my vpn is off. When I test it by opening Brave then turning off my vpn connection, the applet does re-start my vpn, but doesn't close down Brave Browser. I have tried both setting it to shutdown when the VPN goes down and restart when it come back up again. I have also tried it just on the shutdown setting. Either way, the browser stays open. The Look Out logs show the VPN disconnect and restart, but nothing else. Any suggestions?
Bundy01
Bundy01-4 years ago
Bonsoir claudiux, cet applet est super mais ne gère que l'interface tun0. Mon vpn crée une interface du type 'nom_VPN-serveur' quand j'utilise un protocole autre que Open-VPN. J'ai remarqué quand supprimant manuellement l'interface tun0, ça marchait. Mais si je change de serveur et en voulant refaire la manipulation, l'applet fait planter X. La solution serrait peut-être de supprimer automatiquement l'interface au démarrage de l'applet et de pouvoir réactualiser avec le menu quand l'utilisateur change de serveur.
claudiux
claudiux-4 years ago
Bonsoir Bundy01, Je suis justement en train d'améliorer cette applet et d'y ajouter des fonctionnalités. Celle-ci est intéressante, mais comme personnellement je n'ai que des VPN qui utilisent l'interface tun0, j'aurai besoin d'un testeur. Voulez-vous bien ouvrir une "Issue", afin que nous puissions échanger plus confortablement, svp ? Merci à vous.
Bundy01
Bundy01-4 years ago
Ok, je fait ça :)
ah Jun
ah Jun-4 years ago
Hmm ... installed the dependencies, installed the applet. Gears are greyed out. Next is a warning triangle & ! saying: 'This applet contains function calls that could potentially cause Cinnamon to crash or freeze. If you are experiencing crashes or freezing, please try removing it.' Downloaded the version suggested by the link above, ... same grey gears & warning ... No crash or freeze at this point, but VPN Look-out does not work either, Cinnamon is 19.3 Tricia, Applet Version is 3.4.2 (2019-12-11 00:42:15) Any suggestion?
claudiux
claudiux-4 years ago
It looks like you only downloaded this applet. Please add it to a panel (from the Manage applets tab).
ah Jun
ah Jun-4 years ago
Spot on claudiux, thank you! Everything works fine now, great applet & help, very nice contribution, thank you!
dr-bludstul
dr-bludstul-4 years ago
Nice, I like it. Works fine.
Capitalmind
Capitalmind-5 years ago
Applet that should do everything I need however I am unable to activate it in the applet manager, the settings (gear) icon is greyed out. I use OpenVPN via the mint GUI for network settings in the tray and usually import .ovpn files to use. I thought this applet would help ensure I was always connected but I cannot seem to get it to work. I have the latest zenity sox libsox-fmt-mp3 xdg-utils installed?
claudiux
claudiux-5 years ago
Hi Capitalmind, Have you added this applet to a panel? What versions of vpnLookOut and Cinnamon are you using?
Capitalmind
Capitalmind-5 years ago
New to Applets, I seem to have not added it to the panel correctly and now it is showing. Using Mint 19.3 Cinnamon version 4.4.5
claudiux
claudiux-5 years ago
Glad that vpnLookOut is working properly. I hope you find this applet useful.
Andrew G.
Andrew G.-5 years ago
Hello, the applet mostly seems to be running smoothly but I cannot choose what apps are managed by the applet. There is no way to select them and when I enable "Manage VPN-related Apps" nothing happens. Under "Managed Apps" it is blank. I am on Mint 19.2 and Cinnamon 4.2.4, and have Transmission and Qbittorrent installed.
claudiux
claudiux-5 years ago
Hello Andrew, I know this problem. I am preparing the next version of this applet which will solve this issue and use symbolic icons. Regards.
claudiux
claudiux-5 years ago
Hello Andrew, The bug fix is ​​done. The best is to use Spices Update to make sure you download the latest version of vpnLookout.
claudiux
claudiux-5 years ago
Many thanks to Dragone2 for the new Italian translation!
leonzon
leonzon-5 years ago
is there any way to configure for a wireguard vpn? thanks
claudiux
claudiux-5 years ago
I'll test a wireguard vpn and I'll tell you how to do, if it's possible.
fstjohn
fstjohn-4 years ago
I'd like to see the applet working with Wireguard as well. I use NordVPN with their wireguard implementation, called NordLynx. I really like the applet and it works fine on Openvpn in my Mint Cinnamon 19.3. Any progress on this? Your reply to leonzon was 8 months ago.
claudiux
claudiux-5 years ago
Thanks to @muzena for his translation into Croatian!
claudiux
claudiux-6 years ago
Swedish and Turkish translations have been updated. Thanks to @eson57 and @kelebek333 !
claudiux
claudiux-6 years ago
The version 3.3.1 is now available. Now displaying keyboard and mouse shortcuts in the tooltip (hovering over the icon). "Switch to" (another VPN) events are now registered in the log file. The translations in French, Spanish and Italian, and the .pot file, are updated.
claudiux
claudiux-6 years ago
The version 3.3.0 is now available. When the option "Try to reconnect to VPN when it shuts down incidentally." was checked, the Disconnect button was hidden. As requested by Daniel Upshaw (@groovenectar), a new option "Do not try to reconnect automatically if the VPN has been disconnected by the user", complementary to the previous one, allows the user to voluntarily disconnect the VPN (the disconnect button is shown) and not to try to reconnect it afterwards. I also temporarily disabled the automatic installation of translations, which crashed Cinnamon during the installation of this applet.
Daniel Upshaw
Daniel Upshaw-6 years ago
Really cool! I've been using it for a little while now, but only just learned about the middle-click feature. Nice. I noticed that if I select "Try to reconnect the VPN when it shuts down incidentally," the connection toggle at the bottom disappears from the bottom. I would think that we might still want to start/stop it manually with the toggle. No real problem though, and at least I found out why the toggle disappeared.
claudiux
claudiux-6 years ago
Thank you for your support ! Select "Try to reconnect the VPN when it shuts down incidentally" is the same as selecting the autopilot: the manual command is disabled. I could leave the disconnect button visible, but then disconnecting would cause automatic re-connection to be aborted. Then, it may be necessary to notify the user that re-connection will no longer be automatic. I will think about a solution.
claudiux
claudiux-6 years ago
vpnLookOut@claudiux v3.2.0~20181111 is now available. It provides logging of VPN and VPN-related Apps activity. It has been successfully tested on Linux Mint 19, Fedora 27 and Antergos Linux (Arch Linux).
claudiux
claudiux-6 years ago
The Swedish translation has been updated. Thanks to @eson57 !
claudiux
claudiux-6 years ago
The Turkish translation is now available.
claudiux
claudiux-6 years ago
vpnLookOut@claudiux v3.1.0~20181107 is now available. It improves the VPN-related Apps Management and also the French, Spanish and Italian translations. A Turkish translation is coming soon. (Thanks to @kelebek333 !)
claudiux
claudiux-6 years ago
vpnLookOut@claudiux v3.0.1 compatible with Cinnamon 4.0 is now available.
binkyd
binkyd-6 years ago
Love this app!! However, I now use Cinnamon on Antergos Linux, which is Cinnamon 4.0 Can't wait, please catch up!
claudiux
claudiux-6 years ago
Hi @binkyd ! vpnLookOut@claudiux v3.0.1 compatible with Cinnamon 4.0 is coming ! I tested it on Antergos Linux. It works very well.
claudiux
claudiux-6 years ago
Version 3.0.0 is available. For Cinnamon 3.8 (Linux Mint 19): You can manage VPN-related apps, such as Torrent clients. For each of them, you can decide to stop it when the VPN link becomes inactive, and/or restart it when the VPN link becomes active again. There are some new messages to translate. Thank you for contributing to translate them into your language.
claudiux
claudiux-6 years ago
Version 2.5.2 is here. Some translation files have been updated.
claudiux
claudiux-6 years ago
Version 2.5.1 is here. It adds a keyboard shortcut option to activate / deactivate the last used VPN. The default is <Super>v.
claudiux
claudiux-6 years ago
Version 2.5.0 is here. vpnLookOut becomes multi version. For Cinnamon 3.8, the JavaScript code has been switched to Class Syntax and some bash scripts have been modified for more efficiency.
yochananmarqos
yochananmarqos-6 years ago
FYI: Arch uses a tmpfs /run directory, with /var/run and /var/lock simply existing as symlinks for compatibility. It is also used for /tmp by the default systemd setup and does not require an entry in fstab unless a specific configuration is needed.
claudiux
claudiux-6 years ago
Version 2.4.0 is here. New feature: Connect / Disconnect VPN with a single middle-click on the icon of this applet. Fixes a bug in Cinnamon 3.6: the correct script file permissions are set when starting this applet.
caseyjp11
caseyjp11-6 years ago
This applet fails under Archlinux (Cinnamon 3.8.2): vpnLookOut Applet message: Some packages needed!\nTo complete the installation, please enter and execute the command: \napt update && apt install zenity sox libsox-fmt-mp3 [casey@vipertpad ~]$ zenity and sox are already installed...."libsox-fmt-mp3" isn't found either in the main repositories OR the AUR.) fyi
claudiux
claudiux-6 years ago
Version 2.2.0 is now fully compatible with Archlinux, Fedora and LinuxMint/Ubuntu/Debian.
claudiux
claudiux-6 years ago
I'm working on that issue. Please try the last version 2.1.0. Next version will be compatible with Archlinux, too.
paint-rulz
paint-rulz-6 years ago
Hi, a big thank you for this. I'd worked out how to add vpn to startup (Mint 18.1) but didn't know how any dropout could be monitored ... your applet works perfectly! Great that it starts up the vpn (expressvpn), and ensures it's on 24.7. Much appreciate all your work on this applet. A+++++
claudiux
claudiux-6 years ago
Thank you so much! Glad that this applet meets your expectations.
sem5959
sem5959-6 years ago
Спасибо Вам за вашу работу - апплет протестировал на OpenVPN (Protonmail) на дистрибутиве Debian (Cinnamon) работает пока что корректно даже звук издаёт ! Рекомендую всем кто использует VPN, и не забывайте доустановить звуковые оповещения ( apt install zenity sox libsox-fmt-mp3 ) Респект - Thank you !!!
claudiux
claudiux-6 years ago
Спасибо за ваш комментарий, который побуждает меня продолжать разработку этого апплета! Thank you for your comment that encourages me to continue developing this applet!
claudiux
claudiux-6 years ago
vpnLookOut v2.0.1 is here.
GNU / Linux
GNU / Linux-6 years ago
Still I waited for v2.0.0 а 2.0.1 - Thank you !!!
claudiux
claudiux-6 years ago
vpnLookOut v2.0.0 is here !
GNU / Linux
GNU / Linux-6 years ago
Спасибо за ваш ответ. Ждём версию 2.0.0 .
claudiux
claudiux-6 years ago
Le nom de votre connexion comporte-t-il des espaces ? Si c'est la cas, la connexion/déconnexion n'est pas possible dans la version 1.0.0. J'ai corrigé ce bug dans la version 2.0.0 qui arrivera bientôt, accompagnée de nouvelles fonctionnalités. Does your connection name have spaces? If this is the case, connection / disconnection is not possible in version 1.0.0. I fixed this bug in version 2.0.0 which will be coming soon, with new features. У вашего имени соединения есть пробелы? Если это так, соединение / отключение невозможно в версии 1.0.0. Я исправил эту ошибку в версии 2.0.0, которая скоро появится, с новыми функциями.
GNU / Linux
GNU / Linux-7 years ago
Приходится апплет самому выключать и повторно подключаться.
GNU / Linux
GNU / Linux-7 years ago
Здравствуйте. Задумка Ваша с апплетом хорошая, но при разрыве OpenVPN не подключается.