MyWebUniversity.com Home Page
 



OpenSolaris man pages main menu


LDAP Library Functions                          ldaperror(3LDAP)



NAME
     ldaperror, ldaperr2string, ldapperror,  ldapresult2error
     - LDAP protocol error handling functions

SYNOPSIS
     cc[ flag... ] file... -lldap[ library... ]
     #include 
     #include 

     char *ldaperr2string(int err);


     void ldapperror(LDAP *ld, const char *s);


     int ldapresult2error(LDAP *ld, LDAPMessage *res, int freeit);


DESCRIPTION
     These functions interpret the error codes that are  returned
     by   the   LDAP   API   routines.   The   ldapperror()  and
     ldapresult2error() functions are  deprecated  for  all  new
     development. Use ldaperr2string() instead.


     You   can   also   use   ldapparsesaslbindresult(3LDAP),
     ldapparseextendedresult(3LDAP),                       and
     ldapparseresult(3LDAP)  to  provide  error  handling   and
     interpret error codes returned by LDAP API functions.


     The ldaperr2string() function takes  err,  a  numeric  LDAP
     error  code,  returned either by ldapparseresult(3LDAP) or
     another LDAP API call.  It  returns  an  informative,  null-
     terminated, character string that describes the error.


     The ldapresult2error() function takes res,  a  result  pro-
     duced by ldapresult(3LDAP) or other synchronous LDAP calls,
     and returns the corresponding  error  code.  If  the  freeit
     parameter  is  non-zero, it indicates that the res parameter
     should be freed by a call to  ldapresult(3LDAP)  after  the
     error code has been extracted.


     Similar to the way perror(3C) works, the ldapperror() func-
     tion  can  be  called to print an indication of the error to
     standard error.

ERORS
     The possible values for an LDAP error code are:




SunOS 5.11          Last change: 11 Nov 2008                    1






LDAP Library Functions                          ldaperror(3LDAP)



     LDAPSUCES

         The request was successful.


     LDAPOPERATIONSEROR

         An operations error occurred.


     LDAPROTOCOLEROR

         A protocol violation was detected.


     LDAPTIMELIMITEXCEDED

         An LDAP time limit was exceeded.


     LDAPSIZELIMITEXCEDED

         An LDAP size limit was exceeded.


     LDAPCOMPAREFALSE

         A compare operation returned false.


     LDAPCOMPARETRUE

         A compare operation returned true.


     LDAPSTRONGAUTHNOTSUPORTED

         The LDAP server does not support strong authentication.


     LDAPSTRONGAUTHREQUIRED

         Strong authentication is required for the operation.


     LDAPARTIALRESULTS

         Only partial results are returned.


     LDAPNOSUCHATRIBUTE




SunOS 5.11          Last change: 11 Nov 2008                    2






LDAP Library Functions                          ldaperror(3LDAP)



         The attribute type  specified  does  not  exist  in  the
         entry.


     LDAPUNDEFINEDTYPE

         The attribute type specified is invalid.


     LDAPINAPROPRIATEMATCHING

         The filter type  is  not  supported  for  the  specified
         attribute.


     LDAPCONSTRAINTVIOLATION

         An attribute value specified violates  some  constraint.
         For  example,  a  postalAddress has too many lines, or a
         line that is too long.


     LDAPTYPEORVALUEXISTS

         An attribute type or attribute value  specified  already
         exists in the entry.


     LDAPINVALIDSYNTAX

         An invalid attribute value was specified.


     LDAPNOSUCHOBJECT

         The specified object does not exist in the directory.


     LDAPALIASPROBLEM

         An alias in the directory points to a nonexistent entry.


     LDAPINVALIDNSYNTAX

         A syntactically invalid DN was specified.


     LDAPISLEAF

         The object specified is a leaf.




SunOS 5.11          Last change: 11 Nov 2008                    3






LDAP Library Functions                          ldaperror(3LDAP)



     LDAPALIASDEREFPROBLEM

         A problem was encountered when dereferencing an alias.


     LDAPINAPROPRIATEAUTH

         Inappropriate authentication was specified. For example,
         LDAPAUTHSIMPLE  was  specified  and the entry does not
         have a userPassword attribute.


     LDAPINVALIDCREDENTIALS

         Invalid credentials were  presented,  for  example,  the
         wrong password.


     LDAPINSUFICIENTACES

         The user has insufficient access to perform  the  opera-
         tion.


     LDAPBUSY

         The DSA is busy.


     LDAPUNAVAILABLE

         The DSA is unavailable.


     LDAPUNWILINGTOPERFORM

         The DSA is unwilling to perform the operation.


     LDAPLOPDETECT

         A loop was detected.


     LDAPNAMINGVIOLATION

         A naming violation occurred.


     LDAPOBJECTCLASVIOLATION

         An object class violation occurred. For example, a  must



SunOS 5.11          Last change: 11 Nov 2008                    4






LDAP Library Functions                          ldaperror(3LDAP)



         attribute was missing from the entry.


     LDAPNOTALOWEDONONLEAF

         The operation is not allowed on a nonleaf object.


     LDAPNOTALOWEDONRDN

         The operation is not allowed on an RDN.


     LDAPALREADYEXISTS

         The entry already exists.


     LDAPNOBJECTCLASMODS

         Object class modifications are not allowed.


     LDAPOTHER

         An unknown error occurred.


     LDAPSERVERDOWN

         The LDAP library cannot contact the LDAP server.


     LDAPLOCALEROR

         Some local error occurred. This is usually the result of
         a  failed malloc(3C) call or a failure to fflush(3C) the
         stdio stream to files, even when the LDAP requests  were
         processed successfully by the remote server.


     LDAPENCODINGEROR

         An error was encountered encoding parameters to send  to
         the LDAP server.


     LDAPDECODINGEROR

         An error was encountered decoding a result from the LDAP
         server.




SunOS 5.11          Last change: 11 Nov 2008                    5






LDAP Library Functions                          ldaperror(3LDAP)



     LDAPTIMEOUT

         A time limit was exceeded while waiting for a result.


     LDAPAUTHUNKNOWN

         The authentication method specified to  ldapbind(3LDAP)
         is not known.


     LDAPFILTEREROR

         An invalid filter was  supplied  to  ldapsearch(3LDAP),
         for example, unbalanced parentheses.


     LDAPARAMEROR

         An LDAP function was called with a  bad  parameter,  for
         example, a NUL ld pointer, and the like.


     LDAPNOMEMORY

         A memory allocation call failed in an LDAP library func-
         tion, for example, malloc(3C).


     LDAPCONECTEROR

         The LDAP client has either lost its connetion to an LDAP
         server or it cannot establish a connection.


     LDAPNOTSUPORTED

         The requested functionality is not supported., for exam-
         ple,  when  an  LDAPv2 client requests some LDAPv3 func-
         tionality.


     LDAPCONTROLNOTFOUND

         An LDAP client requested a control not found in the list
         of supported controls sent by the server.


     LDAPNORESULTSRETURNED

         The LDAP server sent no results.




SunOS 5.11          Last change: 11 Nov 2008                    6






LDAP Library Functions                          ldaperror(3LDAP)



     LDAPMORERESULTSTORETURN

         More results are chained in the message chain.


     LDAPCLIENTLOP

         A loop has been detected, for  example,  when  following
         referrals.


     LDAPREFERALIMITEXCEDED

         The referral exceeds the hop limit. The hop limit deter-
         mines  the  number  of  servers  that the client can hop
         through to retrieve data.


ATRIBUTES
     See attributes(5) for a description of the following  attri-
     butes:



     
           ATRIBUTE TYPE               ATRIBUTE VALUE       
    
     Availability                 SUNWcsl (32-bit)            
                                  SUNWcslx (64-bit)           
    
     Interface Stability          Committed                   
    


SEE ALSO
     fflush(3C),          ldap(3LDAP),          ldapbind(3LDAP),
     ldapresult(3LDAP),       ldapparseextendedresult(3LDAP),
     ldapparseresult(3LDAP),
     ldapparsesaslbindresult(3LDAP),      ldapsearch(3LDAP),
     malloc(3C), perror(3C) , attributes(5)















SunOS 5.11          Last change: 11 Nov 2008                    7



OpenSolaris man pages main menu

Contact us      |       About us      |       Term of use      |       Copyright © 2000-2010 MyWebUniversity.com ™