Print this page
3882 remove xmod & friends


 384  *      fprintf( stderr, "LDAP SDK level insufficient\n" );
 385  *
 386  */
 387 
 388 int
 389 LDAP_CALL
 390 ldap_version( LDAPVersion *ver )
 391 {
 392         if ( NULL != ver )
 393         {
 394                 memset( ver, 0, sizeof(*ver) );
 395                 ver->sdk_version = (int)(VI_PRODUCTVERSION * 100);
 396                 ver->protocol_version = LDAP_VERSION_MAX * 100;
 397                 ver->SSL_version = SSL_VERSION * 100;
 398                 /* 
 399                  * set security to none by default 
 400                  */
 401 
 402                 ver->security_level = LDAP_SECURITY_NONE;
 403 #if defined(LINK_SSL)
 404 #if defined(NS_DOMESTIC)
 405                 ver->security_level = 128;
 406 #elif defined(NSS_EXPORT)
 407                 ver->security_level = 40;
 408 #endif
 409 #endif
 410 
 411         }
 412         return (int)(VI_PRODUCTVERSION * 100);
 413 }
 414 
 415 /*
 416  * ldap_open - initialize and connect to an ldap server.  A magic cookie to
 417  * be used for future communication is returned on success, NULL on failure.
 418  * "host" may be a space-separated list of hosts or IP addresses
 419  *
 420  * Example:
 421  *      LDAP    *ld;
 422  *      ld = ldap_open( hostname, port );
 423  */
 424 
 425 LDAP *
 426 LDAP_CALL
 427 ldap_open( const char *host, int port )
 428 {
 429         LDAP    *ld;




 384  *      fprintf( stderr, "LDAP SDK level insufficient\n" );
 385  *
 386  */
 387 
 388 int
 389 LDAP_CALL
 390 ldap_version( LDAPVersion *ver )
 391 {
 392         if ( NULL != ver )
 393         {
 394                 memset( ver, 0, sizeof(*ver) );
 395                 ver->sdk_version = (int)(VI_PRODUCTVERSION * 100);
 396                 ver->protocol_version = LDAP_VERSION_MAX * 100;
 397                 ver->SSL_version = SSL_VERSION * 100;
 398                 /* 
 399                  * set security to none by default 
 400                  */
 401 
 402                 ver->security_level = LDAP_SECURITY_NONE;
 403 #if defined(LINK_SSL)

 404                 ver->security_level = 128;


 405 #endif

 406 
 407         }
 408         return (int)(VI_PRODUCTVERSION * 100);
 409 }
 410 
 411 /*
 412  * ldap_open - initialize and connect to an ldap server.  A magic cookie to
 413  * be used for future communication is returned on success, NULL on failure.
 414  * "host" may be a space-separated list of hosts or IP addresses
 415  *
 416  * Example:
 417  *      LDAP    *ld;
 418  *      ld = ldap_open( hostname, port );
 419  */
 420 
 421 LDAP *
 422 LDAP_CALL
 423 ldap_open( const char *host, int port )
 424 {
 425         LDAP    *ld;