krb5 commit: Add test for empty K/M key data handling
Greg Hudson
ghudson at mit.edu
Fri Apr 22 15:00:38 EDT 2016
https://github.com/krb5/krb5/commit/f2286a6493c7aab267cf0d9cca680edaf2968707
commit f2286a6493c7aab267cf0d9cca680edaf2968707
Author: Matt Rogers <mrogers at redhat.com>
Date: Fri Apr 22 12:53:41 2016 -0400
Add test for empty K/M key data handling
ticket: 8395
src/tests/t_mkey.py | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/src/tests/t_mkey.py b/src/tests/t_mkey.py
index 572b2ad..c53b71b 100755
--- a/src/tests/t_mkey.py
+++ b/src/tests/t_mkey.py
@@ -328,4 +328,11 @@ check_mkvno(realm.user_princ, 1)
realm.run([kdb5_util, 'use_mkey', '2', 'now-1day'])
check_mkey_list((2, defetype, True, True), (1, des3, True, False))
+# Regression test for #8395. Purge the master key and verify that a
+# master key fetch does not segfault.
+realm.run([kadminl, 'purgekeys', '-all', 'K/M'])
+out = realm.run([kadminl, 'getprinc', realm.user_princ], expected_code=1)
+if 'Cannot find master key record in database' not in out:
+ fail('Unexpected output from failed master key fetch')
+
success('Master key rollover tests')
More information about the cvs-krb5
mailing list