How one identifies is not relevant to their work in Debian: remove gender attribute...
authorPeter Palfrader <peter@palfrader.org>
Fri, 23 Nov 2018 09:09:06 +0000 (10:09 +0100)
committerPeter Palfrader <peter@palfrader.org>
Fri, 23 Nov 2018 09:09:27 +0000 (10:09 +0100)
debian/changelog
doc/slapd-config.txt
ud-info
ud-mailgate
userdir-ldap-slapd.conf.in
userdir-ldap.schema

index abf6171..ca26d8c 100644 (file)
@@ -10,6 +10,8 @@ userdir-ldap (0.3.93) UNRELEASED; urgency=medium
     historical dchroot.
   * ud-replicate: move from lockfile(1) to flock.
   * ud-replicate: manually remove __db.<foo>.db.t files before makedb calls.
+  * remove gender attribute from ud-ldap: How one identifies is not relevant
+    to their work in Debian.
 
   [ Ansgar Burchardt ]
   * ud-mailgate: include name of unknown host in error message
index 23a8a1c..6be1948 100644 (file)
@@ -19,7 +19,6 @@ unique_uri ldap:///ou=groups,dc=debian,dc=org?gidNumber,cn?sub
 moduleload /usr/lib/ldap/constraint.so
 overlay constraint
 constraint_attribute mailContentInspectionAction regex ^([mM][aA][rR][kK][uU][pP]|[bB][lL][aA][cC][kK][hH][oO][lL][eE]|[rR][eE][jJ][eE][cC][tT])$
-constraint_attribute gender regex ^(1|2|9|[mM][aA][lL][eE]|[fF][eE][mM][aA][lL][eE]|[uU][nN][sS][pP][eE][cC][iI][fF][iI][eE][dD])$
 
 # End----------
 
diff --git a/ud-info b/ud-info
index 2ed498a..3db0648 100755 (executable)
--- a/ud-info
+++ b/ud-info
@@ -68,7 +68,6 @@ AttrInfo = {"cn": ["First Name", 101],
            "icqUin": ["ICQ UIN",14],
            "jabberJID": ["Jabber ID",15],
            "privateSub": ["Debian-Private",16],
-           "gender": ["Gender",17],
            "birthDate": ["Date of Birth",18],
            "mailDisableMessage": ["Mail Disabled",19],
            "mailGreylisting": ["Mail Greylisting",20],
@@ -103,7 +102,6 @@ AttrPrompt = {"cn": ["Common name or first name"],
               "supplementaryGid": ["Groups the user is in"],
              "allowedHost": ["Grant access to certain hosts"],
               "privateSub": ["Debian-Private mailing list subscription"],
-             "gender": ["ISO5218 Gender code (1=male,2=female,9=unspecified)"],
              "birthDate": ["Date of Birth (YYYYMMDD)"],
              "mailDisableMessage": ["Error message to return via SMTP"],
              "mailGreylisting": ["SMTP Greylisting (TRUE/FALSE)"],
index fd70c37..918f5d0 100755 (executable)
@@ -42,14 +42,6 @@ ValidHostNames = [] # will be initialized in later
 SSHFingerprint = re.compile('^(\d+) ([0-9a-f\:]{47}|SHA256:[0-9A-Za-z/+]{43}) (.+)$')
 SSHRSA1Match = re.compile('^^(.* )?\d+ \d+ \d+')
 
-GenderTable = {"male": '1',
-              "1": '1',
-              "female": '2',
-              "2": '2',
-              "unspecified": '9',
-              "9": '9',
-};
-
 ArbChanges = {"c": "..",
              "l": ".*",
              "facsimileTelephoneNumber": ".*",
@@ -70,7 +62,6 @@ ArbChanges = {"c": "..",
              "mailCallout": "^(TRUE|FALSE)$",
              "mailDefaultOptions": "^(TRUE|FALSE)$",
              "VoIP": ".*",
-             "gender": "^(1|2|9|male|female|unspecified)$",
          "mailContentInspectionAction": "^(reject|blackhole|markup)$",
 };
 
@@ -184,10 +175,6 @@ def DoArbChange(Str,Attrs):
       raise UDFormatError, "Item does not match the required format"+ArbChanges[attrName];
 
    value = G[1];
-   if attrName == 'gender':
-      if G[1] not in GenderTable:
-         raise UDFormatError, "Gender not found in table"
-      value = GenderTable[G[1]]
 
 #   if attrName == 'birthDate':
 #      (re.match("^([0-9]{4})([01][0-9])([0-3][0-9])$",G[1]) {
index 8794277..eca64fd 100644 (file)
@@ -21,7 +21,7 @@ constraint_attribute keyfingerprint regex ^([0-9A-F]{40})$
 # Indexing options
 index gecos,cn,sn,uid,ircNick,hostname,emailForward pres,eq,sub,approx
 index keyfingerprint,homeDirectory,objectClass,loginShell,supplementaryGid pres,eq
-index c,gender,dnsZoneEntry,birthDate,gidNumber,uidNumber pres,eq
+index c,dnsZoneEntry,birthDate,gidNumber,uidNumber pres,eq
 
 # Don't limit queries to the default of 500
 sizelimit 10000
@@ -54,7 +54,7 @@ access to attrs=privateSub
        by * break
 
 # allow users write access to an explicit subset of their fields
-access to attrs=c,l,loginShell,ircNick,labeledURI,icqUIN,jabberJID,onVacation,birthDate,mailDisableMessage,gender,emailforward,mailCallout,mailGreylisting,mailRBL,mailRHSBL,mailWhitelist,mailContentInspectionAction,mailDefaultOptions,facsimileTelephoneNumber,telephoneNumber,postalAddress,postalCode,loginShell,onVacation,latitude,longitude,VoIP,userPassword,sudoPassword,webPassword,rtcPassword,bATVToken
+access to attrs=c,l,loginShell,ircNick,labeledURI,icqUIN,jabberJID,onVacation,birthDate,mailDisableMessage,emailforward,mailCallout,mailGreylisting,mailRBL,mailRHSBL,mailWhitelist,mailContentInspectionAction,mailDefaultOptions,facsimileTelephoneNumber,telephoneNumber,postalAddress,postalCode,loginShell,onVacation,latitude,longitude,VoIP,userPassword,sudoPassword,webPassword,rtcPassword,bATVToken
        by self write
        by * break
 
@@ -73,7 +73,7 @@ access to attrs=sshrsaauthkey
        by * none
 
 # debian.org readable, authenticated user readable
-access to attrs=activity-pgp,activity-from,c,l,loginShell,onVacation,birthDate,mailDisableMessage,gender,emailforward,mailCallout,mailGreylisting,mailRBL,mailRHSBL,mailWhitelist,mailContentInspectionAction,mailDefaultOptions
+access to attrs=activity-pgp,activity-from,c,l,loginShell,onVacation,birthDate,mailDisableMessage,emailforward,mailCallout,mailGreylisting,mailRBL,mailRHSBL,mailWhitelist,mailContentInspectionAction,mailDefaultOptions
        by peername.ip=127.0.0.1 read
        by domain=alioth.debian.org none
        by domain.subtree=@@DOMAIN@@ read
index c9f30e2..b919a63 100644 (file)
@@ -334,12 +334,12 @@ attributetype ( 1.3.6.1.4.1.9586.100.4.2.29
        SUBSTR caseExactIA5SubstringsMatch
        SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 SINGLE-VALUE )
 
-attributetype ( 1.3.6.1.4.1.9586.100.4.2.30
-       NAME 'gender'
-       DESC 'ISO 5218 representation of human gender'
-       EQUALITY integerMatch
-       SINGLE-VALUE
-       SYNTAX 1.3.6.1.4.1.1466.115.121.1.27{1} )
+#attributetype ( 1.3.6.1.4.1.9586.100.4.2.30
+#      NAME 'gender'
+#      DESC 'ISO 5218 representation of human gender'
+#      EQUALITY integerMatch
+#      SINGLE-VALUE
+#      SYNTAX 1.3.6.1.4.1.1466.115.121.1.27{1} )
 
 attributetype ( 1.3.6.1.4.1.9586.100.4.2.31
        NAME 'birthDate'
@@ -588,7 +588,7 @@ objectclass ( 1.3.6.1.4.1.9586.100.4.3.1
              dnsZoneEntry $ emailForward $ icqUin $ ircNick $
              jabberJID $ keyFingerPrint $ latitude $ longitude $ mn $
              onVacation $ privateSub $ sshRSAAuthKey $ supplementaryGid $
-             access $ gender $ birthDate $ mailCallout $ mailGreylisting $
+             access $ birthDate $ mailCallout $ mailGreylisting $
               mailRBL $ mailRHSBL $ mailWhitelist $ VoIP $ mailContentInspectionAction $
               bATVToken $ mailDefaultOptions $ mailPreserveSuffixSeparator
        ) )