- def __init__(self, user):
- searchresult = lc.search_s(BaseDn,ldap.SCOPE_SUBTREE, 'uid=%s'%(user))
+ array_values = ['objectClass', 'keyFingerPrint', 'mailWhitelist', 'mailRBL',
+ 'mailRHSBL', 'supplementaryGid', 'sshRSAAuthKey',
+ 'sudoPassword', 'dnsZoneEntry', 'allowedHost']
+ int_values = ['shadowExpire', 'gidNumber', 'uidNumber']
+ defaults = {
+ 'accountStatus': 'active',
+ 'keyFingerPrint': []
+ }
+
+ @staticmethod
+ def from_search(ldap_connection, base, user):
+ searchresult = ldap_connection.search_s(base, ldap.SCOPE_SUBTREE, 'uid=%s'%(user))