+Wed Sep 11 17:01:06 1996 Barry Jaspan <bjaspan@mit.edu>
+
+ * make-host-keytab.pl.in: use kadmin instead of kadm5_keytab
+
Mon Aug 12 11:36:57 1996 Barry Jaspan <bjaspan@mit.edu>
* init_db: use kdb5_util instead of kdb5_create
$TCLUTIL = ($ENV{'TCLUTIL'} || "$TESTDIR/tcl/util.t");
# This'll be wrong sometimes
$RSH_CMD = ($ENV{'RSH_CMD'} || '/usr/ucb/rsh');
-$EDIT_KEYTAB = ($ENV{'EDIT_KEYTAB'} || "$top/keytab/kadm5_keytab.local");
+$KADMIN = ($ENV{'KADMIN'} || "$top/cli/kadmin.local");
if ($server) {
# XXX Using /usr/ucb/rsh for now.
else {
$redirect = "> /dev/null" if (! $verbose);
- $cmd = "$EDIT_KEYTAB -k $ktfile";
- $cmd .= " -q" if (! $verbose);
- $cmd .= " -a -c";
+ # We can ignore errors here, because the ktadd below will fail if
+ # this fails for any reason other than "principal exists"
for (@princs) {
- if (system "$cmd $_") {
- sleep(1);
- die "Error in system($cmd $_)\n";
- }
+ next if (/^kadmin/);
+ $cmd = "$KADMIN -q 'ank -randkey $_' $redirect 2>&1";
+ system($cmd);
+ }
+
+ $cmd = "$KADMIN -q 'ktadd -k $ktfile ";
+ $cmd .= " -q " if (! $verbose);
+ $cmd .= "@princs' $redirect";
+ if (system "$cmd") {
+ sleep(1);
+ die "Error in system($cmd)\n";
}
}
$TCLUTIL = ($ENV{'TCLUTIL'} || "$TESTDIR/tcl/util.t");
# This'll be wrong sometimes
$RSH_CMD = ($ENV{'RSH_CMD'} || '/usr/ucb/rsh');
-$EDIT_KEYTAB = ($ENV{'EDIT_KEYTAB'} || "$top/keytab/kadm5_keytab.local");
+$KADMIN = ($ENV{'KADMIN'} || "$top/cli/kadmin.local");
if ($server) {
# XXX Using /usr/ucb/rsh for now.
else {
$redirect = "> /dev/null" if (! $verbose);
- $cmd = "$EDIT_KEYTAB -k $ktfile";
- $cmd .= " -q" if (! $verbose);
- $cmd .= " -a -c";
+ # We can ignore errors here, because the ktadd below will fail if
+ # this fails for any reason other than "principal exists"
for (@princs) {
- if (system "$cmd $_") {
- sleep(1);
- die "Error in system($cmd $_)\n";
- }
+ next if (/^kadmin/);
+ $cmd = "$KADMIN -q 'ank -randkey $_' $redirect 2>&1";
+ system($cmd);
+ }
+
+ $cmd = "$KADMIN -q 'ktadd -k $ktfile ";
+ $cmd .= " -q " if (! $verbose);
+ $cmd .= "@princs' $redirect";
+ if (system "$cmd") {
+ sleep(1);
+ die "Error in system($cmd)\n";
}
}