[Date Prev][Date Next] [Chronological] [Thread] [Top]

Accessing LDAPResult::errorMessage

openldap guru's

Our LDAP infrastructure here in Motorola expires passwords after 90 days. After this point an authenticated Bind to a DN will fail with:

   Message: Id=3  Bind Result
       Message Length: 24
       Result Code: Invalid credentials (0x31)
       Matched DN: (null)
       Error Message: password expired!

I'd like to print to my users (and log) the "Error Message" string. The user can then go through the process of changing their password.

I've looked and all the ldap_*error* functions and they just use the requests "Result Code" to map to an error string via the ldap_errlist.

I realize the rfc's don't want developers relying on this field; but I'd like to just like to pass it onto the UI.

Did I miss how to access this? If I didn't why was access to this field left out of the API?


Rodd Zurcher
Sr. Staff Software Engineer
SPS/WSAS - 847.576.0666