Shared folder permissions made easier with libpam-umask

With User Private Groups, umask of 002 or 007 makes more sense than the traditional umask of 022 when multiple users are working with shared files. Libpam-umask is handy for overriding the default umask setting.

Starting with Debian Lenny, libpam-umask is part of libpam-modules (which was auto installed on every Debian Lenny setup I've done so far), so just need to add the following to "/etc/pam.d/common-session":

session    optional     pam_umask.so umask=002

Be sure to comment out conflicting umask directives elsewhere (e.g. /etc/profile)..

On Debian Etch, an addition step of installing libpam-modules is required:

# aptitude install libpam-umask

Lots of good info on UPG from a RedHat manual.

Leave a comment

NOTE: Enclose quotes in <blockquote></blockquote>. Enclose code in <pre lang="LANG"></pre> (where LANG is one of these).