1LDAP_RENAME(3)             Library Functions Manual             LDAP_RENAME(3)
2
3
4

NAME

6       ldap_rename, ldap_rename_s - Renames the specified entry.
7

LIBRARY

9       OpenLDAP LDAP (libldap, -lldap)
10

SYNOPSIS

12       #include <ldap.h>
13
14       int ldap_rename( ld, dn, newrdn, newparent, deleteoldrdn, sctrls[], cctrls[], msgidp );
15       LDAP *ld;
16       const char *dn, *newrdn, *newparent;
17       int deleteoldrdn;
18       LDAPControl *sctrls[], *cctrls[];
19       int *msgidp);
20
21       int ldap_rename_s( ld, dn, newrdn, newparent, deleteoldrdn, sctrls[], cctrls[] );
22       LDAP *ld;
23       const char *dn, *newrdn, *newparent;
24       int deleteoldrdn;
25       LDAPControl *sctrls[], *cctrls[];
26

DESCRIPTION

28       These  routines are used to perform a LDAP rename operation.  The func‐
29       tion changes the leaf component of an entry's  distinguished  name  and
30       optionally moves the entry to a new parent container. The ldap_rename_s
31       performs a rename operation synchronously.  The method takes dn,  which
32       points  to the distinguished name of the entry whose attribute is being
33       compared, newparent,the distinguished name of the entry's  new  parent.
34       If  this  parameter  is  NULL, only the RDN is changed.  The root DN is
35       specified by passing a zero length string, "".  deleteoldrdn  specifies
36       whether the old RDN should be retained or deleted.  Zero indicates that
37       the old RDN  should  be  retained.  If  you  choose  this  option,  the
38       attribute  will  contain  both  names  (the old and the new).  Non-zero
39       indicates that the old RDN should be deleted.  serverctrls points to an
40       array  of  LDAPControl  structures that list the client controls to use
41       with this extended operation. Use NULL to specify no  client  controls.
42       clientctrls  points to an array of LDAPControl structures that list the
43       client controls to use with the search.
44
45       ldap_rename works just like ldap_rename_s, but the operation  is  asyn‐
46       chronous.  It  returns  the message id of the request it initiated. The
47       result of this operation can be obtained by calling ldap_result(3).
48

ERRORS

50       ldap_rename() returns -1 in case of error initiating the  request,  and
51       will  set the ld_errno field in the ld parameter to indicate the error.
52       ldap_rename_s() returns the LDAP error code resulting from  the  rename
53       operation.
54

SEE ALSO

56       ldap(3), ldap_modify(3)
57

ACKNOWLEDGEMENTS

59       OpenLDAP  Software  is developed and maintained by The OpenLDAP Project
60       <http://www.openldap.org/>.  OpenLDAP Software is derived from  Univer‐
61       sity of Michigan LDAP 3.3 Release.
62
63
64
65OpenLDAP 2.4.44                   2016/02/05                    LDAP_RENAME(3)
Impressum