📄 ldap_error.3
字号:
.TH LDAP_ERROR 3 "RELEASEDATE" "OpenLDAP LDVERSION".\" $OpenLDAP: pkg/ldap/doc/man/man3/ldap_error.3,v 1.19.2.4 2007/01/02 21:43:44 kurt Exp $.\" Copyright 1998-2007 The OpenLDAP Foundation All Rights Reserved..\" Copying restrictions apply. See COPYRIGHT/LICENSE..SH NAMEldap_perror, ld_errno, ldap_result2error, ldap_errlist, ldap_err2string \- LDAP protocol error handling routines.SH LIBRARYOpenLDAP LDAP (libldap, -lldap).SH SYNOPSIS.nf.ft B#include <ldap.h>.LP.ft Bchar *ldap_err2string( int err );.LP.ft Bvoid ldap_perror( LDAP *ld, const char *s ).LP.ft Bint ldap_result2error( LDAP *ld, LDAPMessage *res, int freeit ).SH DESCRIPTIONThese routines provide interpretation of the various error codesreturned by the LDAP protocol and LDAP library routines or associatedwith an LDAP session. The error code associated with an LDAP sessionis accessible using.BR ldap_get_option (3)and.BR ldap_set_option (3)with the.B LDAP_OPT_RESULT_CODEoption (previously called.BR LDAP_OPT_ERROR_NUMBER )..LPThe.B ldap_result2error()routine takes \fIres\fP, a result as produced by.BR ldap_result (3)or.BR ldap_search_s (3),and returnsthe corresponding error code. Possible error codes are listedbelow. If the \fIfreeit\fP parameter is non zero it indicates that the\fIres\fP parameter should be freed by a call to.BR ldap_msgfree (3)after the error code has been extracted. The.B ld_errnofield in \fIld\fP is set and returned..LPThe returned value can be passed to.B ldap_err2string()to get a text description of the message. The stringreturned from.B ldap_err2string()is a pointer to a static area thatshould not be modified..LPThe.B ldap_perror()routine can be called to print an indication ofthe error on standard error, similar to the way.BR perror (3)works..SH ERRORSThe possible values for an ldap error code are:.LP.TP 20.SM LDAP_SUCCESSThe request was successful..TP.SM LDAP_OPERATIONS_ERRORAn operations error occurred..TP.SM LDAP_PROTOCOL_ERRORA protocol violation was detected..TP.SM LDAP_TIMELIMIT_EXCEEDEDAn LDAP time limit was exceeded..TP.SM LDAP_SIZELIMIT_EXCEEDEDAn LDAP size limit was exceeded..TP.SM LDAP_COMPARE_FALSEA compare operation returned false..TP.SM LDAP_COMPARE_TRUEA compare operation returned true..TP.SM LDAP_STRONG_AUTH_NOT_SUPPORTEDThe LDAP server does not support strong authentication..TP.SM LDAP_STRONG_AUTH_REQUIREDStrong authentication is required for the operation..TP.SM LDAP_PARTIAL_RESULTSPartial results only returned..TP.SM LDAP_NO_SUCH_ATTRIBUTEThe attribute type specified does not exist in the entry..TP.SM LDAP_UNDEFINED_TYPEThe attribute type specified is invalid..TP.SM LDAP_INAPPROPRIATE_MATCHINGFilter type not supported for the specified attribute..TP.SM LDAP_CONSTRAINT_VIOLATIONAn attribute value specified violates some constraint (e.g., a postalAddresshas too many lines, or a line that is too long)..TP.SM LDAP_TYPE_OR_VALUE_EXISTSAn attribute type or attribute value specified already exists in the entry..TP.SM LDAP_INVALID_SYNTAXAn invalid attribute value was specified..TP.SM LDAP_NO_SUCH_OBJECTThe specified object does not exist in The Directory..TP.SM LDAP_ALIAS_PROBLEMAn alias in The Directory points to a nonexistent entry..TP.SM LDAP_INVALID_DN_SYNTAXA syntactically invalid DN was specified..TP.SM LDAP_IS_LEAFThe object specified is a leaf..TP.SM LDAP_ALIAS_DEREF_PROBLEMA problem was encountered when dereferencing an alias..TP.SM LDAP_INAPPROPRIATE_AUTHInappropriate authentication was specified (e.g., LDAP_AUTH_SIMPLE wasspecified and the entry does not have a userPassword attribute)..TP.SM LDAP_INVALID_CREDENTIALSInvalid credentials were presented (e.g., the wrong password)..TP.SM LDAP_INSUFFICIENT_ACCESSThe user has insufficient access to perform the operation..TP.SM LDAP_BUSYThe DSA is busy..TP.SM LDAP_UNAVAILABLEThe DSA is unavailable..TP.SM LDAP_UNWILLING_TO_PERFORMThe DSA is unwilling to perform the operation..TP.SM LDAP_LOOP_DETECTA loop was detected..TP.SM LDAP_NAMING_VIOLATIONA naming violation occurred..TP.SM LDAP_OBJECT_CLASS_VIOLATIONAn object class violation occurred (e.g., a "must" attribute was missingfrom the entry)..TP.SM LDAP_NOT_ALLOWED_ON_NONLEAFThe operation is not allowed on a nonleaf object..TP.SM LDAP_NOT_ALLOWED_ON_RDNThe operation is not allowed on an RDN..TP.SM LDAP_ALREADY_EXISTSThe entry already exists..TP.SM LDAP_NO_OBJECT_CLASS_MODSObject class modifications are not allowed..TP.SM LDAP_OTHERAn unknown error occurred..TP.SM LDAP_SERVER_DOWNThe LDAP library can't contact the LDAP server..TP.SM LDAP_LOCAL_ERRORSome local error occurred. This is usually a failed dynamic memory allocation..TP.SM LDAP_ENCODING_ERRORAn error was encountered encoding parameters to send to the LDAP server..TP.SM LDAP_DECODING_ERRORAn error was encountered decoding a result from the LDAP server..TP.SM LDAP_TIMEOUTA timelimit was exceeded while waiting for a result..TP.SM LDAP_AUTH_UNKNOWNThe authentication method specified to ldap_bind() is not known..TP.SM LDAP_FILTER_ERRORAn invalid filter was supplied to ldap_search() (e.g., unbalancedparentheses)..TP.SM LDAP_PARAM_ERRORAn ldap routine was called with a bad parameter..TP.SM LDAP_NO_MEMORYAn memory allocation (e.g., malloc(3) or other dynamic memoryallocator) call failed in an ldaplibrary routine..SH SEE ALSO.BR ldap (3),.BR perror (3).SH ACKNOWLEDGEMENTS.B OpenLDAPis developed and maintained by The OpenLDAP Project (http://www.openldap.org/)..B OpenLDAPis derived from University of Michigan LDAP 3.3 Release.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -