On Thu, 21 Dec 2006 09:58:35 +0000 Steve James s.james@bigfoot.com wrote:
Besides, I don't think the use of hardlinks should be relevant: two directory entries that link to the same file are still two different directory entries with their own, individual ownerships and permissions. I could do the experiment if that's useful?
No they're not. :) Hard links are two directory entries ('names') pointing to the same inode: permissions, file ownership, timestamps, etc. are all set at the inode level.
(winslowb@winslowb:/tmp) touch foo (11:32am/3/pts/42) (winslowb@winslowb:/tmp) ls -l foo (11:32am/4/pts/42) -rw-r--r-- 1 winslowb winslowb 0 2006-12-21 11:32 foo (winslowb@winslowb:/tmp) ln foo bar (11:32am/5/pts/42) (winslowb@winslowb:/tmp) ls -l bar (11:32am/6/pts/42) -rw-r--r-- 2 winslowb winslowb 0 2006-12-21 11:32 bar (winslowb@winslowb:/tmp) chmod 600 bar (11:32am/7/pts/42) (winslowb@winslowb:/tmp) ls -l foo bar (11:32am/8/pts/42) -rw------- 2 winslowb winslowb 0 2006-12-21 11:32 bar -rw------- 2 winslowb winslowb 0 2006-12-21 11:32 foo
I think that probably makes umask irrelevant -- but whether dovecot should chmod things when maildir_copy_with_hardlinks is on is a separate discussion.
HTH,
Ben Winslow rain@bluecherry.net