SA Bugzilla – Bug 4862
[review] CONTACT_ADDRESS superseded by rules file downloaded through sa-update
Last modified: 2006-07-09 17:10:30 UTC
Hi, after installation of SA 3.1.1 share/spamassassin/10_misc.cf contains: report_contact postmaster@example.com Today I tried sa-update for the first time and noticed that the updated file 10_misc.cf contains report_contact @@CONTACT_ADDRESS@@ This leads to reports like this: .. If you have any questions, see @@CONTACT_ADDRESS@@ for details... I think this setting should probably move from 10_misc.cf to the local.cf file so it would not be affected by updates. ciao Klaus
I'm not really sure how we can deal with this yet. The problem being that the @...@ macros are only handled during the install and the values aren't stored anywhere else. So a kluge would be to parse out stuff from the installed rule files and then replace values accordingly, but that's horrible and we shouldn't do it. ;) I'm thinking that the install process ought to create a new file in the default area, perhaps /usr/share/ spamassassin/macros or something, that have the mappings. Or, we just create something like /etc/ mail/spamassassin/install.cf that sets the macro settings, and then things like sa-update doesn't have to worry about it. I don't know, but we should probably do something.
(In reply to comment #1) > I'm thinking that the install process ought to create a new file in the > default area, perhaps /usr/share/spamassassin/macros or something, that > have the mappings. Administrator might want to edit this file, so placing it in /usr would violate FHS. > Or, we just create something like /etc/mail/spamassassin/install.cf > that sets the macro settings, and then things like sa-update doesn't > have to worry about it. That sounds sane... if local.cf is not enough.
ok, after prodding around I think I came up with a pretty easy fix for this. sa-update gets preprocessed during install with the variables defined via the Makefile. Therefore, if we add in macro processing capabilities into sa-update, and trap the defined variables during install, it should all work fine. I'll see about working up a patch. :)
ok, here's the patch ready for 3.1. committed to 3.2: Sending sa-update.raw Transmitting file data . Committed revision 417353.
Created attachment 3562 [details] suggested patch
+1 perfect workaround ;)
cool, +1
Sending sa-update.raw Transmitting file data . Committed revision 420376.