#413 "Server is unwilling to perform" when running ldapmodify on nsds5ReplicaStripAttrs
Closed: Fixed None Opened 7 years ago by pviktori.

The server rejects modifications to nsds5ReplicaStripAttrs (a replica agreement attribute added in #321).

$ ldapmodify -x -h localhost -D "cn=Directory Manager" -w 12345678
dn: cn=meTovm-028.idm.lab.bos.redhat.com,cn=replica,cn=dc\3Didm\2Cdc\3Dlab\2Cdc\3Dbos\2Cdc\3Dredhat\2Cdc\3Dcom,cn=mapping tree,cn=config
changetype: modify
add: nsds5replicastripattrs
nsds5replicastripattrs: modifiersname modifytimestamp internalmodifiersname internalmodifytimestamp

modifying entry "cn=meTovm-028.idm.lab.bos.redhat.com,cn=replica,cn=dc\3Didm\2Cdc\3Dlab\2Cdc\3Dbos\2Cdc\3Dredhat\2Cdc\3Dcom,cn=mapping tree,cn=config"
ldap_modify: Server is unwilling to perform (53)

Sending out for review...

The function agmt_set_attrs_to_strip needs to
1) lock the ra
2) free the old value if there is a new value to set (just setting the old value to NULL will leak memory and there is no way to recover it if there is no new value or the new value is bogus)
3) notify the protocol that there is a change

e.g. see agmt_set_port_from_entry for an example of the checking and locking and notifying

Fix revised and patch attached...

git merge ticket413
Updating 3cf9a52..e860135
ldap/servers/plugins/replication/repl5.h | 1 +
ldap/servers/plugins/replication/repl5_agmt.c | 24 +++++++++++++++++++++
ldap/servers/plugins/replication/repl5_agmtlist.c | 9 +++++++
3 files changed, 34 insertions(+), 0 deletions(-)

[mareynol@localhost servers]$ git push origin master
Counting objects: 17, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (9/9), done.
Writing objects: 100% (9/9), 1.20 KiB, done.
Total 9 (delta 7), reused 0 (delta 0)
To ssh://git.fedorahosted.org/git/389/ds.git
3cf9a52..e860135 master -> master

Added initial screened field value.

Metadata Update from @mreynolds:
- Issue assigned to mreynolds
- Issue set to the milestone:

3 years ago

Login to comment on this ticket.