Koozali.org: home of the SME Server
Obsolete Releases => SME 7.x Contribs => Topic started by: dede77b on May 28, 2009, 03:50:21 PM
-
I'm looking for a solution to be informed via email everytime a vpn connection become active.
In sme7admin I can set a value for the Maximum number of vpn sessions, that means I can just receive an email when I have 2 vpn connection up at a time.
Have you any suggestion for this?
I'm using openvpn as a bridge.
Thanks
Fred
-
Hi
sme7admin won't alert you for OpenVPN connections, only the builtin PPTP.
If you want to have an email each time a client connects, it's quite easy. Create a custom-template for the config file /etc/openvpn/bridge/openvpn.conf and add a --client-connect directive which call a simple script, which will send the mail. man openvpn for more informations on this directive. You can even send who is connecting and from where using some environment variables. You can also do the same for --client-disconnect to have an email sent when clients disconnect.
Cheers, Daniel
-
Tnx for your suggestion. I will work on this and see what I can do.
Fred