summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorJeffrey Hutzelman <jhutz@cmu.edu>2016-04-05 18:28:53 -0400
committerRuss Allbery <eagle@eyrie.org>2016-04-26 20:51:03 -0700
commitdb19c1d8b1de7d26aac07c722373391cef2ed7f1 (patch)
tree9b60d22e9e068f1fe29bcf238c8ddd86bd4f2418 /tests
parent528bf1fd2051687583a0848cd650abf4055d5f11 (diff)
Skip anonymous tests if Kerberos is too old
Some older versions of Heimdal not only can't do PKINIT, but also crash when krb5_get_init_creds_password() is called with no password or prompter. Heimdal versions which avoid the crash have krb5_init_creds_set_password(), as do all versions of MIT Kerberos which support PKINIT. So, disable the anonymous tests if that function is not present. Note that there is a 4-month window in which the new function is present in Heimdal and the crash is still possible, but there were no releases during that time.
Diffstat (limited to 'tests')
-rw-r--r--tests/server/anonymous-t.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/server/anonymous-t.c b/tests/server/anonymous-t.c
index d70bb49..e118ddd 100644
--- a/tests/server/anonymous-t.c
+++ b/tests/server/anonymous-t.c
@@ -27,7 +27,7 @@
* Kerberos errors resort in an abort instead.
*/
#ifdef HAVE_KRB5
-# ifndef HAVE_KRB5_GET_INIT_CREDS_OPT_SET_ANONYMOUS
+# if !defined(HAVE_KRB5_GET_INIT_CREDS_OPT_SET_ANONYMOUS) || !defined(HAVE_KRB5_INIT_CREDS_SET_PASSWORD)
static char *
cache_init_anonymous(krb5_context ctx UNUSED, const char *principal UNUSED)