1 .TH LDAP_ERROR 3 "23 July 2001" "OpenLDAP LDVERSION"
3 .\" Copyright 1998-2000 The OpenLDAP Foundation All Rights Reserved.
4 .\" Copying restrictions apply. See COPYRIGHT/LICENSE.
6 ldap_perror, ld_errno, ldap_result2error, ldap_errlist, ldap_err2string \- LDAP protocol error handling routines
13 char *ldap_err2string( int err );
16 void ldap_perror( LDAP *ld, const char *s )
19 int ldap_result2error( LDAP *ld, LDAPMessage *res, int freeit )
21 These routines provide interpretation of the various error codes
22 returned by the LDAP protocol and LDAP library routines or associated
23 with an LDAP session. The error code associated with an LDAP session
25 .BR ldap_get_option (3)
27 .BR ldap_set_option (3)
29 .B LDAP_OPT_ERROR_NUMBER
33 .B ldap_result2error()
34 routine takes \fIres\fP, a result as produced by
37 .BR ldap_search_s (3),
39 the corresponding error code. Possible error codes are listed
40 below. If the \fIfreeit\fP parameter is non zero it indicates that the
41 \fIres\fP parameter should be freed by a call to
43 after the error code has been extracted. The
45 field in \fIld\fP is set and returned.
47 The returned value can be passed to
49 to get a text description of the message. The string
52 is a pointer to a static area that
53 should not be modified.
57 routine can be called to print an indication of
58 the error on standard error, similar to the way
62 The possible values for an ldap error code are:
66 The request was successful.
68 .SM LDAP_OPERATIONS_ERROR
69 An operations error occurred.
71 .SM LDAP_PROTOCOL_ERROR
72 A protocol violation was detected.
74 .SM LDAP_TIMELIMIT_EXCEEDED
75 An LDAP time limit was exceeded.
77 .SM LDAP_SIZELIMIT_EXCEEDED
78 An LDAP size limit was exceeded.
80 .SM LDAP_COMPARE_FALSE
81 A compare operation returned false.
84 A compare operation returned true.
86 .SM LDAP_STRONG_AUTH_NOT_SUPPORTED
87 The LDAP server does not support strong authentication.
89 .SM LDAP_STRONG_AUTH_REQUIRED
90 Strong authentication is required for the operation.
92 .SM LDAP_PARTIAL_RESULTS
93 Partial results only returned.
95 .SM LDAP_NO_SUCH_ATTRIBUTE
96 The attribute type specified does not exist in the entry.
98 .SM LDAP_UNDEFINED_TYPE
99 The attribute type specified is invalid.
101 .SM LDAP_INAPPROPRIATE_MATCHING
102 Filter type not supported for the specified attribute.
104 .SM LDAP_CONSTRAINT_VIOLATION
105 An attribute value specified violates some constraint (e.g., a postalAddress
106 has too many lines, or a line that is too long).
108 .SM LDAP_TYPE_OR_VALUE_EXISTS
109 An attribute type or attribute value specified already exists in the entry.
111 .SM LDAP_INVALID_SYNTAX
112 An invalid attribute value was specified.
114 .SM LDAP_NO_SUCH_OBJECT
115 The specified object does not exist in The Directory.
117 .SM LDAP_ALIAS_PROBLEM
118 An alias in The Directory points to a nonexistent entry.
120 .SM LDAP_INVALID_DN_SYNTAX
121 A syntactically invalid DN was specified.
124 The object specified is a leaf.
126 .SM LDAP_ALIAS_DEREF_PROBLEM
127 A problem was encountered when dereferencing an alias.
129 .SM LDAP_INAPPROPRIATE_AUTH
130 Inappropriate authentication was specified (e.g., LDAP_AUTH_SIMPLE was
131 specified and the entry does not have a userPassword attribute).
133 .SM LDAP_INVALID_CREDENTIALS
134 Invalid credentials were presented (e.g., the wrong password).
136 .SM LDAP_INSUFFICIENT_ACCESS
137 The user has insufficient access to perform the operation.
143 The DSA is unavailable.
145 .SM LDAP_UNWILLING_TO_PERFORM
146 The DSA is unwilling to perform the operation.
151 .SM LDAP_NAMING_VIOLATION
152 A naming violation occurred.
154 .SM LDAP_OBJECT_CLASS_VIOLATION
155 An object class violation occurred (e.g., a "must" attribute was missing
158 .SM LDAP_NOT_ALLOWED_ON_NONLEAF
159 The operation is not allowed on a nonleaf object.
161 .SM LDAP_NOT_ALLOWED_ON_RDN
162 The operation is not allowed on an RDN.
164 .SM LDAP_ALREADY_EXISTS
165 The entry already exists.
167 .SM LDAP_NO_OBJECT_CLASS_MODS
168 Object class modifications are not allowed.
171 An unknown error occurred.
174 The LDAP library can't contact the LDAP server.
177 Some local error occurred. This is usually a failed dynamic memory allocation.
179 .SM LDAP_ENCODING_ERROR
180 An error was encountered encoding parameters to send to the LDAP server.
182 .SM LDAP_DECODING_ERROR
183 An error was encountered decoding a result from the LDAP server.
186 A timelimit was exceeded while waiting for a result.
188 .SM LDAP_AUTH_UNKNOWN
189 The authentication method specified to ldap_bind() is not known.
191 .SM LDAP_FILTER_ERROR
192 An invalid filter was supplied to ldap_search() (e.g., unbalanced
196 An ldap routine was called with a bad parameter (e.g., a NULL ld
200 An memory allocation (e.g., malloc(3) or other dynamic memory
201 allocator) call failed in an ldap
208 is developed and maintained by The OpenLDAP Project (http://www.openldap.org/).
210 is derived from University of Michigan LDAP 3.3 Release.