[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Problems with unified heimdal/samba domain
"James F. Hranicky" <jfh@cise.ufl.edu> writes:
>> Can you please try the patch above ?
>
> The patch above seems to stop the segfault, but it doesn't list all the
> princs. However, with the attached patch, it seems to do so. The patch
> includes a few initializations of hdb_entry structs, an addition of
> sambaSamAccount to the LDAP_firstkey() routine, and a check for a
> null pointer in krb5_realm_compare() . Do these additions seem reasonable?
>
[...]
> Only in heimdal-20041209.mod/lib/des: Makefile
> diff -cr heimdal-20041209/lib/hdb/hdb-ldap.c heimdal-20041209.mod/lib/hdb/hdb-ldap.c
> *** heimdal-20041209/lib/hdb/hdb-ldap.c Sat Dec 11 00:07:36 2004
> --- heimdal-20041209.mod/lib/hdb/hdb-ldap.c Sat Dec 11 16:09:31 2004
> *** heimdal-20041209/lib/hdb/hdb.c Sat Dec 11 00:07:36 2004
> --- heimdal-20041209.mod/lib/hdb/hdb.c Sat Dec 11 10:01:15 2004
So, I think its the libhdb backend that do the memset and not the caller,
does it still work for you if its done that way (ie only the samba change).
I've commited all other changes than the memset and the compare below
> diff -cr heimdal-20041209/lib/krb5/principal.c heimdal-20041209.mod/lib/krb5/principal.c
> *** heimdal-20041209/lib/krb5/principal.c Sat Dec 11 00:07:38 2004
> --- heimdal-20041209.mod/lib/krb5/principal.c Sat Dec 11 10:06:34 2004
> ***************
> *** 606,611 ****
> --- 606,612 ----
> krb5_const_principal princ1,
> krb5_const_principal princ2)
> {
> + if (!princ1 || !princ2) return 0;
> return strcmp(princ_realm(princ1), princ_realm(princ2)) == 0;
> }
>
When is this needed ? I think the caller is wrong if it passes a NULL
principal to this function, when does it happen ?
Love
PGP signature