Home | Trees | Indices | Help |
---|
|
Instance Methods | |||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
Method Details |
thisClass.adminbind('myADMINPW') binds to the LDAP server with administrative access. The LDAP server's admin DN is stored in thisClass.AdminDN, the administrative password is given through the argument 'myADMINPW'. |
thisClass.bind_norefresh('myDN', 'myPW') as the easyLDAP class does not load any objects into the easyLDAP cache, this method is just an alias for this_class.bind() |
attrtype_needs_objectclass('myATTRIBUTE') returns True if the easyLDAP object in cache needs an additional objectClass before adding the LDAP attribute 'myATTRIBUTE'. If the objectClass dependencies are already all solved, it returns False. The pseudo-boolean funtcion returns None, if there is no such attribute in the server's LDAP schema. |
thisClass.bind('myDN', 'myPW') binds to the LDAP server with the given credentials 'myDN' and 'myPW'. |
thisClass.bind_norefresh('myDN', 'myPW') as the easyLDAP class does not load any objects into the easyLDAP cache, this method is just an alias for this_class.bind() |
check_objectclass_dependencies ('myOBJECT_CLASS'|['myOBJECT_CLASS1', 'myOBJECT_CLASS2']) checks if and what objectClasses are needed before adding them to an LDAP directory. The dependencies are derived from the server's LDAP schema. The method returns a list of ObjectClasses, including those that were given to the method and those that are needed to complete the set. |
thisClass.cnbind('myCN', 'myPW') binds to the LDAP server. This method tries to find the cn's corresponding DN in the LDAP tree starting at thisClass.BaseDN. Binding by CN (Common Name) will fail if the given cn 'myCN' is not unique to the specified LDAP tree. |
thisClass.uid_bind_norefresh('myDN', 'myPW') as the easyLDAP class does not load any objects into the easyLDAP cache, this method is just an alias for this_class.bind() |
searches the connected LDAP server for the lowest vacant gidNumber between minGID and maxGID. If myGROUPSBASEDN is not specified, the easyLDAP thisClass.GroupBaseDN is presumed. The method only checks vacant gidNumber in the connected LDAP tree. Other sources for posixGroupIDs (/etc/groups, NIS, etc.) are not taken into consideration! If an error occurs or no vacant gidNumber can be found, the method returns '-1'. |
self.find_newUidNumber (minUID,maxUID,myPEOPLEBASEDN) live searches the connected LDAP server for the lowest vacant uidNumber between minUID and maxUID. If myPEOPLEBASEDN is not specified, the easyLDAP thisClass.PeoplebaseDN is presumed. The method only checks vacant uidNumber in the connected LDAP tree. Other sources for posixUserIDs (/etc/passwd, NIS, etc.) are not taken into consideration! If an error occurs or no vacant uidNumber can be found, the method returns '-1'. |
thisClass.generate_attributetypes_dict () is for class-internal use only. It is evoked once from thisClass.__init__() to generate the python dictionary thisClass.attributeTypesDict. You should not need to call this method. |
thisClass.generate_ldapsyntaxes__dict () is for class-internal use only. It is evoked once from thisClass.__init__() to generate the python dictionary thisClass.ldapSyntaxesDict. You should not need to call this method. |
is for class-internal use only. It is evoked once from thisClass.__init__() to generate the python dictionary thisClass.objectClassesDict. You should not need to call this method. |
thisClass.get_attrtypealiases('myATTRTYPE') returns a list of attribute types that are treated as aliases in the LDAP server's schema. |
thisClass.get_basedn () returns the absolute DN of the currently cached easyLDAP object/tree/subtree from the LDAP server's directory tree. |
commits a search operation on the LDAP server with starting with thisClass.ObjectCacheBaseDN as the base DN. The result of this operation can be compared to the current content of the easyLDAP cache to figure out what changes have been made to the object in cache by easyLDAP methods. If an error occurs, an empty list will be returned. |
thisClass.get_parent_dn ('myDN') returns the parent absolute DN of 'myDN' from the LDAP server's directory tree. |
thisClass.get_parent_rdn ('myDN') returns the parent relative DN of 'myDN' from the LDAP server's directory tree. |
thisClass.get_samba3_algorithmicRidBase('myDOMAIN') searches the LDAP tree starting at thisClass.BaseDN for the algorithmic RID base of Samba domain 'myDOMAIN'. |
thisClass.get_samba3_domainSID('myDOMAIN') searches the LDAP tree starting at thisClass.BaseDN for the Samba PDC's sambaDomainName entry. When the method can find it, then it will extract the domain's SID. |
thisClass.get_samelevel_dns ('myDN') returns a list with distinguished names that exist on the same level as the given DN 'myDN'. If the DN 'myDN' is alone on its level, it will be the only item in the list. If the returned list is empty, an error occurred. |
thisClass.get_subleveldns ('myDN') returns a list with distinguished names that exist exactly below the given DN 'myDN'. If the easyLDAP object has no objects on its sublevel, the result will be an empty list. If an LDAP error occurs, the list will also be empty! |
thisClass.get_sublevelrdns ('myDN') returns a list with reduced distinguished names that exist exactly below the given DN 'myDN'. If the easyLDAP object has no objects on its sublevel, the result will be an empty list. If an LDAP error occurs, the list will also be empty! |
thisClass.get_subtree_dns (this_dn) returns a tree of all distinguished names that exists below the given DN 'myDN'. If the easyLDAP object has no objects on its sublevel, the result will be an empty list. If an LDAP error occurs, the list will also be empty! |
thisClass.get_used_attroptions('myATTRDESC', [mySINGLELDAPOBJECT]) returns a list of all attribute options used with attribute type same as in 'myATTRDESC'. The comparison is performed on an OID basis. So, if an alias of an 'myATTRDESC' is used, it will be taken into account. |
returns a list of those attribute OIDs, that are currently used in the cached easyLDAP object. This list is taken from the server's LDAP schema. If - by some reason - the easyLDAP object cache is, an empty list is returned. Another LDAP object than the one currently cached can be analyzed by passing 'mySINGLELDAPOBJECT'. The lengths of the passed LDAP object has to be 1. |
returns a list of attribute types that are used in the current easyLDAP object. If - by some reason - the cache is empty, an empty list is returned. Another LDAP object than the one currently cached can be analyzed by passing 'mySINGLELDAPOBJECT'. The lengths of the passed LDAP object has to be 1. |
thisClass.has_dn ('myDN') checks, if the given distinguished name 'myDN' exists in the server's LDAP directory. The searches starts with the thisClass.BaseDN. |
thisClass.has_oid_set('myOID'[, mySINGLELDAPOBJECT]) checks if the given OID 'myOID' is set in the cached easyLDAP object. If so, the method's result is True. Another LDAP object than the one currently cached can be analyzed by passing 'mySINGLELDAPOBJECT'. The lengths of the passed LDAP object has to be 1. |
thisClass.has_parent_dn ('myDN') tests the existence of the referred object with a live search request to the LDAP server. |
thisClass.has_valid_attrtype('myATTRDESC') tests if the given attribute 'myATTRDESC' has a valid attributeType according to the server's LDAP schema. |
thisClass.is_collectiveattr('myATTRIBUTE') tests if the COLLECTIVE flag is set for the LDAP attribute 'myATTRIBUTE'. |
thisClass.is_nousermodattr('myATTRIBUTE') tests if the NO-USER-MODIFICATION flag is set for the LDAP attribute 'myATTRIBUTE'. |
thisClass.is_obsoleteattr('myATTRIBUTE') tests if the OBSOLETE flag is set for the LDAP attribute 'myATTRIBUTE'. |
thisClass.is_ldapobject('myLDAP_DATA') returns True, if the given data structure conforms to the python-ldap data format and only contains data of a single DN. |
thisClass.is_ldaptree('myLDAP_DATA') returns True, if the given data structure conforms to the python-ldap data format and the hierarchical structure is tree-like. |
thisClass.is_singlevalueattr('myATTRIBUTE') tests if the SINGLE-VALUE flag is set for the LDAP attribute 'myATTRIBUTE'. |
thisClass.is_valid_attrtype('myATTRTYPE') tests if the given attribute type 'myATTRTYPE' is a valid attribute type according to the server's LDAP schema. |
thisClass.is_valid_objectclass('myOBJECTCLASS') tests if the given objectClass 'myOBJECTCLASS' is a valid objectClass according to the server's LDAP schema. |
thisClass.map_attrtype2ldapsyntax('myATTRTYPE') returns the LDAPSyntax for the given attribute 'myATTRTYPE'. Using the dictionary thisClass.templateLDAPSyntaxValues will help you to generate a default value for new attribute values: print thisClass.templateLDAPSyntaxValues[ thisClass.map_attrtype2ldapsyntax['myATTRTYPE'] ] |
thisClass.map_attrtype2ldapsyntax('myATTRTYPE') returns the LDAPSyntax for the given attribute 'myATTRTYPE'. Using the dictionary thisClass.templateLDAPSyntaxValues will help you to generate a default value for new attribute values: print thisClass.templateLDAPSyntaxValues[ thisClass.map_attrtype2ldapsyntax['myATTRTYPE'] ] |
thisClass.map_attrtype2ldapsyntaxoid('myATTRTYPE') returns the LDAPSyntax's OID for the given attribute type 'myATTRTYPE'. |
thisClass.map_attrtype2objectclass ('myATTRTYPE') returns a lists of objectClasses that the given attribute 'myATTRTYPE' occurs in. This list is derived from the server's LDAP schema. |
thisClass.map_attrtype2ldapsyntaxoid('myATTRTYPE') returns the LDAPSyntax's OID for the given attribute type 'myATTRTYPE'. |
thisClass.map_attrtypes2oids('myATTRIBUTELIST') maps the given attributes in 'myATTRIBUTELIST' to a list of their unequivocal OIDs. If the mapping fails, an empty list is returned. |
thisClass.map_cn2dn ('myCN') transforms the given common name 'myCN' - if unique - to the corresponding DN in the LDAP tree. The search is started at base DN thisClass.BaseDN. |
thisClass.map_dn2ufn ('myDN'): tries to map a given 'myDN' to a user-friendly DN. This method is taken directly from python-ldap. |
thisClass.map_gid2dn ('myGID') transforms the given gid 'myGID' - if unique - to the corresponding DN in the LDAP tree. The search is started at base DN thisClass.BaseDN. |
thisClass.map_gid2gidNumber ('myGID') transforms the given gid 'myGID' to the corresponding gidNumber. The search is started at base DN thisClass.BaseDN. |
thisClass.map_gidNumber2gid ('myGIDNUMBER') transforms the given gidNumber 'myGIDNUMBER' to the corresponding gid. The search is started at base DN thisClass.BaseDN. |
thisClass.map_objectclass2attr ('myOBJECT_CLASS') returns all attributes that are mentioned in the server's LDAP schema for objectClass 'myOBJECT_CLASS'. |
thisClass.map_oid2attrtypes('myOID') maps the given OID 'myOID' to a list of their possible ATTRIBUTEs according to the LDAP server's LDAP schema. If the mapping fails, an empty list is returned. |
thisClass.map_ou2dn ('myOU', 'mySUBTREE') transforms the given organizationalUnit 'myOU' - if unique - to the corresponding DN in the LDAP tree. The search is started at base DN thisClass.BaseDN. |
thisClass.map_uid2dn ('myUID') transforms the given uid 'myUID' - if unique - to the corresponding DN in the LDAP tree. The search is started at base DN thisClass.BaseDN. |
thisClass.map_uid2posixgroups ('myUID'[,'mySUBTREE']) find all ldap groups that the given uid 'myUID' is a posix member of. As a result the method returns a list of posixGroup DNs. The search is started at base DN thisClass.BaseDN if not otherswise specified in 'mySUBTREE'. |
thisClass.map_uid2uniquemembergroups ('myUID'[,'mySUBTREE']) find all groups that the given uid 'myUID' is a unique member of. As a result the method returns a list of posixGroup DNs. The search is started at base DN thisClass.BaseDN if not otherswise specified in 'mySUBTREE'. |
thisClass.map_uidNumber2uid ('myUIDNUMBER') transforms the given uidNumber 'myUIDNUMBER' to the corresponding uid. The search is started at base DN thisClass.BaseDN. |
thisClass.show_objectclass ('myOBJECT_CLASS'): displays an objectClass's schema in a user-friendly manner... |
thisClass.uid_bind('myUID', 'myPW') binds to the LDAP server. This method tries to find the UID's corresponding DN in the LDAP tree starting at thisClass.BaseDN. Binding by UID will fail if the given UID 'myUID' is not unique to the specified LDAP tree. |
thisClass.uid_bind_norefresh('myUID', 'myPW') as the easyLDAP class does not load any objects into the easyLDAP cache, this method is just an alias for this_class.bind() |
Home | Trees | Indices | Help |
---|
Generated by Epydoc 3.0.1 on Sun Oct 3 15:37:36 2010 | http://epydoc.sourceforge.net |