PNG  IHDR;IDATxܻn0K )(pA 7LeG{ §㻢|ذaÆ 6lذaÆ 6lذaÆ 6lom$^yذag5bÆ 6lذaÆ 6lذa{ 6lذaÆ `}HFkm,mӪôô! x|'ܢ˟;E:9&ᶒ}{v]n&6 h_tڠ͵-ҫZ;Z$.Pkž)!o>}leQfJTu іچ\X=8Rن4`Vwl>nG^is"ms$ui?wbs[m6K4O.4%/bC%t Mז -lG6mrz2s%9s@-k9=)kB5\+͂Zsٲ Rn~GRC wIcIn7jJhۛNCS|j08yiHKֶۛkɈ+;SzL/F*\Ԕ#"5m2[S=gnaPeғL lذaÆ 6l^ḵaÆ 6lذaÆ 6lذa; _ذaÆ 6lذaÆ 6lذaÆ RIENDB`  %Sc@s dZddlmZddddgZddlZddlZddlZddlZddlZddlZddl m Z dd l m Z m Z mZdd lmZmZdd lmZdfd YZdefd YZdefdYZeZdS(s ldapobject.py - wraps class _ldap.LDAPObject See http://www.python-ldap.org/ for details. \$Id: ldapobject.py,v 1.138 2014/02/19 20:05:57 stroeder Exp $ Compability: - Tested with Python 2.0+ but should work with Python 1.5.x - LDAPObject class should be exactly the same like _ldap.LDAPObject Usage: Directly imported by ldap/__init__.py. The symbols of _ldap are overridden. Thread-lock: Basically calls into the LDAP lib are serialized by the module-wide lock self._ldap_object_lock. i(t __version__t LDAPObjecttSimpleLDAPObjecttNonblockingLDAPObjecttReconnectLDAPObjectN(t SCHEMA_ATTRS(t LDAPControltDecodeControlTuplestRequestControlTuples(tExtendedRequesttExtendedResponse(t LDAPErrorcBseZdZi ejd6ejd6ejd6ejd6ejd6ej d6ej d6ej d6ej d 6Z d dJd d Zd dZdZdZdZdJdJdZdZdJdJdZdJdJdZdJdJdZdJdJdZdZdZd d dJdJdZd d dJdJdZejdZejdZ dJdJej!dZ"dJdJdZ#dJdJd Z$d!Z%d"Z&dJdJd#Z'dJdJd$Z(d%Z)d&Z*dJdJd'Z+ej,d(dJd)Z-dJdJdJd*Z.dJdJd+Z/dJdJd,Z0d-Z1d.Z2d(d/Z3d(d0Z4dJdJd1Z5dJdJd2Z6dJd(dJdJd3Z7dJd(dJdJd4Z8ej,d(dJd5Z9ej,d(dJd6Z:ej,d(dJdJd7Z;ej,d(dJd d d dJd8Z<d9dJd dJdJd:d d;Z=d9dJd dJdJd:d d<Z>d9dJd d=Z?d9dJd d>Z@d9dJd d:d?ZAd@ZBdJdJdAZCdJdJdBZDdCZEdDZFdJdJdEZGdFZHdGZId dHZJdJdIZKRS(Ks3 Drop-in wrapper class around _ldap.LDAPObject tprotocol_versiontdereft referralst timelimitt sizelimittnetwork_timeoutt error_numbert error_stringt matched_dniicCsy||_|ptj|_||_||_|jd|_tj j tj t j ||_d|_tj|_dS(Ntopcalli(t _trace_leveltsyststdoutt _trace_filet_trace_stack_limitt_urit _ldap_lockt_ldap_object_locktldapt functionst_ldap_function_callt_ldap_module_lockt_ldapt initializet_lttimeouttVERSION3R (tselfturit trace_levelt trace_filettrace_stack_limit((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyt__init__=s   ! tcCs4tjr)tjdd|t|fStjSdS(Ntdescs %s within %s(Rt LIBLDAP_RtLDAPLocktreprR!(R'R.((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRJs  cOs3|jjd}ygzR|||}trg|jdkrg|jdkrg|jjtj }qgnWd|jj XWnTt k r}tr|jdkr|j j d|jjt|fnn_Xtr/|jdkr/|dk r|j j dt|n|j j dtj|n|S(s[ Wrapper method mainly for serializing calls into OpenLDAP libs and trace logs it unbind_extNs=> LDAPError - %s: %s s=> diagnosticMessage: %s s=> result: %s (RtacquiretNonet __debug__Rt__name__R$t get_optionRtOPT_DIAGNOSTIC_MESSAGEtreleaseR Rtwritet __class__tstrR1tpprinttpformat(R'tfunctargstkwargstdiagnostic_message_successtresultte((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyt _ldap_callPs$ )  cCs=|jj|r,|j|j||n ||j| None abandon(msgid) -> None Abandons or cancels an LDAP operation in progress. The msgid should be the message id of an outstanding LDAP operation as returned by the asynchronous methods search(), modify() etc. The caller can expect that the result of an abandoned operation will not be returned from a future call to result(). (RER$t abandon_extR(R'tmsgidt serverctrlst clientctrls((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyROs cCs|j|ddS(N(ROR4(R'RP((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytabandonscCs(|j|jj|t|t|S(sQ cancel(cancelid[,serverctrls=None[,clientctrls=None]]) -> int Send cancels extended operation for an LDAP operation specified by cancelid. The cancelid should be the message id of an outstanding LDAP operation as returned by the asynchronous methods search(), modify() etc. The caller can expect that the result of an abandoned operation will not be returned from a future call to result(). In opposite to abandon() this extended operation gets an result from the server and thus should be preferred if the server supports it. (RER$tcancelR(R'tcancelidRQRR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRTs cCsa|j|||}y"|j|ddd|j}Wn#tjtjfk r\d}nX|S(NtalliR%(RTRCR%Rt CANCELLEDtSUCCESSR4(R'RURQRRRPtres((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytcancel_ss " cCs+|j|jj||t|t|S(s\ add_ext(dn, modlist[,serverctrls=None[,clientctrls=None]]) -> int This function adds a new entry with a distinguished name specified by dn which means it must not already exist. The parameter modlist is similar to the one passed to modify(), except that no operation integer need be included in the tuples. (RER$tadd_extR(R'tdntmodlistRQRR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyR[sc CsR|j||||}|j|ddd|j\}}}} |||| fS(NRViR%(R[tresult3R%( R'R\R]RQRRRPt resp_typet resp_datat resp_msgidt resp_ctrls((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyt add_ext_ss*cCs|j||ddS(s2 add(dn, modlist) -> int This function adds a new entry with a distinguished name specified by dn which means it must not already exist. The parameter modlist is similar to the one passed to modify(), except that no operation integer need be included in the tuples. N(R[R4(R'R\R]((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytaddscCs.|j||}|j|ddd|jS(NRViR%(RdRCR%(R'R\R]RP((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytadd_sscCs+|j|jj||t|t|S(s1 simple_bind([who='' [,cred='']]) -> int (RER$t simple_bindR(R'twhotcredRQRR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRfsc CsR|j||||}|j|ddd|j\}}}} |||| fS(s7 simple_bind_s([who='' [,cred='']]) -> 4-tuple RViR%(RfR^R%( R'RgRhRQRRRPR_R`RaRb((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyt simple_bind_ss*cCs|j||S(s( bind(who, cred, method) -> int (Rf(R'RgRhtmethod((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytbindscCs1|j|||}|j|ddd|jS(s+ bind_s(who, cred, method) -> None RViR%(RkRCR%(R'RgRhRjRP((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytbind_sscCs.|j|jj||t|t||S(sx sasl_interactive_bind_s(who, auth [,serverctrls=None[,clientctrls=None[,sasl_flags=ldap.SASL_QUIET]]]) -> None (RER$tsasl_interactive_bind_sR(R'RgtauthRQRRt sasl_flags((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRmscCs.|j|jj|||t|t|S(s  compare_ext(dn, attr, value [,serverctrls=None[,clientctrls=None]]) -> int compare_ext_s(dn, attr, value [,serverctrls=None[,clientctrls=None]]) -> int compare(dn, attr, value) -> int compare_s(dn, attr, value) -> int Perform an LDAP comparison between the attribute named attr of entry dn, and the value value. The synchronous form returns 0 for false, or 1 for true. The asynchronous form returns the message id of the initiates request, and the result of the asynchronous compare can be obtained using result(). Note that this latter technique yields the answer by raising the exception objects COMPARE_TRUE or COMPARE_FALSE. A design bug in the library prevents value from containing nul characters. (RER$t compare_extR(R'R\tattrRKRQRR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRpsc Csy|j|||||}y.|j|ddd|j\}}} } Wn)tjk r`dStjk rtdSXdS(NRViR%i(RpR^R%Rt COMPARE_TRUEt COMPARE_FALSER4( R'R\RqRKRQRRRPR_R`RaRb((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyt compare_ext_ss.cCs|j|||ddS(N(RpR4(R'R\RqRK((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytcomparescCs|j|||ddS(N(RtR4(R'R\RqRK((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyt compare_sscCs(|j|jj|t|t|S(s delete(dn) -> int delete_s(dn) -> None delete_ext(dn[,serverctrls=None[,clientctrls=None]]) -> int delete_ext_s(dn[,serverctrls=None[,clientctrls=None]]) -> None Performs an LDAP delete operation on dn. The asynchronous form returns the message id of the initiated request, and the result can be obtained from a subsequent call to result(). (RER$t delete_extR(R'R\RQRR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRw s c CsO|j|||}|j|ddd|j\}}}}||||fS(NRViR%(RwR^R%( R'R\RQRRRPR_R`RaRb((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyt delete_ext_ss*cCs|j|ddS(N(RwR4(R'R\((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytdeletescCs|j|ddS(N(RxR4(R'R\((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytdelete_sscCs4|j|jj|j|jt|t|S(s extop(extreq[,serverctrls=None[,clientctrls=None]]]) -> int extop_s(extreq[,serverctrls=None[,clientctrls=None[,extop_resp_class=None]]]]) -> (respoid,respvalue) Performs an LDAP extended operation. The asynchronous form returns the message id of the initiated request, and the result can be obtained from a subsequent call to extop_result(). The extreq is an instance of class ldap.extop.ExtendedRequest. If argument extop_resp_class is set to a sub-class of ldap.extop.ExtendedResponse this class is used to return an object of this class instead of a raw BER value in respvalue. (RER$textopt requestNametencodedRequestValueR(R'textreqRQRR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyR{"sic CsL|j|ddd|jdddddd\}}}}}}||fS(NRViR%t add_ctrlstadd_intermediatest add_extop(tresult4R%( R'RPRVR%t resulttypetmsgt respctrlstrespoidt respvalue((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyt extop_result2sBc Cs|j|||}|j|ddd|j}|r|\}}|j|krstjd|j|fn||j|S|SdS(NRViR%s3Wrong OID in extended response! Expected %s, got %s(R{RR%t responseNameRtPROTOCOL_ERROR( R'R~RQRRtextop_resp_classRPRYRR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytextop_s6s cCs+|j|jj||t|t|S(sN modify_ext(dn, modlist[,serverctrls=None[,clientctrls=None]]) -> int (RER$t modify_extR(R'R\R]RQRR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRAsc CsR|j||||}|j|ddd|j\}}}} |||| fS(NRViR%(RR^R%( R'R\R]RQRRRPR_R`RaRb((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyt modify_ext_sGs*cCs|j||ddS(s modify(dn, modlist) -> int modify_s(dn, modlist) -> None modify_ext(dn, modlist[,serverctrls=None[,clientctrls=None]]) -> int modify_ext_s(dn, modlist[,serverctrls=None[,clientctrls=None]]) -> None Performs an LDAP modify operation on an entry's attributes. dn is the DN of the entry to modify, and modlist is the list of modifications to make to the entry. Each element of the list modlist should be a tuple of the form (mod_op,mod_type,mod_vals), where mod_op is the operation (one of MOD_ADD, MOD_DELETE, MOD_INCREMENT or MOD_REPLACE), mod_type is a string indicating the attribute type name, and mod_vals is either a string value or a list of string values to add, delete, increment by or replace respectively. For the delete operation, mod_vals may be None indicating that all attributes are to be deleted. The asynchronous modify() returns the message id of the initiated request. N(RR4(R'R\R]((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytmodifyLscCs.|j||}|j|ddd|jS(NRViR%(RRCR%(R'R\R]RP((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytmodify_scscCs|j||d|S(sc modrdn(dn, newrdn [,delold=1]) -> int modrdn_s(dn, newrdn [,delold=1]) -> None Perform a modify RDN operation. These routines take dn, the DN of the entry whose RDN is to be changed, and newrdn, the new RDN to give to the entry. The optional parameter delold is used to specify whether the old RDN should be kept as an attribute of the entry or not. The asynchronous version returns the initiated message id. This operation is emulated by rename() and rename_s() methods since the modrdn2* routines in the C library are deprecated. N(trenameR4(R'R\tnewrdntdelold((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytmodrdngscCs|j||d|S(N(trename_sR4(R'R\RR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytmodrdn_swscCs.|j|jj|||t|t|S(N(RER$tpasswdR(R'tusertoldpwtnewpwRQRR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRzscCs7|j|||||}|j|ddd|jS(NRViR%(RRR%(R'RRRRQRRRP((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytpasswd_s}sc Cs1|j|jj||||t|t|S(s rename(dn, newrdn [, newsuperior=None [,delold=1][,serverctrls=None[,clientctrls=None]]]) -> int rename_s(dn, newrdn [, newsuperior=None] [,delold=1][,serverctrls=None[,clientctrls=None]]) -> None Perform a rename entry operation. These routines take dn, the DN of the entry whose RDN is to be changed, newrdn, the new RDN, and newsuperior, the new parent DN, to give to the entry. If newsuperior is None then only the RDN is modified. The optional parameter delold is used to specify whether the old RDN should be kept as an attribute of the entry or not. The asynchronous version returns the initiated message id. This actually corresponds to the rename* routines in the LDAP-EXT C API library. (RER$RR(R'R\Rt newsuperiorRRQRR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRsc CsX|j||||||}|j|ddd|j\}} } } || | | fS(NRViR%(RR^R%( R'R\RRRRQRRRPR_R`RaRb((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRs*cCs(|j|||\}}}||fS(s result([msgid=RES_ANY [,all=1 [,timeout=None]]]) -> (result_type, result_data) This method is used to wait for and return the result of an operation previously initiated by one of the LDAP asynchronous operation routines (eg search(), modify(), etc.) They all returned an invocation identifier (a message id) upon successful initiation of their operation. This id is guaranteed to be unique across an LDAP session, and can be used to request the result of a specific operation via the msgid parameter of the result() method. If the result of a specific operation is required, msgid should be set to the invocation message id returned when the operation was initiated; otherwise RES_ANY should be supplied. The all parameter only has meaning for search() responses and is used to select whether a single entry of the search response should be returned, or to wait for all the results of the search before returning. A search response is made up of zero or more search entries followed by a search result. If all is 0, search entries will be returned one at a time as they come in, via separate calls to result(). If all is 1, the search response will be returned in its entirety, i.e. after all entries and the final search result have been received. For all set to 0, result tuples trickle in (with the same message id), and with the result type RES_SEARCH_ENTRY, until the final result which has a result type of RES_SEARCH_RESULT and a (usually) empty data field. When all is set to 1, only one result is returned, with a result type of RES_SEARCH_RESULT, and all the result tuples listed in the data field. The method returns a tuple of the form (result_type, result_data). The result_type is one of the constants RES_*. See search() for a description of the search result's result_data, otherwise the result_data is normally meaningless. The result() method will block for timeout seconds, or indefinitely if timeout is negative. A timeout of 0 will effect a poll. The timeout can be expressed as a floating-point value. If timeout is None the default in self.timeout is used. If a timeout occurs, a TIMEOUT exception is raised, unless polling (timeout = 0), in which case (None, None) is returned. (tresult2(R'RPRVR%R_R`Ra((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRCs3cCs.|j|||\}}}}|||fS(N(R^(R'RPRVR%R_R`RaRb((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRs!c CsO|j|||ddddddd|\}}}}} } ||||fS(NRiRRtresp_ctrl_classes(R( R'RPRVR%RR_R`Ratdecoded_resp_ctrlstretoidtretval((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyR^s  cCs|dkr|j}n|j|jj||||||}|dkrfd\} } } } } }nt|dkr|\} } } } d\} }n|\} } } } } }|rg| D]'\}}}||t||f^q} nt| |}| | | || |fS(Ni(NNNNNN(NN(R4R%RER$RtlenR(R'RPRVR%RRRRt ldap_resultR_R`RaRbt resp_namet resp_valuetttrtcR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRs  ' 7s(objectClass=*)ic Cs:|j|jj|||||t|t||| S(s search(base, scope [,filterstr='(objectClass=*)' [,attrlist=None [,attrsonly=0]]]) -> int search_s(base, scope [,filterstr='(objectClass=*)' [,attrlist=None [,attrsonly=0]]]) search_st(base, scope [,filterstr='(objectClass=*)' [,attrlist=None [,attrsonly=0 [,timeout=-1]]]]) search_ext(base,scope,[,filterstr='(objectClass=*)' [,attrlist=None [,attrsonly=0 [,serverctrls=None [,clientctrls=None [,timeout=-1 [,sizelimit=0]]]]]]]) search_ext_s(base,scope,[,filterstr='(objectClass=*)' [,attrlist=None [,attrsonly=0 [,serverctrls=None [,clientctrls=None [,timeout=-1 [,sizelimit=0]]]]]]]) Perform an LDAP search operation, with base as the DN of the entry at which to start the search, scope being one of SCOPE_BASE (to search the object itself), SCOPE_ONELEVEL (to search the object's immediate children), or SCOPE_SUBTREE (to search the object and all its descendants). filter is a string representation of the filter to apply in the search (see RFC 4515). Each result tuple is of the form (dn,entry), where dn is a string containing the DN (distinguished name) of the entry, and entry is a dictionary containing the attributes. Attributes types are used as string dictionary keys and attribute values are stored in a list as dictionary value. The DN in dn is extracted using the underlying ldap_get_dn(), which may raise an exception of the DN is malformed. If attrsonly is non-zero, the values of attrs will be meaningless (they are not transmitted in the result). The retrieved attributes can be limited with the attrlist parameter. If attrlist is None, all the attributes of each entry are returned. serverctrls=None clientctrls=None The synchronous form with timeout, search_st() or search_ext_s(), will block for at most timeout seconds (or indefinitely if timeout is negative). A TIMEOUT exception is raised if no result is received within the time. The amount of search results retrieved can be limited with the sizelimit parameter if non-zero. (RER$t search_extR( R'tbasetscopet filterstrtattrlistt attrsonlyRQRRR%R((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRs-    c CsD|j||||||||| } |j| ddd|dS(NRViR%(RRC( R'RRRRRRQRRR%RRP((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyt search_ext_s s'cCs|j|||||ddS(N(RR4(R'RRRRR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytsearch$sc Cs(|j|||||ddd|jS(NR%(RR4R%(R'RRRRR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytsearch_s'sc Cs"|j|||||dd|S(N(RR4(R'RRRRRR%((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyt search_st*scCs|j|jjS(s start_tls_s() -> None Negotiate TLS with server. The `version' attribute must have been set to VERSION3 before calling start_tls_s. If TLS could not be started an exception will be raised. (RER$t start_tls_s(R'((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyR-scCs%|j|jjt|t|S(s unbind() -> int unbind_s() -> None unbind_ext() -> int unbind_ext_s() -> None This call is used to unbind from the directory, terminate the current association, and free resources. Once called, the connection to the LDAP server is closed and the LDAP object is invalid. Further invocation of methods on the object will yield an exception. The unbind and unbind_s methods are identical, and are synchronous in nature (RER$R2R(R'RQRR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyR26scCs\|j||}|dkrX|j|ddd|j\}}}}||||fSdS(NRViR%(R2R4R^R%(R'RQRRRPR_R`RaRb((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyt unbind_ext_sGs *cCs|jddS(N(R2R4(R'((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytunbindMscCs|jddS(N(RR4(R'((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytunbind_sPscCs|j|jj||S(N(RER$twhoami_s(R'RQRR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRSscCsI|j|jj|}|tjks6|tjkrEt|}n|S(N(RER$R7RtOPT_SERVER_CONTROLStOPT_CLIENT_CONTROLSR(R'toptionRC((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyR7VscCsF|tjks|tjkr-t|}n|j|jj||S(N(RRRRRER$RH(R'Rtinvalue((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRH\scCsy"|j|tjddg}Wn=tjtjtjfk rMg}ntjk radSXym|rtjj|dd}|j ddgd}|dkr|r|j ddSdSq|SnWnt k rdSXdS(s Returns the distinguished name of the sub schema sub entry for a part of a DIT specified by dn. None as result indicates that the DN of the sub schema sub entry could not be determined. s(objectClass=*)tsubschemaSubentryiiR\R-N( RRt SCOPE_BASEtNO_SUCH_OBJECTtNO_SUCH_ATTRIBUTEtINSUFFICIENT_ACCESStUNDEFINED_TYPER4tcidicttgettsearch_subschemasubentry_st IndexError(R'R\RRDtsearch_subschemasubentry_dn((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRas$    cCs]|p t}y|j|tjd|}Wntjk rBdSX|rU|ddSdSdS(s1 Returns the sub schema sub entry's data s(objectClass=subschema)iiN(RRRRRR4(R'tsubschemasubentry_dntattrsR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pytread_subschemasubentry_ss    N(LR6t __module__t__doc__RtOPT_PROTOCOL_VERSIONt OPT_DEREFt OPT_REFERRALSt OPT_TIMELIMITt OPT_SIZELIMITtOPT_NETWORK_TIMEOUTtOPT_ERROR_NUMBERtOPT_ERROR_STRINGtOPT_MATCHED_DNRFR4R,RRERLRNRORSRTRZR[RcRdReRfRit AUTH_SIMPLERkRlt SASL_QUIETRmRpRtRuRvRwRxRyRzR{tRES_ANYRRRRRRRRRRRRRCRR^RRRRRRRR2RRRRR7RHRR(((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyR,s           $                6!6      cBsDeZddddZejdddZdddddZRS(iicCs#||_tj||||dS(N(t_result_timeoutRR,(R'R(R)R*tresult_timeout((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyR,s icCs |j|jj|d|j}|s+|Stj}g}x|rx|ddkr|dkrtj||kr|j|jj|tjd|ntj d|j|jj|d|j}qIW|ddkrPn|j |dd}q@W|S(s is#LDAP time limit (%d secs) exceeded.gh㈵>iN(NN( RER$RCRttimeR4RSRtTIMEOUTtsleeptextend(R'RPRVR%Rt start_timet all_results((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRCs$!  " % s(objectClass=*)cCs4|j|||||}|j|ddd|S(NRViR%(RRC(R'RRRRRR%RP((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRsN(R6RR4R,RRRCR(((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRscBseZdZidd6dd6dd6ZddddddZd Zd Zd Zd Z d Z dddZ dZ dZ dZdZdZdZdZdZdZdZdZdZdZdZdZRS(s In case of server failure (ldap.SERVER_DOWN) the implementations of all synchronous operation methods (search_s() etc.) are doing an automatic reconnect and rebind and will retry the very same operation. This is very handy for broken LDAP server implementations (e.g. in Lotus Domino) which drop connections very often making it impossible to have a long-lasting control flow in the application. R$RRiiigN@cCs{||_g|_d|_tj|||||tjddt||_ ||_ ||_ d|_ d|_ dS(s Parameters like SimpleLDAPObject.__init__() with these additional arguments: retry_max Maximum count of reconnect trials retry_delay Time span to wait between two reconnect trials R.sreconnect lock within %silN(Rt_optionsR4t _last_bindRR,RR0R1t_reconnect_lockt _retry_maxt _retry_delayt _start_tlst_reconnects_done(R'R(R)R*R+t retry_maxt retry_delay((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyR,s      cCsIi}x<|jjD]+\}}|jj|s||| delay %s... s;*** %s reconnect to %s successful => repeat last operation l(RR3R5RRR:RRR R!R"R#R$RRRRt SERVER_DOWNRRRRRRR9(R'R(RRtreconnect_countert counter_textRD((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRsB   !           cOs|jjds7|j|jd|jd|jny||||SWnVtjk rtj ||` |j|jd|jd|j||||SXdS(NR$RR( RIRGRRRRRRRRR$(R'R?R@RA((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyt_apply_method_s.s% "cCs)|jj||ftj|||S(N(RtappendRRH(R'RR((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRH;scOs2|jtj||}|jtj|||S(N(RRRlR(R'R@RARY((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRl?scOs2|jtj||}|jtj|||S(N(RRRiR(R'R@RARY((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRiDscOs%|jtj||}d|_|S(Ni(RRRR(R'R@RARY((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRIs cOs2|jtj||}|jtj|||S(s4 sasl_interactive_bind_s(who, auth) -> None (RRRmR(R'R@RARY((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRmNscOs|jtj||S(N(RRRc(R'R@RA((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRcVscOs|jtj||S(N(RRRZ(R'R@RA((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRZYscOs|jtj||S(N(RRRv(R'R@RA((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRv\scOs|jtj||S(N(RRRx(R'R@RA((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRx_scOs|jtj||S(N(RRR(R'R@RA((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRbscOs|jtj||S(N(RRR(R'R@RA((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRescOs|jtj||S(N(RRR(R'R@RA((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRhscOs|jtj||S(N(RRR(R'R@RA((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRkscOs|jtj||S(N(RRR(R'R@RA((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRnsN(R6RRR4RR,RRRRRRRRHRlRiRRmRcRZRvRxRRRRR(((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyRs8        -             (RRRt__all__RRR=R"tldap.functionst ldap.schemaRt ldap.controlsRRRt ldap.extopR R R RRRR(((s5/usr/lib64/python2.7/site-packages/ldap/ldapobject.pyts  Hk"