Martineau
Part of the Furniture
Did you alter the script to hardcode the USERNAMEs to monitor as instructed in post #13Just a quick reply. I am not at home right now.
Yes, I have enabled the custom scripts in Merlin.
I will test the script when I get home. But I am still confused about what you mean.
Can you give me a example how to setup the cru command with the script.
I have created 2 test accounts in my VPN server now, "vpnuserA" and "vpnuserB"
How should I use one cru command to check both these accounts?
do you mean like
Code:/jffs/scripts/LimitOVPNSession.sh vpnuser1 enforce server /jffs/scripts/LimitOVPNSession.sh vpnuser2 enforce server
just repeat for all users but in one line?
i.e.
Is it Possible to limit OpenVPN connect time?
Hi, I am using 386.11 Merlin on RT-AC66U B1. I enable the VPN server1 on my router. Is it possible to limited the connection time for security reason? For example, It will force to disconnect the client after 5 mins no mater if it's still using or not. I only need to use my home ip in some...
www.snbforums.com
Issue the following command to see if you get the same response
Code:
grep -F '"$USERNAME" == "$LIMIT_USER"' /jffs/scripts/LimitOVPNSession.sh
if [ "$USERNAME" == "$LIMIT_USER" ];then
i.e. replace line:
Code:
if [ "$USERNAME" == "$LIMIT_USER" ];then
Code:
LIMIT_USER=$(echo "$LIMIT_USER" | tr ',' ' ') # Allow CSV list of users to check
if [ -n "$(echo "$LIMIT_USER" | grep -oE "$USERNAME\s")" ];then
then you have one
cron
job and you pass the list of USERNAMEs you want monitored.e.g.
Code:
cru a LimitOVPNSession "*/1 * * * * /jffs/scripts/LimitOVPNSession.sh 'vpnuserA,vpnuserB' enforce server"