Hi SA friends, today I turned on the "MySQL-connection" of SA so I can save the config in a mysql database described at "http://www.spamassassin.org/full/2.6x/dist/sql/README". If was satisfied with the results, but one little thing scratched my back. B-)
There a global and a per user config like this example: +--------+-------------+-----------------+-------+ | prefid | username | preference | value | +--------+-------------+-----------------+-------+ | 1 | GLOBAL | rewrite_subject | 0 | | 2 | [EMAIL PROTECTED] | rewrite_subject | 1 | +--------+-------------+-----------------+-------+ The subjects will be *not* rewritten except for the user [EMAIL PROTECTED] So far so good: but I want a per site config (one setting for a whole domain) too, so I extended the table a little bit: +--------+-------------+-----------------+-------+ The 'prefid' | prefid | username | preference | value | is not +--------+-------------+-----------------+-------+ important | 1 | GLOBAL | rewrite_subject | 0 | for the | 2 | [EMAIL PROTECTED] | rewrite_subject | 0 | ordering! | 3 | bar.com | rewrite_subject | 1 | +--------+-------------+-----------------+-------+ Mails to "[EMAIL PROTECTED]" are not(!) marked. Mails to other members of bar.com are marked. All other's are not marked. Got it? 1) global (least important) 2) per site 3) per user (most important) Advantages: - backward compabtible to the "@GLOBAL" and "GLOBAL" settings. - only changes made in "Mail/SpamAssassin/ConfSourceSQL.pm" - no changes in calling the method 'load_with_dbi' - the modified SQL query is fully ANSI compatible (I hope so. B-) No weird MySQL stuff in here. Disadvantages: - The sorting of the parameter of the query is now done by perl My Questions: - Is anybody interessested in the patch? - Is there any chance that this patch goes in the offical release? I would like it! Result: - Please drop a mail if you are interessested I don't wan't to polute the ML more than it's needed. Feedback is welcome. BTW: Thanks to the SA maintainers for the great work. You guys saved my inbox. B-) P.S: I used SA 2.60 for the work but there is no change in the file "Mail/SpamAssassin/ConfSourceSQL.pm" between 2.60 and 2.63. -- So long... Fuzz
