#include <ldap_ssl.h>
int ldapssl_clientauth_init( char *certdbpath, void *certdbhandle,
int needkeydb, char *keydbpath, void *keydbhandle );
certdbpath | |
certdbhandle | Pass a NULL value for this. (This parameter is not used currently.) |
needkeydb | |
keydbpath | |
certdbhandle | Pass a NULL value for this. (This parameter is not used currently.) |
ldapssl_clientauth_init() function to initialize your client application for SSL and certificate-based client authentication.
If you need to specify the name and path of the security modules database or if you need to specify how the server's certificate will be verified, you should call the ldapssl_advclientauth_init() function instead of this function.
You must call this function before calling the ldapssl_init() function to connect to the server. For details, see Chapter 12, "Connecting Over SSL".
#include <ldap.h>
#include <ldap_ssl.h>
#include <stdio.h>
...
/* Initialize client, using mozilla's certificate database */
if ( ldapssl_clientauth_init( "/u/mozilla/.netscape/cert7.db", NULL, 1,
"/u/mozilla/.netscape/key3.db", NULL ) < 0 ) {perror( "ldap_clientauth_init" );
return( 1 );
}
}
...
ldap_init(), ldapssl_clientauth_init(), ldapssl_init(), ldapssl_install_routines().
Last Updated: 10/01/98 17:06:23