From 0d0ec9c38991f84768628eee0de17888f29d48ea Mon Sep 17 00:00:00 2001 From: Stephen Gran Date: Sun, 15 Nov 2009 23:27:38 +0000 Subject: [PATCH] default anti-spam options Signed-off-by: Stephen Gran --- ud-generate | 1 + ud-mailgate | 2 ++ userdir-ldap-slapd.conf.in | 2 +- userdir-ldap.schema | 13 +++++++++++-- 4 files changed, 15 insertions(+), 3 deletions(-) diff --git a/ud-generate b/ud-generate index 3b86981..1681e97 100755 --- a/ud-generate +++ b/ud-generate @@ -1182,6 +1182,7 @@ for host in HostAttrs: DoLink(GlobalDir, OutDir, "mail-whitelist") GenCDB(OutDir + "user-forward.cdb", filter(lambda x: IsInGroup(x), PasswdAttrs), 'emailForward') GenCDB(OutDir + "batv-tokens.cdb", filter(lambda x: IsInGroup(x), PasswdAttrs), 'bATVToken') + GenCDB(OutDir + "default-mail-options.cdb", filter(lambda x: IsInGroup(x), PasswdAttrs), 'mailDefaultOptions') # Compatibility. DoLink(GlobalDir, OutDir, "forward-alias") diff --git a/ud-mailgate b/ud-mailgate index d1d340f..31aa9c1 100755 --- a/ud-mailgate +++ b/ud-mailgate @@ -64,6 +64,7 @@ ArbChanges = {"c": "..", "mailDisableMessage": ".*", "mailGreylisting": "^(TRUE|FALSE)$", "mailCallout": "^(TRUE|FALSE)$", + "mailDefaultOptions": "^(TRUE|FALSE)$", "VoIP": ".*", "gender": "^(1|2|9|male|female|unspecified)$", "mailContentInspectionAction": "^(reject|blackhole|markup)$", @@ -94,6 +95,7 @@ DelItems = {"c": None, "mailRHSBL": None, "mailWhitelist": None, "mailDisableMessage": None, + "mailDefaultOptions": None, "VoIP": None, "mailContentInspectionAction": None, }; diff --git a/userdir-ldap-slapd.conf.in b/userdir-ldap-slapd.conf.in index e5ffb6b..7964202 100644 --- a/userdir-ldap-slapd.conf.in +++ b/userdir-ldap-slapd.conf.in @@ -42,7 +42,7 @@ access to attrs=activity-pgp,activity-from,dnsZoneEntry by * none # owner writeable, debian readable, authenticated user readable -access to attrs=c,l,loginShell,ircNick,labeledURI,icqUIN,jabberJID,onVacation,birthDate,mailDisableMessage,gender,emailforward,mailCallout,mailGreylisting,mailRBL,mailRHSBL,mailWhitelist,mailContentInspectionAction +access to attrs=c,l,loginShell,ircNick,labeledURI,icqUIN,jabberJID,onVacation,birthDate,mailDisableMessage,gender,emailforward,mailCallout,mailGreylisting,mailRBL,mailRHSBL,mailWhitelist,mailContentInspectionAction,mailDefaultOptions by group="cn=LDAP Administrator,ou=users,@@DN@@" write by dn="uid=sshdist,ou=users,@@DN@@" write by self write diff --git a/userdir-ldap.schema b/userdir-ldap.schema index 1be2c29..7009474 100644 --- a/userdir-ldap.schema +++ b/userdir-ldap.schema @@ -128,6 +128,7 @@ # .12 - RHS RBL # .13 - whitelist # .14 - bATVToken +# .15 - mailDefaultOptions # Public attribute types attributetype ( 1.3.6.1.4.1.9586.100.4.2.1 @@ -490,6 +491,12 @@ attributetype ( 1.3.6.1.4.1.9586.100.4.4.14 EQUALITY caseExactMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 SINGLE-VALUE ) +attributetype ( 1.3.6.1.4.1.9586.100.4.4.15 + NAME 'mailDefaultOptions' + DESC 'Whether or not to use a default set of anti-spam options' + EQUALITY booleanMatch + SYNTAX 1.3.6.1.4.1.1466.115.121.1.7 SINGLE-VALUE ) + attributetype ( 1.3.6.1.4.1.9586.100.4.2.38 NAME 'mailContentInspectionAction' DESC 'what to do on content inspection hits' @@ -536,7 +543,8 @@ objectclass ( 1.3.6.1.4.1.9586.100.4.3.1 jabberJID $ keyFingerPrint $ latitude $ longitude $ mn $ onVacation $ privateSub $ sshRSAAuthKey $ supplementaryGid $ access $ gender $ birthDate $ mailCallout $ mailGreylisting $ - mailRBL $ mailRHSBL $ mailWhitelist $ VoIP $ mailContentInspectionAction $ bATVToken + mailRBL $ mailRHSBL $ mailWhitelist $ VoIP $ mailContentInspectionAction $ + bATVToken $ mailDefaultOptions ) ) objectclass ( 1.3.6.1.4.1.9586.100.4.3.2 @@ -557,5 +565,6 @@ objectclass ( 1.3.6.1.4.1.9586.100.4.3.3 SUP account STRUCTURAL MAY ( emailForward $ supplementaryGid $ allowedHost $ labeledURI $ mailCallout $ mailGreylisting $ mailRBL $ mailRHSBL $ - mailWhitelist $ dnsZoneEntry $ mailContentInspectionAction $ bATVToken + mailWhitelist $ dnsZoneEntry $ mailContentInspectionAction $ + bATVToken $ mailDefaultOptions ) ) -- 2.20.1