aboutsummaryrefslogtreecommitdiffstats
path: root/package/6in4/files
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2010-09-04 16:09:49 +0000
committerJo-Philipp Wich <jow@openwrt.org>2010-09-04 16:09:49 +0000
commitc53f7423475b80da5e94d99af8f188e2ccb8caca (patch)
tree5dc3238ace5d3206432bbaac41fd17e55d643970 /package/6in4/files
parentc4b3034fab45aa23bebc26de7946fba860546f4a (diff)
downloadupstream-c53f7423475b80da5e94d99af8f188e2ccb8caca.tar.gz
upstream-c53f7423475b80da5e94d99af8f188e2ccb8caca.tar.bz2
upstream-c53f7423475b80da5e94d99af8f188e2ccb8caca.zip
[package] 6in4: replace sed match with variable substitution, change pattern from a-z to a-f (hex only)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22893 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/6in4/files')
-rw-r--r--package/6in4/files/6in4.hotplug2
1 files changed, 1 insertions, 1 deletions
diff --git a/package/6in4/files/6in4.hotplug b/package/6in4/files/6in4.hotplug
index b695b527ed..790edc0e15 100644
--- a/package/6in4/files/6in4.hotplug
+++ b/package/6in4/files/6in4.hotplug
@@ -32,7 +32,7 @@ if [ "$ACTION" = ifup ]; then
config_get password "$cfg" password
[ -n "$tunnelid" ] && [ -n "$username" ] && [ -n "$password" ] && {
- [ "${#password}" != 32 ] || [ -n "$(echo "$password" | sed 's/[a-z0-9]//g')" ] && {
+ [ "${#password}" == 32 -a -z "${password//[a-f0-9]/}" ] && {
password="$(echo -n "$password" | md5sum)"; password="${password%% *}"
}
uci_set_state network "$cfg" ipaddr "$wanip"