Re: Special characters in distinguished name

2012-07-30 Thread Qiang Xu
On Sun, Jul 29, 2012 at 11:16 AM, wrote: > are special characters, especially German umlauts, acceptable in the > distinguished name? > I've accidentally discovered that CPAN's Net::LDAP::Entry module doesn't > support them (in the distinguished name). Other attributes are escaped > correctly. >

Re: What will happen if there are two user with same uid in OpenLDAP server

2012-07-30 Thread Qiang Xu
On Mon, Jul 30, 2012 at 11:24 AM, Guillaume Rousse wrote: > No specific syntax. Just get a specific user entry, and check its DN: > ldapsearch -x -b uid= > OK, I see. Just do a generic ldapsearch, right? Simple and effective. Thank you, Guillaume.

Re: What will happen if there are two user with same uid in OpenLDAP server

2012-07-30 Thread Qiang Xu
On Mon, Jul 30, 2012 at 10:55 AM, Guillaume Rousse wrote: > It lists the available classes and types (the known schemas), which > doesn't seems to be the issue here. If the question is 'how is my RDN > formed', just querying the directory with ldapsearch should be enough. > What is the specific l

Re: What will happen if there are two user with same uid in OpenLDAP server

2012-07-30 Thread Qiang Xu
On Sat, Jul 28, 2012 at 10:34 PM, Qian Zhang wrote: > [Qian] Sorry, I am new to LDAP, can you please let me know how to > figure out which way I am using for DN format? By some ldap commands? > > BTW, I installed and setup LDAP in a default way, so I guess the DN > format should be "uid=ghenry,ou

Re: LDAP_OPT_X_TLS_xxx option in SSL/TLS connection

2012-03-01 Thread Qiang Xu
2012/3/1 Michael Ströder > Could someone of the OpenLDAP core developers please confirm this? > Especially whether LDAP_OPT_X_TLS_NEWCTX is set to LDAP_OPT_OFF for > "clients"? > At least this is what is mentioned in the man page: http://linux.die.net/man/3/ldap_set_option *LDAP_OPT_X_TLS_NEWCT

Re: LDAP_OPT_X_TLS_xxx option in SSL/TLS connection

2012-02-29 Thread Qiang Xu
Guess what? Just picked up a pearl in the sea of internet: http://www.mailinglistarchive.com/postfix-us...@postfix.org/msg57688.html Basically, it seems to be a feature introduced since the beginning of openldap 2.4 version. We need to set LDAP_OPT_X_TLS_REQUIRE_CERT on an ldap handle (already ini

Re: LDAP_OPT_X_TLS_xxx option in SSL/TLS connection

2012-02-29 Thread Qiang Xu
On Tue, Feb 28, 2012 at 8:25 PM, Hallvard B Furuseth < h.b.furus...@usit.uio.no> wrote: > The essential parts here are creating the LDAP* with > ldap_initialize() or whatever, and ldap_start_tls_s(). > > Note that ldap_unbind() is misnamed, it should have been > called ldap_destroy(). It does sen

Re: LDAP_OPT_X_TLS_xxx option in SSL/TLS connection

2012-02-28 Thread Qiang Xu
Thanks for your reply, Hallvard. On Tue, Feb 28, 2012 at 6:23 PM, Hallvard B Furuseth < h.b.furus...@usit.uio.no> wrote: > Possibly the answer lies in the code you did not show: > Create an LDAP* (with which url/host?), connect, bind, unbind. The complete code is quite long. But the essential p

cert options in ssl/tls connections

2012-02-28 Thread Qiang Xu
Hello All, Today I came across a strange problem. I wrote a program to test ldap ssl/tls connection with OpenLDAP library. Something like the code snippet as follows: int ret = LDAP_OPT_SUCCESS; int cert_flag = LDAP_OPT_X_TLS_NEVER; ... ret = ldap_set_option(NULL, LDAP_OPT_X_TLS_REQUIRE_CERT, &c

LDAP_OPT_X_TLS_xxx option in SSL/TLS connection

2012-02-28 Thread Qiang Xu
Hello All, Today I came across a strange problem. I wrote a program to test ldap ssl/tls connection with OpenLDAP library. Something like the code snippet as follows: int ret = LDAP_OPT_SUCCESS; int cert_flag = LDAP_OPT_X_TLS_NEVER; ... ret = ldap_set_option(NULL, LDAP_OPT_X_TLS_REQUIRE_CERT, &c