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`  0Sc@sdZddlZddlZddlmZmZddlmZm Z m Z yddlm Z Wne k r}e Z nXi dd6dd6dd6dd 6dd 6dd 6dd 6dd 6dd6Zdd,dYZdefdYZejjidd6dd6dd6dd6dd6ZdefdYZdefdYZd efd!YZd"efd#YZd$efd%YZd&efd'YZd(efd)YZd*ejfd+YZdS(-s schema.py - support for subSchemaSubEntry information See http://www.python-ldap.org/ for details. \$Id: models.py,v 1.47 2014/03/12 21:44:10 stroeder Exp $ iN(t split_tokenstextract_tokens(t TupleTypet StringTypetIntType(t BooleanTypes1.3.6.1.4.1.1466.115.121.1.4s1.3.6.1.4.1.1466.115.121.1.5s1.3.6.1.4.1.1466.115.121.1.8s1.3.6.1.4.1.1466.115.121.1.9s1.3.6.1.4.1.1466.115.121.1.10s1.3.6.1.4.1.1466.115.121.1.23s1.3.6.1.4.1.1466.115.121.1.28s1.3.6.1.4.1.1466.115.121.1.40s1.3.6.1.4.1.1466.115.121.1.49t SchemaElementcBsfeZdZid d6Zd dZdZdZdZddZ ddd Z d Z RS( s Base class for all schema element classes. Not used directly! Arguments: schema_element_str String which contains the schema element description to be parsed. Class attributes: schema_attribute LDAP attribute type containing a certain schema element description token_defaults Dictionary internally used by the schema element parser containing the defaults for certain schema description key-words tDESCcCsR|rNt||j}|j|dt||j}|j||ndS(Ni(Rttoken_defaultstset_idRt _set_attrs(tselftschema_element_strtltd((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyt__init__7s cCs|dd|_dS(NRi(tdesc(R R R((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR >scCs ||_dS(N(toid(R t element_id((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR BscCs|jS(N(R(R ((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pytget_idEsicCsy|dks:t|tks:ttdt||rq|r`d||jddfSd||fSndSdS(Ns%value has to be of StringType, was %ss %s '%s't's\'s %s %st(tNonettypeRtAssertionErrort TypeErrortreprtreplace(R tkeytvaluetquoted((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pytkey_attrHs :t cCst|tks$ttd|s.dS|r`g|D]}d|jdd^q;}n|}t|dkrd||dfSd ||j|fSdS( Nsvalues has to be of ListTypeRs'%s'Rs\'is %s %sis %s ( %s )(RRRRRtlentjoin(R RtvaluestsepRRt quoted_values((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pytkey_listRs$,cCsEt|jg}|j|jd|jddddj|S(NRRis( %s )R(tstrRtappendRRR"(R tresult((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyt__str___s"N(N( t__name__t __module__t__doc__RRRR R RRR&R*(((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR"s       t ObjectClasscBskeZdZdZi d d6dd6dd6dd6dd6dd6dd6dd 6dd 6Zd Zd ZRS(sU Arguments: schema_element_str String containing an ObjectClassDescription Class attributes: oid OID assigned to the object class names This list of strings contains all NAMEs of the object class desc This string contains description text (DESC) of the object class obsolete Integer flag (0 or 1) indicating whether the object class is marked as OBSOLETE in the schema must This list of strings contains NAMEs or OIDs of all attributes an entry of the object class must have may This list of strings contains NAMEs or OIDs of additional attributes an entry of the object class may have kind Kind of an object class: 0 = STRUCTURAL, 1 = ABSTRACT, 2 = AUXILIARY sup This list of strings contains NAMEs or OIDs of object classes this object class is derived from t objectClassestNAMERtOBSOLETEtSUPt STRUCTURALt AUXILIARYtABSTRACTtMUSTtMAYcCs|ddk|_|d|_|dd|_|d|_|d|_d|_|ddkrpd|_n|d dkrd |_n|jdkr|d  r|jd krd|_n |d |_t |jt kst |jdkst |jt kst t |jt krF|jdksL|jdksLt t |jt ksgt t |jtkst t |jt kst t |jt kst dS(NR1R0RiR6R7R5iR4iR2s2.5.6.0ttop(stop(RtobsoletetnamesRtmusttmaytkindRtsupRRRRRR(R R R((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR s*      )  *9cCst|jg}|j|jd|jdd|j|jd|jdd|j|jd|jdd|jidd 6d d6|j|jid d 6d d6d d6|j |j|jd|j dd|j|jd|j ddddj |S(NR0RiRR2R$s $ Ris OBSOLETEs STRUCTURALs ABSTRACTs AUXILIARYiR6R7s( %s )( R'RR(R&R:RRR>R9R=R;R<R"(R R)((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR*s"""")""(N(N((((R+R,R-tschema_attributeRRR R*(((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR.es   ituserApplicationtuserApplicationsitdirectoryOperationitdistributedOperationit dSAOperationt AttributeTypecBseZdZdZidd6dd6dd6dd6dd6dd6dd6dd 6dd 6dd 6dd 6dd6dd6dd6ZdZdZRS(sZ Arguments: schema_element_str String containing an AttributeTypeDescription Class attributes: oid OID assigned to the attribute type names This list of strings contains all NAMEs of the attribute type desc This string contains description text (DESC) of the attribute type obsolete Integer flag (0 or 1) indicating whether the attribute type is marked as OBSOLETE in the schema single_value Integer flag (0 or 1) indicating whether the attribute must have only one value syntax String contains OID of the LDAP syntax assigned to the attribute type no_user_mod Integer flag (0 or 1) indicating whether the attribute is modifiable by a client application equality String contains NAME or OID of the matching rule used for checking whether attribute values are equal substr String contains NAME or OID of the matching rule used for checking whether an attribute value contains another value ordering String contains NAME or OID of the matching rule used for checking whether attribute values are lesser-equal than usage USAGE of an attribute type: 0 = userApplications 1 = directoryOperation, 2 = distributedOperation, 3 = dSAOperation sup This list of strings contains NAMEs or OIDs of attribute types this attribute type is derived from tattributeTypesR0RR1R2tEQUALITYtORDERINGtSUBSTRtSYNTAXs SINGLE-VALUEt COLLECTIVEsNO-USER-MODIFICATIONRAtUSAGEsX-ORIGINs X-ORDEREDc Csk|d|_|dd|_|ddk|_|d|_|dd|_|dd|_|dd|_|d d|_|d d|_ y|d d}Wn#t k rd|_ d|_ nX|dkrd|_ d|_ ny$|d dj d \|_ }Wnstk r|d d|_ d|_ x\|D]=}|jd rA|jd rAt|dd!|_ qAqAWnXt|d |_ |ddk|_|ddk|_|ddk|_tj|ddd|_t|jtks t|jdks4t|jtks4tt|jtksbtdt|jt|jtkr|jdks|jdkstt|jtkr|jdks|jdkstt|jtkr|jdks |jdks t|j dks7t|j tks7t|j dksgt|j tdksgtdS(NR0RiR1R2RGRHRIsX-ORIGINs X-ORDEREDRJt{t}iis SINGLE-VALUERKsNO-USER-MODIFICATIONRLsattribute sup has type %sl(R:RRR9R>tequalitytorderingtsubstrtx_origint x_orderedt IndexErrortsyntaxt syntax_lentsplitt ValueErrort startswithtendswithtlongt single_valuet collectivet no_user_modtAttributeUsagetgettusageRRRRR(R R RRURVti((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR sN        $   !*.999*0cCs(t|jg}|j|jd|jdd|j|jd|jdd|j|jd|jdd|jidd 6d d6|j|j|jd |j |j|jd |j |j|jd |j |j|jd|j |j dkr=|jd|j |j d kn|jidd 6dd6|j|jidd 6dd6|j|jidd 6dd6|j|jidd 6dd6dd6dd6|j|j|jd|jdd|j|jd|jddddj|S(NR0RiRR2R$s $ Ris OBSOLETERGRHRIRJs{%d}s SINGLE-VALUEs COLLECTIVEs NO-USER-MODIFICATIONs USAGE directoryOperations USAGE distributedOperationis USAGE dSAOperationisX-ORIGINs X-ORDEREDs( %s )(R'RR(R&R:RRR>R9RORPRQRURVRR\R]R^RaRRRSR"(R R)((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR*-s0""""$""" ""(N(N((N(N(N(N(RA(N(N(R+R,R-R?RRR R*(((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyREs&,  ,t LDAPSyntaxcBsHeZdZdZid d6d d6d d6d d6ZdZdZRS( s SyntaxDescription oid OID assigned to the LDAP syntax desc This string contains description text (DESC) of the LDAP syntax not_human_readable Integer flag (0 or 1) indicating whether the attribute type is marked as not human-readable (X-NOT-HUMAN-READABLE) t ldapSyntaxesRsX-NOT-HUMAN-READABLEsX-BINARY-TRANSFER-REQUIREDsX-SUBSTcCs|dd|_|dd|_tj|jpE|dddk|_|dddk|_|jdkst|jt kst dS(NRisX-SUBSTsX-NOT-HUMAN-READABLEtTRUEsX-BINARY-TRANSFER-REQUIRED( Rtx_substt NOT_HUMAN_READABLE_LDAP_SYNTAXESthas_keyRtnot_human_readabletx_binary_transfer_requiredRRRR(R R R((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR ]s*cCst|jg}|j|jd|jdd|j|jd|jdd|jidd6dd6|jddj|S( NRRisX-SUBSTRis X-NOT-HUMAN-READABLE 'TRUE's( %s )(R'RR(RRRfRiR"(R R)((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR*gs ""N(N(N(N(N(R+R,R-R?RRR R*(((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyRcIs   t MatchingRulecBsHeZdZdZidd6d d6d d6d d6ZdZdZRS( s Arguments: schema_element_str String containing an MatchingRuleDescription Class attributes: oid OID assigned to the matching rule names This list of strings contains all NAMEs of the matching rule desc This string contains description text (DESC) of the matching rule obsolete Integer flag (0 or 1) indicating whether the matching rule is marked as OBSOLETE in the schema syntax String contains OID of the LDAP syntax this matching rule is usable with t matchingRulesR0RR1RJcCs|d|_|dd|_|ddk|_|dd|_t|jtks]t|jdkst|jtkstt|jt kr|jdks|jdkst|jdkst|jtkstdS(NR0RiR1RJi( R:RRR9RURRRRR(R R R((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR s *9*cCst|jg}|j|jd|jdd|j|jd|jdd|jidd6dd6|j|j|jd|jd dj |S( NR0RiRRis OBSOLETERJs( %s )( R'RR(R&R:RRR9RUR"(R R)((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR*s """(N(N(N(R+R,R-R?RRR R*(((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyRkqs  tMatchingRuleUsecBsHeZdZdZidd6d d6d d6d d6ZdZdZRS( s  Arguments: schema_element_str String containing an MatchingRuleUseDescription Class attributes: oid OID of the accompanying matching rule names This list of strings contains all NAMEs of the matching rule desc This string contains description text (DESC) of the matching rule obsolete Integer flag (0 or 1) indicating whether the matching rule is marked as OBSOLETE in the schema applies This list of strings contains NAMEs or OIDs of attribute types for which this matching rule is used tmatchingRuleUseR0RR1tAPPLIEScCs|d|_|dd|_|ddk|_|d|_t|jtksYt|jdkst|jtkstt|jt kr|jdks|jdkstt|jtkstdS(NR0RiR1Roi( R:RRR9tappliesRRRRR(R R R((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR s  *9cCst|jg}|j|jd|jdd|j|jd|jdd|jidd6dd6|j|j|jd|jd d d dj |S( NR0RiRRis OBSOLETERoR$s $ s( %s )( R'RR(R&R:RRR9RpR"(R R)((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR*s """"(N(N((R+R,R-R?RRR R*(((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyRms  tDITContentRulecBs]eZdZdZid d6d d6d d6dd6dd6dd6dd6Zd Zd ZRS(sZ Arguments: schema_element_str String containing an DITContentRuleDescription Class attributes: oid OID of the accompanying structural object class names This list of strings contains all NAMEs of the DIT content rule desc This string contains description text (DESC) of the DIT content rule obsolete Integer flag (0 or 1) indicating whether the DIT content rule is marked as OBSOLETE in the schema aux This list of strings contains NAMEs or OIDs of all auxiliary object classes usable in an entry of the object class must This list of strings contains NAMEs or OIDs of all attributes an entry of the object class must have which may extend the list of required attributes of the object classes of an entry may This list of strings contains NAMEs or OIDs of additional attributes an entry of the object class may have which may extend the list of optional attributes of the object classes of an entry nots This list of strings contains NAMEs or OIDs of attributes which may not be present in an entry of the object class tdITContentRulesR0RR1tAUXR6R7tNOTcCsS|d|_|dd|_|ddk|_|d|_|d|_|d|_|d|_t|jt kst |jdkst|jt kst t|jt kr|jdks|jd kst t|jt kst t|jt kst t|jt ks4t t|jt ksOt dS( NR0RiR1RsR6R7Rti( R:RRR9tauxR;R<tnotsRRRRR(R R R((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR s     *9cCst|jg}|j|jd|jdd|j|jd|jdd|jidd6dd6|j|j|jd|jd d |j|jd |j d d |j|jd |j d d |j|jd |j d d ddj |S(NR0RiRRis OBSOLETERsR$s $ R6R7Rts( %s )( R'RR(R&R:RRR9RuR;R<RvR"(R R)((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR*s"""""""(N(N(((((R+R,R-R?RRR R*(((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyRqs   tDITStructureRulecBsaeZdZdZid d6d d6d d6dd6dd6ZdZdZd Zd Z RS(s Arguments: schema_element_str String containing an DITStructureRuleDescription Class attributes: ruleid rule ID of the DIT structure rule (only locally unique) names This list of strings contains all NAMEs of the DIT structure rule desc This string contains description text (DESC) of the DIT structure rule obsolete Integer flag (0 or 1) indicating whether the DIT content rule is marked as OBSOLETE in the schema form List of strings with NAMEs or OIDs of associated name forms sup List of strings with NAMEs or OIDs of allowed structural object classes of superior entries in the DIT tdITStructureRulesR0RR1tFORMR2cCs ||_dS(N(truleid(R R((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR ?scCs|jS(N(Rz(R ((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyRBscCs|d|_|dd|_|ddk|_|dd|_|d|_t|jtksjt|jdkst|jt kstt|jt kr|jdks|jdkstt|jt kstt|jtkstdS(NR0RiR1RyR2i( R:RRR9tformR>RRRRR(R R R((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR Es  *9cCst|jg}|j|jd|jdd|j|jd|jdd|jidd6dd6|j|j|jd|jdd|j|jd |j d d d dj |S( NR0RiRRis OBSOLETERyR2R$s $ s( %s )( R'RzR(R&R:RRR9R{R>R"(R R)((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR*Rs"""""(N(N(N(( R+R,R-R?RRR RR R*(((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyRws    tNameFormcBsVeZdZdZid d6d d6d d6d d6dd6dd6ZdZd ZRS(s Arguments: schema_element_str String containing an NameFormDescription Class attributes: oid OID of the name form names This list of strings contains all NAMEs of the name form desc This string contains description text (DESC) of the name form obsolete Integer flag (0 or 1) indicating whether the name form is marked as OBSOLETE in the schema form List of strings with NAMEs or OIDs of associated name forms oc String with NAME or OID of structural object classes this name form is usable with must This list of strings contains NAMEs or OIDs of all attributes an RDN must contain may This list of strings contains NAMEs or OIDs of additional attributes an RDN may contain t nameFormsR0RR1tOCR6R7cCs/|d|_|dd|_|ddk|_|dd|_|d|_|d|_t|jtkswt |jdkst|jt kst t|jt kr|jdks|jdkst t|jt kst t|jtkst t|jtks+t dS( NR0RiR1R~R6R7i( R:RRR9tocR;R<RRRRR(R R R((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR s   *9cCst|jg}|j|jd|jdd|j|jd|jdd|jidd6dd6|j|j|jd|j|j|jd |j d d |j|jd |j d d d dj |S(NR0RiRRis OBSOLETER~R6R$s $ R7s( %s )( R'RR(R&R:RRR9RR;R<R"(R R)((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR*s"""""(N(N(N(((R+R,R-R?RRR R*(((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyR|\s  tEntrycBseZdZdZdZdZdZdZdZdZ dZ d Z d Z d Z dd d ZRS(s Schema-aware implementation of an LDAP entry class. Mainly it holds the attributes in a string-keyed dictionary with the OID as key. cCsHi|_i|_||_||_tjj|i|j|dS(N(t_keytuple2attrtypet_attrtype2keytuplet_stdntUserDictRtupdate(R tschemaRtentry((s8/usr/lib64/python2.7/site-packages/ldap/schema/models.pyRs     cCs{y|j|SWnetk rv|jjtjj|}|jjd}||dsB   CT  (12I?B