File tree Expand file tree Collapse file tree 3 files changed +4
-32
lines changed
Expand file tree Collapse file tree 3 files changed +4
-32
lines changed Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ include $(TOPDIR)/rules.mk
33PKG_NAME: =luci-app-fleth
44LUCI_TITLE: =LuCI Support for Flet'h
55LUCI_DESCRIPTION: =luci-app-fleth is a helper that can configure IPv4 over IPv6 tunnel automatically in Japan.
6- PKG_VERSION: =0.9
6+ PKG_VERSION: =0.10
77PKG_RELEASE: =1
88
99LUCI_PKGARCH: =all
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -297,30 +297,9 @@ elif [ "$1" = "hook_none.js" ]; then
297297elif [ " $1 " = " restore_none.js" ]; then
298298 printf " 'use strict';'require network';return network.registerProtocol('none',{getI18n:function(){return _('Unmanaged');}});" > /www/luci-static/resources/protocol/none.js
299299elif [ " $h_IP6PREFIX_ENABLED " -eq 1 ] && [ " $1 " = " ip6prefix" ]; then
300- TRIES=0
301- MAX_TRIES=30
302- current_prefix=$( uci get network.${h_UPLINK_INTERFACE} .ip6prefix) > /dev/null
303- while [ $TRIES -lt $MAX_TRIES ]; do
304- ipv6_address=$( ifstatus ${h_UPLINK_INTERFACE} | grep ' "address"' | awk -F ' "' ' {print $4}' | grep -vE ' ^(fe80|fc00|fd00|fd50|::|::1|::ffff:0:0|::/96)' | head -n 1)
305- if [ -n " $ipv6_address " ]; then
306- pd_prefix=$( echo $ipv6_address | cut -d ' :' -f 1-4) ::/64
307- if [ " $pd_prefix " != " $current_prefix " ]; then
308- logger -t fleth " Got new PD with ${h_UPLINK_INTERFACE} =${pd_prefix} "
309- uci set network.${h_UPLINK_INTERFACE} .ip6prefix=${pd_prefix}
310- uci commit
311- if [ " $h_ENABLED " -eq 1 ] && [ " $ACTION " = " ifup" ]; then
312- sleep 10
313- /usr/sbin/fleth auto
314- fi
315- fi
316- break
317- fi
318- sleep 1
319- TRIES=$(( TRIES + 1 ))
320- done
321- if [ $TRIES -ge $MAX_TRIES ]; then
322- logger -t fleth " Failed to obtain a valid IPv6 address after $MAX_TRIES attempts."
323- fi
300+ uci set network.${h_UPLINK_INTERFACE} .extendprefix=1
301+ uci delete network.${h_UPLINK_INTERFACE} .ip6prefix
302+ uci commit network.${h_UPLINK_INTERFACE}
324303else
325304 echo " Flet'h by huggy"
326305 echo " Flet'h is a helper that can configure your IPv4 over IPv6 tunnel automatically."
You can’t perform that action at this time.
0 commit comments