Using LDAP framework with SSL
Using LDAP framework with SSL
- Subject: Using LDAP framework with SSL
- From: Alexander Hartner <email@hidden>
- Date: Sat, 18 Mar 2006 00:03:53 +0000
I am trying to connect to my LDAP directory using SSL. Without SSL
the following lines work, but with SSL they fail.
ldap = ldap_init([hostname cString], [port intValue]);
ldap_perror(ldap, "LDAP INITIALISED");
const int version = 3;
int e = ldap_set_option(ldap, LDAP_OPT_PROTOCOL_VERSION, &version);
ldap_perror(ldap, "LDAP VERSION 3 SET");
e = ldap_simple_bind_s(ldap, [username cString], [password cString]);
char * errorMessage = ldap_err2string(e);
ldap_perror(ldap, "LDAP BOUND");
The error reported is :
LDAP BOUND: Can't contact LDAP server (-1)
At first I thought it was because I didn't have the OpenSSL libraries
included. After some searching on the web I found out that it is
recommended to use the Securities framework, which i already include.
Thanks
Alexander Hartner
email@hidden
Does a good farmer neglect a crop he has planted?
Does a good teacher overlook even the most humble student?
Does a good father allow a single child to starve?
Does a good programmer refuse to maintain his code?
- The Tao of Programming
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden