make use of new -config cmd-line parameter in reconfgureYACY.sh

to asure pwd encoding is compatible with DIGEST auth. in future.
pull/1/head
reger 11 years ago
parent d3a88eaecb
commit 2c8c51ce4b

@ -121,10 +121,7 @@ change_admin_password()
echo 'Entries did not match, please try again.'
change_admin_password
else
BASE64=`$JAVA -classpath lib/yacycore.jar net.yacy.cora.order.Base64Order -es "$USERNAME:$INPUT1"`
B64MD5=`$JAVA -classpath lib/yacycore.jar net.yacy.cora.order.Digest -strfhex "$BASE64"`
B64MD5=`echo $B64MD5 | sed "s/\(\S\) .*/\1/"`
replace_parameter 'adminAccountBase64MD5' "$B64MD5"
replace_parameter 'adminAccount' "$USERNAME:$INPUT1"
fi
STATUS='Admin password has been changed.'
@ -272,8 +269,7 @@ read_parameter()
# REPLACES THE VALUE OF A PARAMETER (FIRST ARGUMENT) WITH A NEW ONE (SECOND ARGUMENT)
replace_parameter()
{
sed "s/^\($1 *=\)\(.*\)/\1$2/" "$CONFIGFILE" >"$SETTINGSDIR/yacy.tmp"
mv "$SETTINGSDIR/yacy.tmp" "$CONFIGFILE"
$JAVA -classpath lib/yacycore.jar net.yacy.yacy -config "$1=$2" 2>/dev/null
}
#

Loading…
Cancel
Save