summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim McDonough <jmcd@samba.org>2003-08-27 20:22:12 +0000
committerJim McDonough <jmcd@samba.org>2003-08-27 20:22:12 +0000
commit270a59f7d33cf541a6db91797d5748ec9a17de3a (patch)
tree2553b0d60843a781f7e6c23ce70ad9dee83b5fb0
parentda0397bd2f1d4e299358a193a5223610571a9ae2 (diff)
downloadsamba-270a59f7d33cf541a6db91797d5748ec9a17de3a.tar.gz
samba-270a59f7d33cf541a6db91797d5748ec9a17de3a.tar.bz2
samba-270a59f7d33cf541a6db91797d5748ec9a17de3a.zip
Fix to properly set AP_OPTS_SUBKEY in heimdal. In MIT it is a #define, but
in heimdal it is an enum. Thanks to Guenther Deschner (gd@suse.de). With this join will work, but without a keytab, cifs connections will still fail with heimdal. Fix to come later. (This used to be commit d30bef4c37e8203c273eb3852215a89348bece7a)
-rw-r--r--source3/configure.in12
-rw-r--r--source3/include/ads.h2
2 files changed, 13 insertions, 1 deletions
diff --git a/source3/configure.in b/source3/configure.in
index 618171a4d3..1ac663436c 100644
--- a/source3/configure.in
+++ b/source3/configure.in
@@ -2545,6 +2545,18 @@ if test x"$with_ads_support" != x"no"; then
[Whether the ENCTYPE_ARCFOUR_HMAC_MD5 key type is available])
fi
+ AC_CACHE_CHECK([for AP_OPTS_USE_SUBKEY],
+ samba_cv_HAVE_AP_OPTS_USE_SUBKEY,[
+ AC_TRY_COMPILE([#include <krb5.h>],
+ [krb5_flags ap_options; ap_options = AP_OPTS_USE_SUBKEY;],
+ samba_cv_HAVE_AP_OPTS_USE_SUBKEY=yes,
+ samba_cv_HAVE_AP_OPTS_USE_SUBKEY=no)])
+
+ if test x"$samba_cv_HAVE_AP_OPTS_USE_SUBKEY" = x"yes"; then
+ AC_DEFINE(HAVE_AP_OPTS_USE_SUBKEY,1,
+ [Whether the AP_OPTS_USE_SUBKEY ap option is available])
+ fi
+
AC_CACHE_CHECK([for the krb5_princ_component macro],
samba_cv_HAVE_KRB5_PRINC_COMPONENT,[
AC_TRY_LINK([#include <krb5.h>],
diff --git a/source3/include/ads.h b/source3/include/ads.h
index 0961c9581c..b85ad21fba 100644
--- a/source3/include/ads.h
+++ b/source3/include/ads.h
@@ -218,6 +218,6 @@ typedef void **ADS_MODLIST;
/* The older versions of heimdal that don't have this
define don't seem to use it anyway. I'm told they
always use a subkey */
-#ifndef AP_OPTS_USE_SUBKEY
+#ifndef HAVE_AP_OPTS_USE_SUBKEY
#define AP_OPTS_USE_SUBKEY 0
#endif