1
0
Fork 0
mirror of https://github.com/kakwa/ldapcherry synced 2025-07-04 20:37:48 +02:00
This commit is contained in:
kakwa 2019-02-07 20:16:39 +01:00
parent be598b0129
commit 3d6e24eb73
5 changed files with 27 additions and 24 deletions

View file

@ -12,14 +12,13 @@ import ldap.filter
import logging
import ldapcherry.backend
import sys
if sys.version < '3':
from sets import Set as set
from ldapcherry.exceptions import UserDoesntExist, \
GroupDoesntExist, \
UserAlreadyExists
import os
import re
if sys.version < '3':
from sets import Set as set
class CaFileDontExist(Exception):
@ -74,7 +73,7 @@ class Backend(ldapcherry.backend.Backend):
self.key = key
# objectclasses parameter is a coma separated list in configuration
# split it to get a real list, and convert it to bytes
for o in re.split('\W+', self.get_param('objectclasses')):
for o in re.split(r'\W+', self.get_param('objectclasses')):
self.objectclasses.append(self._str(o))
self.group_attrs = {}
self.group_attrs_keys = set([])