Changing scores/rules on the fly when calling SpamAssassin from MailScanner

Steve Freegard steve.freegard at fsl.com
Wed Jul 11 19:08:09 IST 2007


Hey Matt,

Matt Hampton wrote:
> If I just want to change the bayes username I can (I assume) just do this:
> 
> $f->signal_user_changed(username=>"newuser");
> 
> But how do I revert back to the default?
> 

Just a thought - but wouldn't the default be the user that is running 
MailScanner e.g. the Run As User, so to revert back you'd run:

$f->signal_user_changed(
  username => MailScanner::Config::Value('runasuser'),
  user_dir => undef,
  userstate_dir => MailScanner::Config::Value('spamassassinuserstatedir'));

Hope this helps.

Cheers,
Steve.


More information about the MailScanner mailing list