After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 271193 - Using Contacts to add to openldap DSA - Oddities
Using Contacts to add to openldap DSA - Oddities
Status: RESOLVED FIXED
Product: evolution
Classification: Applications
Component: Contacts
2.0.x (obsolete)
Other All
: Normal major
: ---
Assigned To: evolution-addressbook-maintainers
Evolution QA team
: 612888 (view as bug list)
Depends on: 273290
Blocks: 327508 327510
 
 
Reported: 2005-01-12 06:14 UTC by Craig White
Modified: 2013-09-10 14:04 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Adding support for givenName? (400 bytes, patch)
2010-03-14 19:24 UTC, Robert Markula
committed Details | Review

Description Craig White 2005-01-12 06:14:37 UTC
Description of Problem:
Actually - two problems

1. When you write the record - First Name (givenName) attribute isn't
written. Combination of First/Last is written to 'cn' and Last is written
to 'sn'

2. If access is controlled by ACL - New/Contact Editor is unconvinced it
can write to LDAP and field entry isn't possible unless you do all data
entry while set to 'Personal' and when finished - prior to save - change it
to the specific LDAP Directory and click "OK" Contact does get written.

Steps to reproduce the problem:
1. Client - Fedora Core - 3 / recently updated...
# rpm -qa|grep evolution
evolution-devel-2.0.2-3
evolution-2.0.2-3
evolution-data-server-1.0.3-2_1.rhfc3.at

2. Server - Openldap-2.2.19
3. openldap - slapd.conf (relevant parts anyway- ACL's)
# give read access to one's entry to himself only
access to dn.regex="^uid=([^,]+)ou=People,dc=azapple,dc=com$$"
        by self read
        by dn.exact="uid=Administrator,ou=People,dc=azapple,dc=com" write
        by * none

# allow one to create chidren of its own addressbook
access to dn.regex="^ou=addressbook,uid=([^,]+),ou=People,dc=azapple,dc=com$$"
        attrs=children,entry,inetOrgPerson,organizationalPerson,evolutionPerson
        by dn.exact,expand="uid=$1,ou=People,dc=azapple,dc=com" write
        by dn.exact="uid=Administrator,ou=People,dc=azapple,dc=com" write
        by * none

# allow one to create entries in its own addressbook
access to
dn.regex="[^,]+,ou=addressbook,uid=([^,]+),ou=People,dc=azapple,dc=com$$"
        attrs=children,entry,inetOrgPerson,organizationalPerson,evolutionPerson
        by dn.exact,expand="uid=$1,ou=People,dc=azapple,dc=com" write
        by dn.exact="uid=Administrator,ou=People,dc=azapple,dc=com" write
        by * none

4. Bind is permitted as user:
binddn 'uid=craig,ou=People,dc=azapple,dc=com'
searchbase 'ou=AddressBook,uid=craig,ou=People,dc=azapple,dc=com'

4. I have 'included' evolutionPerson.schema from Fedora Core-3 distribution
into openldap slapd.conf

Actual Results:
entry written by Evolution(contacts) using last second change from Personal
to 'LDAP AB' per above
# Craig White, AddressBook, craig, People, azapple, com
dn: cn=Craig White,ou=AddressBook,uid=craig,ou=People,dc=azapple,dc=com
cn: Craig White
sn: White
mail: work@email.com
mail: home@email.com
telephoneNumber: 111-111-1111
homePhone: 333-333-3333
mobile: 222-222-2222
facsimileTelephoneNumber: 444-444-4444
objectClass: top
objectClass: person
objectClass: organizationalPerson
objectClass: inetOrgPerson

Expected Results:
above +
givenName: Craig

How often does this happen? 
always

Additional Information:
If bind is rootbinddn - then new entry allows you to directly enter/edit
entries in LDAP without last-second sleight of hand change to LDAP
directory before save. Also, there is no way to 'edit' an existing entry -
deleting is not a problem but editing is not an option.

Craig
Comment 1 André Klapper 2006-01-09 01:46:19 UTC
retargetting bugs with severity=major from 2.3 to 2.5
Comment 2 James Andrewartha 2006-12-13 03:05:57 UTC
I think the givenName part could be solved by adding 

WRITE_ONLY_STRING_PROP (E_CONTACT_GIVEN_NAME, "givenName" ),

in the /* name fields */ section of evolution-data-server/addressbook/backends/ldap/e-book-backend-ldap.c

Also the dependancy (if still relevant) for part 2 should be changed to bug 261783, as bug 273290 was duped to it.
Comment 3 Robert Markula 2010-03-08 19:37:29 UTC
Unfortunately this bug (the givenname part) is still present in 2.28.

IMO this is a serious blocker when working with ldap address books, because you simply can't write to company wide address books without accidently deleting the given name of those addressbooks.
Comment 4 Matthew Barnes 2010-03-14 19:16:03 UTC
*** Bug 612888 has been marked as a duplicate of this bug. ***
Comment 5 Robert Markula 2010-03-14 19:24:03 UTC
Created attachment 156134 [details] [review]
Adding support for givenName?

Skimming quickly over the source code, would it suffice to add this line
of code to e-book-backend-ldap.c?
Comment 6 Robert Markula 2010-03-14 19:24:58 UTC
Btw, the bug is still present in latest trunk.
Comment 7 Matthew Barnes 2010-03-15 20:32:04 UTC
Patch looks reasonable to me.  Added it for 2.30.0.

http://git.gnome.org/browse/evolution-data-server/commit/?id=779a2361c85a92df5ae11f0fa120758e027738a9

I guess that leaves the ACL part, or is that fixed / no longer care?
Comment 8 Matthew Barnes 2010-03-15 20:35:11 UTC
Actually, since this is two bugs in one report and we haven't heard from the O.P. in five years, closing this as FIXED.  Craig can file a new bug for the ACL part if it's still an issue.
Comment 9 Craig White 2010-03-15 20:40:11 UTC
that would seem to be the prudent thing as I had long since forgotten that I even made the bug report.

If I get a chance, I will test against current version of Evolution and make a new bug report if needed. Thanks - Craig