garycnew
Senior Member
All:
As you know, I'm constantly trying to innovate and think outside of the box with solutions. I finally got around to implementing and documenting this project (http://vpnbook-passwd.com/). For those of you whom would prefer to automate the vpnbook.com openvpn client password update, I've registered vpnbook-passwd.com that provides read-only access to my /tmp/etc/openvpn/client1/auth file directly on my router. The process makes use of OCR software to automatically extract the vpnbook.com image password, update my router's openvpn client1/auth configuration, and then makes it available, in plain-text, via vpnbook-passwd.com. (A BIG Shout-out to @Martineau for recommending this process.)
Here is a Sample Robot Script that works specifically with ASUSWRT-Merlin (which can be adopted for other architectures):
I've had something similar to this successfully running for the past year and thought it was mature enough to let out into the wild.
It's always a mystery as to what type of responses I will receive when posting to the ASUSWRT-Merlin forums. Inevitably, someone will mention Security, Honeypots, etc. The fact is, if it's useful to you then have at it. If not, at least be constructive in your criticism. Thank You.
Respectfully,
Gary
As you know, I'm constantly trying to innovate and think outside of the box with solutions. I finally got around to implementing and documenting this project (http://vpnbook-passwd.com/). For those of you whom would prefer to automate the vpnbook.com openvpn client password update, I've registered vpnbook-passwd.com that provides read-only access to my /tmp/etc/openvpn/client1/auth file directly on my router. The process makes use of OCR software to automatically extract the vpnbook.com image password, update my router's openvpn client1/auth configuration, and then makes it available, in plain-text, via vpnbook-passwd.com. (A BIG Shout-out to @Martineau for recommending this process.)
Here is a Sample Robot Script that works specifically with ASUSWRT-Merlin (which can be adopted for other architectures):
Code:
#!/bin/sh
### Robot Installation ###
# mkdir -p /jffs/scripts/vpnbook-passwd.com
# cd /jffs/scripts/vpnbook-passwd.com/
# wget http://vpnbook-passwd.com/robot
# chmod 755 /jffs/scripts/vpnbook-passwd.com/robot
wget=$(/usr/sbin/wget --quiet -O - --no-check-certificate --save-cookies wget-cookies.txt --keep-session-cookies --load-cookies wget-cookies.txt -U "VPNBook-Passwd.com Robot/0.1" http://vpnbook-passwd.com/ | head -2 2>&1 | tee auth)
wget=$(sed -n '2p' auth)
#echo $wget
username=$(nvram get vpn_client1_username)
password=$(nvram get vpn_client1_password)
if [ "$wget" != "" ] && [ "$wget" != "$password" ]; then
password=$wget
#echo "#$username#"
#echo "#$password#"
nvram set vpn_client_password=$password
nvram set vpn_client1_password=$password
nvram commit
#service restart_vpnclient1
#service restart_webdav
echo $password | tee -a history
#echo -e "Password Changed\n$username\n$password\n" | /usr/sbin/sendmail -S"smtp.domain.com:25" -auusername -appassword -f"noreply@vpnbook-passwd.com" -t 5555555555@txt.att.net
logger "vpnbook-passwd.com $password"
fi
### ASUSWRT-Merlin service-event Config ###
# touch /jffs/scripts/service-event
# chmod 755 /jffs/scripts/service-event
# if ! grep "#!\/bin\/sh" /jffs/scripts/service-event; then echo "#!/bin/sh" >> /jffs/scripts/service-event; fi
# echo "if echo \"$1\" | grep -i \"start\" && [ \"$2\" = \"vpnclient1\" ]; then" >> /jffs/scripts/service-event
# echo " /bin/sh /jffs/scripts/vpnbook-passwd.com/robot >/dev/null 2>&1" >> /jffs/scripts/service-event
# echo "fi" >> /jffs/scripts/service-event
I've had something similar to this successfully running for the past year and thought it was mature enough to let out into the wild.
It's always a mystery as to what type of responses I will receive when posting to the ASUSWRT-Merlin forums. Inevitably, someone will mention Security, Honeypots, etc. The fact is, if it's useful to you then have at it. If not, at least be constructive in your criticism. Thank You.
Respectfully,
Gary
Last edited: