[Fedora-directory-commits] ldapserver config.h.in,1.25,1.26

Richard Allen Megginson rmeggins at fedoraproject.org
Wed Nov 12 17:42:39 UTC 2008

Author: rmeggins

Update of /cvs/dirsec/ldapserver
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv2757/ldapserver

Modified Files:
Log Message:
Resolves: bug 469261
Bug Description: Support server-to-server SASL - kerberos improvements
Reviewed by: ssorce (Thanks!)
Fix Description: I made several improvements to the kerberos code at
Simo's suggestion
First look for the principal in the ccache.  If not found, use the
username if it does not look like a DN.  If still not found, construct a
principal using the krb5_sname_to_principal() function to construct
"ldap/fqdn at REALM".
Next, see if the credentials for this principal are still valid.  In
order to grab the credentials from the ccache, I needed to construct the
server principal, which in this case is the TGS service principal (e.g.
krbtgt/REALM at REALM).  If the credentials are present and not expired,
then the code assumes they are ok and does not acquire new credentials.
If the credentials are expired or not found, the code will then use the
keytab to authenticate.
Based on more feedback from Simo, I made some additional changes:
* Go ahead and reacquire the creds if they have expired or will expire in 30 seconds - this is not configurable but could be made to be - 30 seconds should be long enough so that the credentials will not expire by the time they are actually used deep in the ldap/sasl/gssapi/krb code, and short enough so that this won't cause unnecessary credential churn
* Retry the bind in the case of Ticket expired.  There is no way that I can see to get the actual error code - fortunately the extended ldap error message has this information
Platforms tested: Fedora 8, Fedora 9
Flag Day: no
Doc impact: oh yes

Index: config.h.in
RCS file: /cvs/dirsec/ldapserver/config.h.in,v
retrieving revision 1.25
retrieving revision 1.26
diff -u -r1.25 -r1.26
--- config.h.in	29 Oct 2008 19:16:29 -0000	1.25
+++ config.h.in	12 Nov 2008 17:42:37 -0000	1.26
@@ -84,12 +84,24 @@
 /* Define to 1 if you have the `getpagesize' function. */
+/* define if you have HEIMDAL Kerberos */
+/* Define to 1 if you have the <heim_err.h> header file. */
 /* Define to 1 if you have the `inet_ntoa' function. */
 /* Define to 1 if you have the <inttypes.h> header file. */
+/* define if you have Kerberos V */
+#undef HAVE_KRB5
+/* Define to 1 if you have the `krb5_cc_new_unique' function. */
 /* Define to 1 if you have the `localtime_r' function. */

More information about the Fedora-directory-commits mailing list