diff options
author | Russ Allbery <rra@stanford.edu> | 2008-02-12 00:07:59 +0000 |
---|---|---|
committer | Russ Allbery <rra@stanford.edu> | 2008-02-12 00:07:59 +0000 |
commit | 247366355b63b3f6804d591dde9d5b48895a8fdf (patch) | |
tree | 5598f9b6c530ba048b361038cb786ca6ad25177f /perl/t/keytab.t | |
parent | ed075220bbd6515c713a5e53af00d6db66cd1c7c (diff) |
Move getcreds into the utility library as well.
Diffstat (limited to 'perl/t/keytab.t')
-rwxr-xr-x | perl/t/keytab.t | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/perl/t/keytab.t b/perl/t/keytab.t index 21a53c6..c1348d4 100755 --- a/perl/t/keytab.t +++ b/perl/t/keytab.t @@ -75,22 +75,6 @@ sub destroy { system_quiet ($Wallet::Config::KEYTAB_KADMIN, @args); } -# Given a keytab file, try authenticating with kinit. -sub getcreds { - my ($file, $principal) = @_; - my @commands = ( - "kinit -k -t $file $principal 2>&1 >/dev/null </dev/null", - "kinit -t $file $principal 2>&1 >/dev/null </dev/null", - "kinit -k -K $file $principal 2>&1 >/dev/null </dev/null", - ); - for my $command (@commands) { - if (system ($command) == 0) { - return 1; - } - } - return 0; -} - # Check whether a principal exists. sub created { my ($principal) = @_; |