diff options
author | wrtbuild <wrtbuild@localhost.(none)> | 2011-10-16 07:34:24 (GMT) |
---|---|---|
committer | wrtbuild <wrtbuild@localhost.(none)> | 2011-10-16 07:34:24 (GMT) |
commit | 64ca2d1ca4e6f9ae279fc17d84b2abd453140d28 (patch) | |
tree | 84a28cd644955e52bd6b91f2c474e9f338841119 /files/www/cgi-bin/splash_click | |
parent | 0850ac21d153d490ddc2b02f29b74b4b5ed88181 (diff) |
add makefile to generate images
Diffstat (limited to 'files/www/cgi-bin/splash_click')
-rwxr-xr-x | files/www/cgi-bin/splash_click | 38 |
1 files changed, 0 insertions, 38 deletions
diff --git a/files/www/cgi-bin/splash_click b/files/www/cgi-bin/splash_click deleted file mode 100755 index d08af6a..0000000 --- a/files/www/cgi-bin/splash_click +++ /dev/null @@ -1,38 +0,0 @@ -#!/bin/sh -echo -en "Status: 200 OK\r\n" -echo -en "Content-Type: text/html\r\n" -echo -en "\r\n" -TEST=`cat ` -TEST=`echo $TEST | sed 's/'target_url='/''/g'` -TEST=`/bin/urldecode "$TEST"` -TEST=`echo $TEST | sed 's/%2F/\//g'` -USER_MAC=`cat /proc/net/arp | grep $REMOTE_HOST | awk 'BEGIN { FS = " " } ; { print $4 }'` - -. $IPKG_INSTROOT/etc/functions.sh -ISSPLASHED=0 -config_load splash_users -is_mac() { - config_get mac "$1" mac - if [ "$mac" == "$USER_MAC" ]; then - ISSPLASHED=1 - fi -} -#check if user is alredy splashed -config_foreach is_mac user -sed 's/targeturl/'"$(echo $TEST| sed 's#/#\\/#g')"'/g' /www/iframe.html - -if [ $ISSPLASHED -eq 1 ]; then - exit -fi -#User is now free to go -iptables -t nat -I ffj_splash 1 -m --mac-source $USER_MAC -j ACCEPT - -uci -q add splash_users user -uci -q set splash_users.@user[-1].mac=$USER_MAC -uci -q set splash_users.@user[-1].time=`date +%s` - -exit 0 - - - - |