On Sat, 26 Jan 2002, dman wrote:
> On Sat, Jan 26, 2002 at 04:40:44PM -0500, Duncan Findlay wrote:
> | On Sat, Jan 26, 2002 at 08:02:40PM +0000, Bryan Ross wrote:
> | > 
> | > My problems come when I try to access files in the User's home
> | > directories, either for a per-user configuration file, or a per-user
> | > whitelist. Basically, 'spamd' tries to write to /mail/.spammassassin/* -
> | > the home directory of the 'mail' user. Im assuming it's looking up its
> | > homedirectory from the password file, and getting the wrong answer.
> | > 
> | > Courier sets $HOME to the home directory of the recipient, so is there a
> | > way I can get 'spamd' to use that instead?
> | 
> | I have a similar problem.  I run spamd as root, and until now, didn't have a
> | .spamassassin dir, so the auto whitelist rule thing didn't work.
> | 
> | Should spamd either a) make the dir, or b) use a tmp dir or other user
> | config dir.
> 
> spamd should use $HOME/.spamassassin for the $HOME of the $USER that
> spamc is run as.  (this is what 1.5 does)
> 
> I dislike apps creating their own config in my home directory.  This
> caused a number of problems when I set up spamassassin because it was
> run by the MTA (user='mail') and not as the user the mail is addressed
> to.

Thats exactly the same problem as I have here. However, Im fortunate that
Courier will fill in the $HOME environment with the correct home
directory- eg, that of the mail recipient.

I noticed in 'spamd' that $ENV{HOME} is removed, I assume for security
reasons. On a very quick skim through the code, it appears the problem is
that 'spamd' is loading up one instance, and just re-using it - so, even
if we make it use $HOME, it will not re-evalute it for every mail.

Anyone have any patches/suggestions for a way round this? I know my
circumstances are coupled with Courier, but I could see this being quite a
common problem.

Thanks,

Bryan.

+-----                      -++-                      -----+
| Bryan Ross                           <[EMAIL PROTECTED]> |
+----------------------------------------------------------+
|  A computer lets you make more mistakes faster than any  |
|  invention in human history- well, apart from tequila... |
+----------------------------------------------------------+
|                            http://www.return0.net/bryan/ |
+-----                      -++-                      -----+


_______________________________________________
Spamassassin-talk mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/spamassassin-talk

Reply via email to