chiark / gitweb /
keys.new-recov, keys.reveal, keyfunc.sh.in: Don't put @bindir@ on the PATH.
authorMark Wooding <mdw@distorted.org.uk>
Sun, 25 Dec 2011 23:49:44 +0000 (23:49 +0000)
committerMark Wooding <mdw@distorted.org.uk>
Mon, 26 Dec 2011 00:08:44 +0000 (00:08 +0000)
Call `shamir' using an explicit pathname instead.

keyfunc.sh.in
keys.new-recov
keys.reveal

index bfcb26b..44117e9 100644 (file)
@@ -31,8 +31,6 @@ quis=${0##*/}
 PACKAGE="@PACKAGE@" VERSION="@VERSION@"
 bindir="@bindir@"
 
-case ":$PATH:" in *:"$bindir":*) ;; *) PATH=$bindir:$PATH ;; esac
-
 if [ -f $ETC/keys.conf ]; then . $ETC/keys.conf; fi
 
 case "${KEYS_DEBUG+t}" in t) set -x ;; esac
index c5d7fce..08c4ce3 100755 (executable)
@@ -102,7 +102,7 @@ done
 c_gensyskey $profile $rdir/new/store secret recov="$recov"
 while read keeper k; do
   read n hunoz <$KEYS/keeper/$keeper/meta
-  shamir issue $k/$n secret | {
+  $bindir/shamir issue $k/$n secret | {
     read param
     echo "$param" >$rdir/new/$keeper.param
     i=0
index a93ec90..a1c0242 100755 (executable)
@@ -133,7 +133,7 @@ if [ $n -lt $t ]; then
   echo >&2 "$quis: share $i revealed; $(( $t - $n )) more required"
 else
   cat $KEYS/recov/$recov/$keeper.param $keeper.*.share >$keeper.shares
-  shamir recover <$keeper.shares >nub.new
+  $bindir/shamir recover <$keeper.shares >nub.new
   c_sysprepare $KEYS/recov/$recov/store
   nubbin=$(nubid <nub.new)
   nubid=$(cat $KEYS/recov/$recov/store/nubid)