diff options
author | Tom Yu <tlyu@mit.edu> | 1996-11-12 02:24:17 +0000 |
---|---|---|
committer | Tom Yu <tlyu@mit.edu> | 1996-11-12 02:24:17 +0000 |
commit | 8cf98fe5624ba448f1658ceeb288289446228fdb (patch) | |
tree | a58f8300eb4f044a7f6af6f4f6f0dcd21d67a916 /src | |
parent | 80cfef97cee7f9053f2e41e07fbdde998e38b497 (diff) | |
download | krb5-8cf98fe5624ba448f1658ceeb288289446228fdb.tar.gz krb5-8cf98fe5624ba448f1658ceeb288289446228fdb.tar.xz krb5-8cf98fe5624ba448f1658ceeb288289446228fdb.zip |
* init_db, save_files.sh, start_servers_local, stop_servers,
stop_servers_local: Use temp files rather than a here document to
provide input to eval'ed commands; Ultrix sh is broken wrt here
documents redirected to eval commands.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@9382 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src')
-rw-r--r-- | src/kadmin/testing/scripts/ChangeLog | 5 | ||||
-rw-r--r-- | src/kadmin/testing/scripts/init_db | 4 | ||||
-rw-r--r-- | src/kadmin/testing/scripts/save_files.sh | 4 | ||||
-rw-r--r-- | src/kadmin/testing/scripts/start_servers_local | 4 | ||||
-rw-r--r-- | src/kadmin/testing/scripts/stop_servers | 4 | ||||
-rw-r--r-- | src/kadmin/testing/scripts/stop_servers_local | 5 |
6 files changed, 18 insertions, 8 deletions
diff --git a/src/kadmin/testing/scripts/ChangeLog b/src/kadmin/testing/scripts/ChangeLog index 550a628ba4..87e77d8d92 100644 --- a/src/kadmin/testing/scripts/ChangeLog +++ b/src/kadmin/testing/scripts/ChangeLog @@ -1,5 +1,10 @@ Mon Nov 11 14:25:15 1996 Tom Yu <tlyu@mit.edu> + * init_db, save_files.sh, start_servers_local, stop_servers, + stop_servers_local: Use temp files rather than a here document to + provide input to eval'ed commands; Ultrix sh is broken wrt here + documents redirected to eval commands. + * start_servers, start_servers_local, init_db: Use ${FOO+bar} and ${FOO=baz} rather than ${FOO:+bar} and ${FOO:=baz} because of Ultrix /bin/sh lossage. diff --git a/src/kadmin/testing/scripts/init_db b/src/kadmin/testing/scripts/init_db index 2b218f0015..07d2921720 100644 --- a/src/kadmin/testing/scripts/init_db +++ b/src/kadmin/testing/scripts/init_db @@ -69,7 +69,7 @@ kdb5_util -r $REALM create -P mrroot -s $REDIRECT cp $STESTDIR/proto/ovsec_adm.dict $K5ROOT/ovsec_adm.dict -eval $SRVTCL <<'EOF' $REDIRECT +cat - > /tmp/init_db$$ <<\EOF source $env(TCLUTIL) set r $env(REALM) if {[info exists env(USER)]} { @@ -165,6 +165,8 @@ foreach cmd $cmds { } } EOF +eval "$SRVTCL < /tmp/init_db$$ $REDIRECT" +rm /tmp/init_db$$ if [ $? -ne 0 ]; then echo "Error in $SRVTCL!" 1>&2 diff --git a/src/kadmin/testing/scripts/save_files.sh b/src/kadmin/testing/scripts/save_files.sh index b9fc37319a..8d0a7c9b39 100644 --- a/src/kadmin/testing/scripts/save_files.sh +++ b/src/kadmin/testing/scripts/save_files.sh @@ -10,9 +10,9 @@ while [ $# -gt 0 ] ; do done # If it's set, set it to true -VERBOSE=${VERBOSE_TEST:+true} +VERBOSE=${VERBOSE_TEST+true} # Otherwise, set it to false -DUMMY=${VERBOSE:=false} +DUMMY=${VERBOSE=false} # files="/etc/inetd.conf /etc/syslog.conf /etc/krb.conf \ # /etc/krb.realms /etc/passwd /etc/services /etc/v5srvtab \ diff --git a/src/kadmin/testing/scripts/start_servers_local b/src/kadmin/testing/scripts/start_servers_local index 83913af0e7..e353659634 100644 --- a/src/kadmin/testing/scripts/start_servers_local +++ b/src/kadmin/testing/scripts/start_servers_local @@ -96,7 +96,7 @@ DUMMY=${REALM=SECURE-TEST.OV.COM}; export REALM hostname=`hostname` QUALNAME=`$TOP/testing/scripts/qualname.pl $hostname`; export QUALNAME -eval $SRVTCL <<'EOF' $REDIRECT +cat - > /tmp/start_servers_local$$ <<\EOF source $env(STOP)/testing/tcl/util.t set r $env(REALM) set q $env(QUALNAME) @@ -106,6 +106,8 @@ puts stdout [ovsec_kadm_create_principal $server_handle \ [simple_principal host/$q@$r] {OVSEC_KADM_PRINCIPAL} notathena] puts stdout [ovsec_kadm_destroy $server_handle] EOF +eval "$SRVTCL < /tmp/start_servers_local$$ $REDIRECT" +rm /tmp/start_servers_local$$ # rm -f /etc/v5srvtab # eval $LOCAL_MAKE_KEYTAB -princ host/xCANONHOSTx /etc/v5srvtab $REDIRECT diff --git a/src/kadmin/testing/scripts/stop_servers b/src/kadmin/testing/scripts/stop_servers index e8dcac8383..dc59d78bff 100644 --- a/src/kadmin/testing/scripts/stop_servers +++ b/src/kadmin/testing/scripts/stop_servers @@ -18,9 +18,9 @@ DUMMY=${RSH_CMD=rsh} DUMMY=${RESTORE_FILES=$TESTDIR/scripts/restore_files.sh} # If it's set, set it to true -VERBOSE=${VERBOSE_TEST:+true} +VERBOSE=${VERBOSE_TEST+true} # Otherwise, set it to false -DUMMY=${VERBOSE:=false} +DUMMY=${VERBOSE=false} local=1 diff --git a/src/kadmin/testing/scripts/stop_servers_local b/src/kadmin/testing/scripts/stop_servers_local index 5328e97a68..dcc52799ef 100644 --- a/src/kadmin/testing/scripts/stop_servers_local +++ b/src/kadmin/testing/scripts/stop_servers_local @@ -4,9 +4,9 @@ DUMMY=${TESTDIR=$TOP/testing} DUMMY=${RESTORE_FILES=$TESTDIR/scripts/restore_files.sh} # If it's set, set it to true -VERBOSE=${VERBOSE_TEST:+true} +VERBOSE=${VERBOSE_TEST+true} # Otherwise, set it to false -DUMMY=${VERBOSE:=false} +DUMMY=${VERBOSE=false} v4files=false while [ $# -gt 0 ] ; do @@ -51,3 +51,4 @@ rm -f /usr/tmp/krb5kdc_rcache if $v4files; then $RESTORE_FILES $start_servers fi +exit 0 |