From 55085d799f50066c9adb5f72c78b48f7e05470b1 Mon Sep 17 00:00:00 2001 From: jow Date: Sun, 5 Sep 2010 21:58:52 +0000 Subject: [PATCH] [backfire] merge r22889, r22893 and r22897 git-svn-id: svn://svn.openwrt.org/openwrt/branches/backfire@22940 3c298f89-4303-0410-b956-a3cf2f4a3e73 --- package/6in4/Makefile | 2 +- package/6in4/files/6in4.hotplug | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/package/6in4/Makefile b/package/6in4/Makefile index c56b9c57c..b9fa220df 100644 --- a/package/6in4/Makefile +++ b/package/6in4/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=6in4 PKG_VERSION:=5 -PKG_RELEASE:=1 +PKG_RELEASE:=2 include $(INCLUDE_DIR)/package.mk diff --git a/package/6in4/files/6in4.hotplug b/package/6in4/files/6in4.hotplug index 96b046d14..534682e99 100644 --- a/package/6in4/files/6in4.hotplug +++ b/package/6in4/files/6in4.hotplug @@ -32,7 +32,9 @@ if [ "$ACTION" = ifup ]; then config_get password "$cfg" password [ -n "$tunnelid" ] && [ -n "$username" ] && [ -n "$password" ] && { - password="$(echo -n "$password" | md5sum)"; password="${password%% *}" + [ "${#password}" == 32 -a -z "${password//[a-f0-9]/}" ] || { + password="$(echo -n "$password" | md5sum)"; password="${password%% *}" + } uci_set_state network "$cfg" ipaddr "$wanip" ( wget -qO/dev/null "http://ipv4.tunnelbroker.net/ipv4_end.php?ipv4b=AUTO&user_id=$username&pass=$password&tunnel_id=$tunnelid" && ifup "$cfg" )&