Changeset 199
- Timestamp:
- 08/10/07 17:37:55 (1 year ago)
- Files:
-
- fon/trunk/bin/thinclient (modified) (1 diff)
- fon/trunk/etc/banner (modified) (1 diff)
- fon/trunk/etc/fon_revision (modified) (1 diff)
- fon/trunk/etc/init.d/N50chillispot (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
fon/trunk/bin/thinclient
r84 r199 29 29 MODE=$1 30 30 31 [ `grep thinclient /etc/crontabs/root|wc -l` -eq 0 ] && { 32 FIRST=$((0x$(head -c2 /dev/urandom | hexdump | awk '$2 > 0 {print $2}') % 30)) 33 LAST=$( expr $FIRST + 30;) 34 echo "$FIRST,$LAST * * * * /bin/thinclient cron" >> /etc/crontabs/root 35 } 36 31 37 rm -f /tmp/.thinclient.sh 32 38 33 39 case "$1" in 34 40 cron) 35 sleep "$((0x$(head -c2 /dev/urandom | hexdump | awk '$2 > 0 {print $2}') % 3600))"41 sleep "$((0x$(head -c2 /dev/urandom | hexdump | awk '$2 > 0 {print $2}') % 60))" 36 42 echo "mode='$MODE' wlmac='$WLMAC' mac='$ETMAC' fonrev='$FONREV' firmware='$FIRMWARE' chillver='$CHILLVER' thclver='$THCLVER' device='$DEVICE'" | ssh -T ${PORT:+ -p $PORT}${KEY:+ -i $KEY} "${USER}@${SERVER}" > /tmp/.thinclient.sh 37 43 ;; fon/trunk/etc/banner
r84 r199 5 5 |___| 6 6 7 Fonera Firmware (Version 0.7.1 rev 3) -------------7 Fonera Firmware (Version 0.7.1 rev 5) ------------- 8 8 * 9 9 * Based on OpenWrt - http://openwrt.org fon/trunk/etc/fon_revision
r84 r199 1 3 1 5 fon/trunk/etc/init.d/N50chillispot
r77 r199 7 7 PID_LOOP_F=/var/run/chilli_loop.pid 8 8 LOG_LOOP_F=/var/log/chilli_loop.log 9 WANIP="$(ifconfig "$wan_ifname" | grep inet | awk -F'[: ]+' '{print $4}')"9 LANIP="$(ifconfig "$lan_ifname" | grep inet | awk -F'[: ]+' '{print $4}')" 10 10 MAC=$(ifconfig wifi0 | head -n1 | awk '{print $5}'|sed s/:/-/g) 11 11 MAC=${MAC:-fon} … … 94 94 ifconfig $wifi_ifname 0.0.0.0 # deconfigure the wifi interface 95 95 /usr/sbin/chilli \ 96 --dns1="$ WANIP" \97 --dns2="$ WANIP" \96 --dns1="$LANIP" \ 97 --dns2="$LANIP" \ 98 98 --radiusnasid="$MAC" \ 99 99 --dhcpif $wifi_ifname \ … … 114 114 ifconfig $wifi_ifname 0.0.0.0 # deconfigure the wifi interface 115 115 /usr/sbin/chilli \ 116 --dns1="$ WANIP" \117 --dns2="$ WANIP" \116 --dns1="$LANIP" \ 117 --dns2="$LANIP" \ 118 118 --radiusnasid="$MAC" \ 119 119 --dhcpif $wifi_ifname \
