3web2ldap plugin classes for Univention Corporate Server
9from ..schema.syntaxes
import (
15 PreformattedMultilineText,
19from .msperson
import DateOfBirth
23 oid: str =
'UniventionObjectType-oid'
24 desc: str =
'Type of UCS object'
25 pattern = re.compile(
'^[a-z_]+/[a-z_]+$')
27syntax_registry.reg_at(
28 UniventionObjectType.oid, [
29 '1.3.6.1.4.1.10176.1003.1',
35 oid: str =
'UniventionPolicyReference-oid'
36 desc: str =
'DN of referenced univentionPolicy entry'
37 ldap_url =
'ldap:///_?cn?sub?(objectClass=univentionPolicy)'
39syntax_registry.reg_at(
40 UniventionPolicyReference.oid, [
41 '1.3.6.1.4.1.10176.1000',
47 oid: str =
'EntryDNUniventionPolicy-oid'
48 desc: str =
'entryDN of an univentionPolicy entry'
51 'univentionPolicyReference',
'Used by',
None,
52 'Search all entries referencing this policy.'
56syntax_registry.reg_at(
57 EntryDNUniventionPolicy.oid, [
59 '1.3.6.1.4.1.4203.666.1.33',
62 '1.3.6.1.4.1.10176.1000.2.2.1',
63 '1.3.6.1.4.1.10176.1000.308.2.1',
68syntax_registry.reg_at(
70 '1.3.6.1.4.1.10176.99',
75syntax_registry.reg_at(
77 '1.3.6.1.4.1.10176.1010.1.1',
78 '1.3.6.1.4.1.10176.1010.1.100',
83syntax_registry.reg_at(
84 DistinguishedName.oid, [
85 '1.3.6.1.4.1.10176.500.1.5',
86 '1.3.6.1.4.1.10176.500.1.6',
87 '1.3.6.1.4.1.10176.1000.11.1.2',
88 '1.3.6.1.4.1.10176.4200.4.2',
89 '1.3.6.1.4.1.10176.1000.308.1.1',
94syntax_registry.reg_at(
96 '1.3.6.1.4.1.10176.4200.1.14',
102 oid: str =
'UniventionLDAPACLData-oid'
103 desc: str =
'bzip2-ed LDAP ACL data in Univention'
106 return bz2.compress(PreformattedMultilineText.sanitize(self, attr_value))
110 self.
_app.ls.uc_decode(line_b)[0]
113 return '\r\n'.join(splitted_lines)
116 Binary.validate(self, bz2.decompress(attr_value))
119 return bz2.decompress(self.
_av).split(b
'\n')
122 return PreformattedMultilineText.display(self, vidx, links)
124syntax_registry.reg_at(
125 UniventionLDAPACLData.oid, [
126 '1.3.6.1.4.1.10176.4202.1.22',
132syntax_registry.reg_syntaxes(__name__)
def _split_lines(self, value)
bytes sanitize(self, bytes attr_value)
def validate(self, bytes attr_value)
str display(self, vidx, links)
def _split_lines(self, value)