Page 1 of 1

LDAP - Access to the user's address books

Posted: Fri Mar 16, 2007 1:16 pm
by MirkoMachine
Hi,

can you tell me the command, to search in a user's address book? or how to show all entries?

Greetings
Mirko

P.S. I'm using a test-installation of Scalix 11.0.2 under SuSE OSS 10.1

Posted: Fri Mar 16, 2007 5:15 pm
by KevinAnderson
"omsearch -s" will list all of the users in the system addressbook. I don't know how to list a user's personal addressbook at the command line.

You can access it using LDAP, if that'll help. You need an authenticated connection, and then look for o=MyContacts.

Kev.

Posted: Sat Mar 17, 2007 4:14 pm
by MirkoMachine
I used this command with Scalix 11.0 and it worked:

ldapsearch -h FQDN -p 389 -D cn="Lastname, GivenName", o=Scalix -w Password -x -b o=MyContacts

But it does't work anymore since I upgraded to 11.0.2:
ldap_bind: Naming violation (64)

seems to be an authentication problem... did anything change? Maybe -x isn't allowed anymore?

Greetings
Mirko

Posted: Sun Mar 18, 2007 5:47 pm
by MirkoMachine
Also, I was wondering what the rootdn is? is the rootpw the password i chose during install?

Posted: Mon Mar 19, 2007 12:15 pm
by KevinAnderson
If I use a similar line,

ldapsearch -D cn="Kevin Anderson" -w password -x -b o=MyContacts

I get results back as expected. I'm on 11.0.2.

Posted: Mon Mar 19, 2007 1:28 pm
by MirkoMachine
If I use
ldapsearch -D cn="GivenName Lastname" -w password -x -b o=MyContacts
I get
ldap_bind: Invalid credentials (49)

If I use
ldapsearch -D cn="Lastname, GivenName" -w password -x -b o=MyContacts
I still get
ldap_bind: Naming violation (64)

But it definetely worked before I upgraded...

Posted: Mon Mar 19, 2007 1:42 pm
by KevinAnderson
What does

ldapsearch -x

return? (Is it legit data or an error?)

Kev

Posted: Mon Mar 19, 2007 3:52 pm
by MirkoMachine
I get all scalix groups and users with details

Posted: Mon Mar 19, 2007 5:34 pm
by KevinAnderson
Ok, so that's all set up correctly. You're certain that the Username and password you're entering are correct?

Can you try it with another user, or yourself?

Kev.

Posted: Mon Mar 19, 2007 7:07 pm
by MirkoMachine
I just created a new User: GivenName Lastname. And I added one contact to his address book.

then, i ran ldapsearch -x and this is what I got (I deleted some irrelevant stuff):

# Lastname\2C GivenName, Scalix
dn: cn="Lastname, GivenName", o=Scalix
cn: Lastname, GivenName
l: xxx
st: xxx
c: xxx
objectClass: top
objectClass: person
objectClass: organizationalPerson
objectClass: mhsUser
objectClass: scalixPerson
surname: Lastname
postalCode: xxx
givenName: GivenName
mhsORAddresses: S=Lastname/G=GivenName/OU1=xxx/CN=Lastname, GivenName
omInternetAddr: "Lastname, GivenName" <gLastname@xxx>
mail: gLastname@xxx
rfc822Mailbox: gLastname@xxx
omAddress: GivenName Lastname /xxx/CN=Lastname, GivenName
omMailnode: xxx
omCn: Lastname, GivenName
omEmplOrg: xxx
omGlobalUniqueId: xxx
omLocalUniqueId: 673
omUlClass: Full


ldapsearch -D cn="Lastname, GivenName", o=Scalix -w password -x -b o=MyContacts
and
ldapsearch -D cn="Lastname, GivenName" -w password -x -b o=MyContacts
still give me:
ldap_bind: Naming violation (64)

Posted: Tue Mar 20, 2007 2:50 pm
by KevinAnderson
There's no comma between given and last names there right?

Kev.

Posted: Tue Mar 20, 2007 9:04 pm
by MirkoMachine
cn="Lastname, GivenName", o=Scalix

That's the Distinguished Name I got from ldapsearch -x

Posted: Wed Mar 21, 2007 7:28 am
by dannyt
Hi,

The problem may be the comma in CN, try quoting it like this: 'cn="last, first", o=scalix'

Regards,
Danny

Posted: Sat Mar 24, 2007 4:58 am
by MirkoMachine
Thanks dannyt, now it's working again.