[Mailman-Users] Confused about data/aliases* permissions

Todd Zullinger tmz at pobox.com
Sun Dec 11 19:01:55 CET 2005

Mark Sapiro wrote:
> The real issue is bin/check_perms doesn't check aliases.db. This is a
> known problem; see
> <https://sourceforge.net/tracker/?func=detail&atid=100103&aid=1204386&group_id=103>.

I made a small patch for this a while back and sent it to the list,
but it never made it in.  At the least, the docs covering Postfix
installation ought to be updated so that anyone following them isn't
left wondering what's wrong.  I'll attach the patch again (reworked
against a fresh CVS checkout since README.POSTFIX is now rolled into
mailman-install.*).  Hope this helps someone...

(I'd attach this to the tracker item listed above, but I have no idea
how to do that from a quick look at the SF site.)

Todd        OpenPGP -> KeyID: 0xD654075A | URL: www.pobox.com/~tmz/pgp
I have to decide between two equally frightening options.  If I wanted
to do that, I'd vote.
    -- Duckman

-------------- next part --------------
Index: Mailman/MTA/Postfix.py
RCS file: /cvsroot/mailman/mailman/Mailman/MTA/Postfix.py,v
retrieving revision 2.23
diff -u -r2.23 Postfix.py
--- Mailman/MTA/Postfix.py	27 Aug 2005 01:54:02 -0000	2.23
+++ Mailman/MTA/Postfix.py	11 Dec 2005 17:42:17 -0000
@@ -339,7 +339,7 @@
                 owner = pwd.getpwuid(stat[ST_UID])[0]
             except KeyError:
                 owner = 'uid %d' % stat[ST_UID]
-            print _('%(dbfile)s owned by %(owner)s (must be owned by %(user)s')
+            print _('%(dbfile)s owned by %(owner)s (must be owned by %(user)s'),
             state.ERRORS += 1
             if state.FIX:
                 print _('(fixing)')
@@ -348,3 +348,12 @@
                 os.chown(dbfile, uid, gid)
+        if stat and (stat[ST_MODE] & targetmode) <> targetmode:
+            state.ERRORS += 1
+            octmode = oct(stat[ST_MODE])
+            print _('%(dbfile)s permissions must be 066x (got %(octmode)s)'),
+            if state.FIX:
+                print _('(fixing)')
+                os.chmod(dbfile, stat[ST_MODE] | targetmode)
+            else:
+                print
Index: doc/mailman-install.tex
RCS file: /cvsroot/mailman/mailman/doc/mailman-install.tex,v
retrieving revision 1.2
diff -u -r1.2 mailman-install.tex
--- doc/mailman-install.tex	28 Aug 2005 04:06:59 -0000	1.2
+++ doc/mailman-install.tex	11 Dec 2005 17:42:19 -0000
@@ -472,13 +472,14 @@
       Make sure that the owner of the \file{data/aliases} and
-      \file{data/aliases.db} file is \code{mailman} and that the group owner
+      \file{data/aliases.db} file is \code{mailman}, that the group owner
       for those files is \code{mailman}, or whatever user and group you used
-      in the configure command:
+      in the configure command, and that both files are group writable:
         % su
         % chown mailman:mailman data/aliases*
+        % chmod g+w data/aliases*
 \item Hack your Postfix's \file{main.cf} file to include the following path in
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 315 bytes
Desc: not available
Url : http://mail.python.org/pipermail/mailman-users/attachments/20051211/ac29758f/attachment.pgp 

More information about the Mailman-Users mailing list