http://issues.apache.org/SpamAssassin/show_bug.cgi?id=5637
Summary: bayes_file_mode is handled incorrectly when creating
bayes.mutex
Product: Spamassassin
Version: 3.2.3
Platform: Other
OS/Version: other
Status: NEW
Severity: normal
Priority: P5
Component: spamassassin
AssignedTo: [email protected]
ReportedBy: [EMAIL PROTECTED]
bayes_file_mode value is not handled correctly in Locker/Flock.pm, which results
in weird permissions on bayes.mutex. Which then results in
bayes: expire_old_tokens: locker: safe_lock: cannot create lockfile
/var/lib/spamd/bayes.mutex: Permission denied
kind of errors.
The root of the problem is that everywhere except Flock.pm:safe_lock() it is
used as string. (It's always used as oct($main->{conf}->{bayes_file_mode}).)
And safe_lock() could use octal string and numeric values. The default is string
'0700' which works.
But otherwise it's specified as $CONF_TYPE_NUMERIC, so if I put 0770 in config
file, it'll get _decimal_ value 700, which is octal 1402, which is bad. (The
resulting bayes.mutex file get permissions as -r------w-)
Sorry for the lengthy description. Anyway, the fix is trivial: just specify it
as $CONF_TYPE_STRING. Patch is attached.
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.