Loading source3/configure.in +1 −0 Original line number Diff line number Diff line Loading @@ -2736,6 +2736,7 @@ if test x"$with_ads_support" != x"no"; then AC_CHECK_FUNC_EXT(krb5_free_ktypes, $KRB5_LIBS) AC_CHECK_FUNC_EXT(krb5_free_data_contents, $KRB5_LIBS) AC_CHECK_FUNC_EXT(krb5_principal_get_comp_string, $KRB5_LIBS) AC_CHECK_FUNC_EXT(krb5_free_unparsed_name, $KRB5_LIBS) LIBS="$LIBS $KRB5_LIBS" Loading source3/include/includes.h +4 −0 Original line number Diff line number Diff line Loading @@ -1294,6 +1294,10 @@ krb5_error_code krb5_set_default_tgs_ktypes(krb5_context ctx, const krb5_enctype krb5_error_code krb5_auth_con_setuseruserkey(krb5_context context, krb5_auth_context auth_context, krb5_keyblock *keyblock); #endif #ifndef (HAVE_KRB5_FREE_UNPARSED_NAME) void krb5_free_unparsed_name(krb5_context ctx, char *val) #endif /* Samba wrapper function for krb5 functionality. */ void setup_kaddr( krb5_address *pkaddr, struct sockaddr *paddr); int create_kerberos_key_from_string(krb5_context context, krb5_principal host_princ, krb5_data *password, krb5_keyblock *key, krb5_enctype enctype); Loading source3/libads/kerberos_keytab.c +4 −3 Original line number Diff line number Diff line Loading @@ -154,7 +154,8 @@ int ads_keytab_add_entry(const char *srvPrinc, ADS_STRUCT *ads) #else compare_ok = ((strcmp(ktprinc, princ_s) == 0) && (kt_entry.vno != kvno - 1)); #endif SAFE_FREE(ktprinc); krb5_free_unparsed_name(ktprinc); ktprinc = NULL; if (compare_ok) { DEBUG(3,("ads_keytab_add_entry: Found old entry for principal: %s (kvno %d) - trying to remove it.\n", Loading Loading @@ -479,7 +480,7 @@ int ads_keytab_create_default(ADS_STRUCT *ads) if (ret != KRB5_KT_END && ret != ENOENT ) { while ((ret = krb5_kt_next_entry(context, keytab, &kt_entry, &cursor)) == 0) { if (kt_entry.vno != kvno) { char *ktprinc; char *ktprinc = NULL; char *p; /* This returns a malloc'ed string in ktprinc. */ Loading Loading @@ -512,7 +513,7 @@ int ads_keytab_create_default(ADS_STRUCT *ads) } for (i = 0; oldEntries[i]; i++) { ret |= ads_keytab_add_entry(oldEntries[i], ads); SAFE_FREE(oldEntries[i]); krb5_free_unparsed_name(oldEntries[i]); } krb5_kt_end_seq_get(context, keytab, &cursor); } Loading Loading
source3/configure.in +1 −0 Original line number Diff line number Diff line Loading @@ -2736,6 +2736,7 @@ if test x"$with_ads_support" != x"no"; then AC_CHECK_FUNC_EXT(krb5_free_ktypes, $KRB5_LIBS) AC_CHECK_FUNC_EXT(krb5_free_data_contents, $KRB5_LIBS) AC_CHECK_FUNC_EXT(krb5_principal_get_comp_string, $KRB5_LIBS) AC_CHECK_FUNC_EXT(krb5_free_unparsed_name, $KRB5_LIBS) LIBS="$LIBS $KRB5_LIBS" Loading
source3/include/includes.h +4 −0 Original line number Diff line number Diff line Loading @@ -1294,6 +1294,10 @@ krb5_error_code krb5_set_default_tgs_ktypes(krb5_context ctx, const krb5_enctype krb5_error_code krb5_auth_con_setuseruserkey(krb5_context context, krb5_auth_context auth_context, krb5_keyblock *keyblock); #endif #ifndef (HAVE_KRB5_FREE_UNPARSED_NAME) void krb5_free_unparsed_name(krb5_context ctx, char *val) #endif /* Samba wrapper function for krb5 functionality. */ void setup_kaddr( krb5_address *pkaddr, struct sockaddr *paddr); int create_kerberos_key_from_string(krb5_context context, krb5_principal host_princ, krb5_data *password, krb5_keyblock *key, krb5_enctype enctype); Loading
source3/libads/kerberos_keytab.c +4 −3 Original line number Diff line number Diff line Loading @@ -154,7 +154,8 @@ int ads_keytab_add_entry(const char *srvPrinc, ADS_STRUCT *ads) #else compare_ok = ((strcmp(ktprinc, princ_s) == 0) && (kt_entry.vno != kvno - 1)); #endif SAFE_FREE(ktprinc); krb5_free_unparsed_name(ktprinc); ktprinc = NULL; if (compare_ok) { DEBUG(3,("ads_keytab_add_entry: Found old entry for principal: %s (kvno %d) - trying to remove it.\n", Loading Loading @@ -479,7 +480,7 @@ int ads_keytab_create_default(ADS_STRUCT *ads) if (ret != KRB5_KT_END && ret != ENOENT ) { while ((ret = krb5_kt_next_entry(context, keytab, &kt_entry, &cursor)) == 0) { if (kt_entry.vno != kvno) { char *ktprinc; char *ktprinc = NULL; char *p; /* This returns a malloc'ed string in ktprinc. */ Loading Loading @@ -512,7 +513,7 @@ int ads_keytab_create_default(ADS_STRUCT *ads) } for (i = 0; oldEntries[i]; i++) { ret |= ads_keytab_add_entry(oldEntries[i], ads); SAFE_FREE(oldEntries[i]); krb5_free_unparsed_name(oldEntries[i]); } krb5_kt_end_seq_get(context, keytab, &cursor); } Loading