summaryrefslogtreecommitdiff
path: root/src/util/sss_krb5.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/util/sss_krb5.c')
-rw-r--r--src/util/sss_krb5.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/util/sss_krb5.c b/src/util/sss_krb5.c
index 5f3177a9..a954d10a 100644
--- a/src/util/sss_krb5.c
+++ b/src/util/sss_krb5.c
@@ -811,15 +811,16 @@ cleanup:
#endif /* HAVE_KRB5_UNPARSE_NAME_FLAGS */
}
-void sss_krb5_get_init_creds_opt_set_canonicalize(krb5_get_init_creds_opt *opts,
+void sss_krb5_get_init_creds_opt_set_canonicalize(krb5_context ctx,
+ krb5_get_init_creds_opt *opts,
int canonicalize)
{
- /* FIXME: The extra check for HAVE_KRB5_TICKET_TIMES is a workaround due to Heimdal
- * defining krb5_get_init_creds_opt_set_canonicalize() with a different set of
- * arguments. We should use a better configure check in the future.
- */
-#if defined(HAVE_KRB5_GET_INIT_CREDS_OPT_SET_CANONICALIZE) && defined(HAVE_KRB5_TICKET_TIMES)
+#if defined(HAVE_KRB5_GET_INIT_CREDS_OPT_SET_CANONICALIZE) && \
+ KRB5_GET_INIT_CREDS_OPT_SET_CANONICALIZE_ARGS == 2
krb5_get_init_creds_opt_set_canonicalize(opts, canonicalize);
+#elif defined(HAVE_KRB5_GET_INIT_CREDS_OPT_SET_CANONICALIZE) && \
+ KRB5_GET_INIT_CREDS_OPT_SET_CANONICALIZE_ARGS == 3
+ (void) krb5_get_init_creds_opt_set_canonicalize(ctx, opts, canonicalize);
#else
DEBUG(SSSDBG_OP_FAILURE, ("Kerberos principal canonicalization is not available!\n"));
#endif