[28773] in CVS-changelog-for-Kerberos-V5
krb5 commit [krb5-1.11]: Add test for kinit -C WRONG_REALM response
daemon@ATHENA.MIT.EDU (Tom Yu)
Fri Feb 6 22:20:38 2015
Date: Fri, 6 Feb 2015 22:20:32 -0500
From: Tom Yu <tlyu@mit.edu>
Message-Id: <201502070320.t173KWsG016582@drugstore.mit.edu>
To: cvs-krb5@mit.edu
Reply-To: krbdev@mit.edu
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Errors-To: cvs-krb5-bounces@mit.edu
https://github.com/krb5/krb5/commit/ca8f09eec788d71a6c8f53786733fcf9c8bdb62a
commit ca8f09eec788d71a6c8f53786733fcf9c8bdb62a
Author: Tom Yu <tlyu@mit.edu>
Date: Fri Feb 6 22:17:30 2015 -0500
Add test for kinit -C WRONG_REALM response
(back ported from commit c0778ab2252ece4c3510788d9b72f7f5e3bb05dd)
ticket: 8122
version_fixed: 1.11.6
status: resolved
src/tests/t_general.py | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/src/tests/t_general.py b/src/tests/t_general.py
index 77246d5..178de37 100755
--- a/src/tests/t_general.py
+++ b/src/tests/t_general.py
@@ -49,6 +49,13 @@ if 'fred\n' not in output:
if 'barney\n' not in output:
fail('Policy not preserved across dump/load.')
+# Test that WRONG_REALM responses aren't treated as referrals unless
+# they contain a crealm field pointing to a different realm.
+# (Regression test for #8060.)
+out = realm.run_as_client([kinit, '-C', 'notfoundprinc'], expected_code=1)
+if 'not found in Kerberos database' not in out:
+ fail('Expected error message not seen in kinit -C output')
+
# Spot-check KRB5_TRACE output
tracefile = os.path.join(realm.testdir, 'trace')
realm.run_as_client(['env', 'KRB5_TRACE=' + tracefile, kinit,
_______________________________________________
cvs-krb5 mailing list
cvs-krb5@mit.edu
https://mailman.mit.edu/mailman/listinfo/cvs-krb5