tag 422692 + pending thanks On Mon, May 07, 2007 at 01:57:35PM -0400, Scott Kitterman wrote: > I just updated the Ubuntu package for Spamassassin 3.2.0 and wanted to > pass on lessons learned to save you some trouble when you get to it.
Thanks, Scott! Unfortuantely, I read your message, went on vacation and forgot about it, then tried updating the package. Oops! This would have saved me some time for sure if I'd looked at it first. :-( > First, the BUGS file is not present. I worked around this in debian/rules > (expecting we'll see it again) as follows: I did the opposite; I think it's long dead. > I was able to remove 05_CVE_2007_0451.dpatch, 06_SA_BUG_5240.dpatch, and > 08_security_version.dpatch because they were incorporated upstream. > Additionally, I had to freshen the 10_change_config_paths patch. The > updated patch is attached. For 10_change_config_paths, I think you were a little bit eager in UPGRADE (there are some legitimate mentions of /etc/mail/spamassassin -- spamassassin still does look there, even if we don't encourage it). :-) I've attached my version. > As an aside, the Mail::SPF library is now the preferred SPF checking > library for SpamAssassin. The library is not in Debian because > libnetaddr-ip-perl is not new enough. See > http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=329644 for details. Thanks for the pointer, I hadn't looked into that. I've made a bunch of other updates for this version of the package, they should be available from the subversion repository, once I commit them. (Revision 88 on the trunk is pre-3.2.0) svn://svn.debian.org/pkg-sa/spamassassin/trunk -- Duncan Findlay
#! /bin/sh -e ## 10_edit_config_paths.dpatch by Duncan Findlay <[EMAIL PROTECTED]> ## ## All lines beginning with `## DP:' are a description of the patch. ## DP: Change all instances of /etc/mail/spamassassin in the documentation ## DP: to /etc/spamassassin, since thats where the configuration is going. if [ $# -lt 1 ]; then echo "`basename $0`: script expects -patch|-unpatch as argument" >&2 exit 1 fi [ -f debian/patches/00patch-opts ] && . debian/patches/00patch-opts patch_opts="${patch_opts:--f --no-backup-if-mismatch} ${2:+-d $2}" case "$1" in -patch) patch -p1 ${patch_opts} < $0;; -unpatch) patch -R -p1 ${patch_opts} < $0;; *) echo "`basename $0`: script expects -patch|-unpatch as argument" >&2 exit 1;; esac exit 0 @DPATCH@ diff -urNad spamassassin~/INSTALL spamassassin/INSTALL --- spamassassin~/INSTALL 2007-05-01 09:54:33.000000000 -0400 +++ spamassassin/INSTALL 2007-05-21 10:41:03.000000000 -0400 @@ -390,7 +390,7 @@ http://issues.apache.org/SpamAssassin/show_bug.cgi?id=5312 If you do not plan to use this plugin, be sure to comment out - its loadplugin line in "/etc/mail/spamassassin/v310.pre". This + its loadplugin line in "/etc/spamassassin/v310.pre". This will ensure that the slowdown will not affect you. diff -urNad spamassassin~/README spamassassin/README --- spamassassin~/README 2007-05-01 09:54:33.000000000 -0400 +++ spamassassin/README 2007-05-21 10:40:00.000000000 -0400 @@ -104,13 +104,13 @@ Distributed configuration files, with all defaults. Do not modify these, as they are overwritten when you upgrade. - - /etc/mail/spamassassin/*.cf: + - /etc/spamassassin/*.cf: Site config files, for system admins to create, modify, and add local rules and scores to. Modifications here will be appended to the config loaded from the above directory. - - /etc/mail/spamassassin/*.pre: + - /etc/spamassassin/*.pre: Plugin control files, installed from the distribution. These are used to control what plugins are loaded. Modifications here will @@ -119,7 +119,7 @@ You want to modify these files if you want to load additional plugins, or inhibit loading a plugin that is enabled by default. - If the files exist in /etc/mail/spamassassin, they will not + If the files exist in /etc/spamassassin, they will not be overwritten during future installs. - /usr/share/spamassassin/user_prefs.template: @@ -127,14 +127,14 @@ Distributed default user preferences. Do not modify this, as it is overwritten when you upgrade. - - /etc/mail/spamassassin/user_prefs.template: + - /etc/spamassassin/user_prefs.template: Default user preferences, for system admins to create, modify, and set defaults for users' preferences files. Takes precedence over the above prefs file, if it exists. Do not put system-wide settings in here; put them in a file in the - "/etc/mail/spamassassin" directory ending in ".cf". This file is + "/etc/spamassassin" directory ending in ".cf". This file is just a template, which will be copied to a user's home directory for them to change. diff -urNad spamassassin~/UPGRADE spamassassin/UPGRADE --- spamassassin~/UPGRADE 2007-05-01 09:54:33.000000000 -0400 +++ spamassassin/UPGRADE 2007-05-21 10:40:00.000000000 -0400 @@ -24,7 +24,7 @@ perldoc Mail::SpamAssassin::Plugin::* (ie AWL, DCC, etc) - There are now multiple files read to enable plugins in the - /etc/mail/spamassassin directory; previously only one, "init.pre" was + /etc/spamassassin directory; previously only one, "init.pre" was read. Now both "init.pre", "v310.pre", and any other files ending in ".pre" will be read. As future releases are made, new plugins will be added to new files named according to the release they're @@ -181,7 +181,7 @@ - If you are using a UNIX machine with all database files on local disks, and no sharing of those databases across NFS filesystems, you can use a more efficient, but non-NFS-safe, locking mechanism. Do this by adding - the line "lock_method flock" to the /etc/mail/spamassassin/local.cf + the line "lock_method flock" to the /etc/spamassassin/local.cf file. This is strongly recommended if you're not using NFS, as it is much faster than the NFS-safe locker. diff -urNad spamassassin~/USAGE spamassassin/USAGE --- spamassassin~/USAGE 2007-05-01 09:54:33.000000000 -0400 +++ spamassassin/USAGE 2007-05-21 10:40:00.000000000 -0400 @@ -117,7 +117,7 @@ CPU-intensive task before they can send mail to you, so we give that some bonus points. However, it requires that you list what addresses you expect to receive mail for, by adding 'hashcash_accept' lines to - your ~/.spamassassin/user_prefs or /etc/mail/spamassassin/local.cf + your ~/.spamassassin/user_prefs or /etc/spamassassin/local.cf files. See the Mail::SpamAssassin::Plugin::Hashcash manual page for details on how to specify these. @@ -129,14 +129,14 @@ - You can create your own system-wide rules files in - /etc/mail/spamassassin; their filenames should end in ".cf". Multiple + /etc/spamassassin; their filenames should end in ".cf". Multiple files will be read, and SpamAssassin will not overwrite these files when installing a new version. - You should not modify the files in /usr/share/spamassassin; these will be overwritten when you upgrade. Any changes you make in - files in the /etc/mail/spamassassin directory, however, will + files in the /etc/spamassassin directory, however, will override these files. diff -urNad spamassassin~/ldap/README spamassassin/ldap/README --- spamassassin~/ldap/README 2007-05-01 09:54:04.000000000 -0400 +++ spamassassin/ldap/README 2007-05-21 10:40:00.000000000 -0400 @@ -13,7 +13,7 @@ database or LDAP server. SpamAssassin will check the global configuration file (ie. any file matching -/etc/mail/spamassassin/*.cf) for the following settings: +/etc/spamassassin/*.cf) for the following settings: user_scores_dsn ldap://host:port/dc=basedn,dc=de?attr?scope?uid=__USERNAME__ user_scores_ldap_username bind dn diff -urNad spamassassin~/lib/Mail/SpamAssassin/Conf.pm spamassassin/lib/Mail/SpamAssassin/Conf.pm --- spamassassin~/lib/Mail/SpamAssassin/Conf.pm 2007-05-01 09:54:10.000000000 -0400 +++ spamassassin/lib/Mail/SpamAssassin/Conf.pm 2007-05-21 10:40:00.000000000 -0400 @@ -40,7 +40,7 @@ =head1 DESCRIPTION SpamAssassin is configured using traditional UNIX-style configuration files, -loaded from the C</usr/share/spamassassin> and C</etc/mail/spamassassin> +loaded from the C</usr/share/spamassassin> and C</etc/spamassassin> directories. The following web page lists the most important configuration settings @@ -1759,7 +1759,7 @@ These settings differ from the ones above, in that they are considered 'privileged'. Only users running C<spamassassin> from their procmailrc's or -forward files, or sysadmins editing a file in C</etc/mail/spamassassin>, can +forward files, or sysadmins editing a file in C</etc/spamassassin>, can use them. C<spamd> users cannot use them in their C<user_prefs> files, for security and efficiency reasons, unless C<allow_user_rules> is enabled (and then, they may only add rules from below). diff -urNad spamassassin~/lib/Mail/SpamAssassin/Plugin/Test.pm spamassassin/lib/Mail/SpamAssassin/Plugin/Test.pm --- spamassassin~/lib/Mail/SpamAssassin/Plugin/Test.pm 2007-05-01 09:54:09.000000000 -0400 +++ spamassassin/lib/Mail/SpamAssassin/Plugin/Test.pm 2007-05-21 10:40:00.000000000 -0400 @@ -27,7 +27,7 @@ =head1 DESCRIPTION To try this plugin, write the above two lines in the synopsis to -C</etc/mail/spamassassin/plugintest.cf>. +C</etc/spamassassin/plugintest.cf>. =cut diff -urNad spamassassin~/lib/spamassassin-run.pod spamassassin/lib/spamassassin-run.pod --- spamassassin~/lib/spamassassin-run.pod 2007-05-01 09:54:10.000000000 -0400 +++ spamassassin/lib/spamassassin-run.pod 2007-05-21 10:43:19.000000000 -0400 @@ -43,7 +43,7 @@ -p prefs, --prefspath=file, --prefs-file=file Set user preferences file --siteconfigpath=path Path for site configs - (def: /etc/mail/spamassassin) + (def: /etc/spamassassin) --cf='config line' Additional line of configuration -x, --nocreate-prefs Don't create user preferences file -e, --exit-code Exit with a non-zero exit code if the @@ -237,7 +237,7 @@ =item B<--siteconfigpath>=I<path> Use the specified path for locating site-specific configuration files. Ignore -the default directories (usually C</etc/mail/spamassassin> or similar). +the default directories (usually C</etc/spamassassin> or similar). =item B<--cf='config line'> diff -urNad spamassassin~/rules/30_text_fr.cf spamassassin/rules/30_text_fr.cf --- spamassassin~/rules/30_text_fr.cf 2007-05-01 09:54:14.000000000 -0400 +++ spamassassin/rules/30_text_fr.cf 2007-05-21 10:40:00.000000000 -0400 @@ -4,7 +4,7 @@ # Latest revision: 2003/11/14 # # Please don't modify this file as your changes will be overwritten with -# the next update. Use /etc/mail/spamassassin/local.cf instead. +# the next update. Use /etc/spamassassin/local.cf instead. # See 'perldoc Mail::SpamAssassin::Conf' for details. # # <@LICENSE> diff -urNad spamassassin~/rules/30_text_pt_br.cf spamassassin/rules/30_text_pt_br.cf --- spamassassin~/rules/30_text_pt_br.cf 2007-05-01 09:54:14.000000000 -0400 +++ spamassassin/rules/30_text_pt_br.cf 2007-05-21 10:40:00.000000000 -0400 @@ -4,7 +4,7 @@ # Feita por Marcelo Cruzeta ZOE Inform�tica # # Por Favor, n�o modifique este arquivo, pois suas mudan�as ser�o sobrescritas com -# o pr�ximo update. Use /etc/mail/spamassassin/local.cf para isso. +# o pr�ximo update. Use /etc/spamassassin/local.cf para isso. # Veja 'perldoc Mail::SpamAssassin::Conf' para detalhes. # # Este programa � um software gratuito; voc� pode distribu�-lo e/ou modific�-lo diff -urNad spamassassin~/rules/user_prefs.template spamassassin/rules/user_prefs.template --- spamassassin~/rules/user_prefs.template 2007-05-01 09:54:14.000000000 -0400 +++ spamassassin/rules/user_prefs.template 2007-05-21 10:40:00.000000000 -0400 @@ -5,7 +5,7 @@ #* directory. At runtime, if a user has no preferences in their home directory #* already, it will be copied for them, allowing them to perform personalised #* customisation. If you want to make changes to the site-wide defaults, -#* create a file in /etc/spamassassin or /etc/mail/spamassassin instead. +#* create a file in /etc/spamassassin instead. ########################################################################### # How many points before a mail is considered spam. diff -urNad spamassassin~/sa-compile.raw spamassassin/sa-compile.raw --- spamassassin~/sa-compile.raw 2007-05-01 09:54:33.000000000 -0400 +++ spamassassin/sa-compile.raw 2007-05-21 10:42:07.000000000 -0400 @@ -636,7 +636,7 @@ -p prefs, --prefspath=file, --prefs-file=file Set user preferences file --siteconfigpath=path Path for site configs - (default: /etc/mail/spamassassin) + (default: /etc/spamassassin) --cf='config line' Additional line of configuration -D, --debug [area=n,...] Print debugging messages -V, --version Print version @@ -688,7 +688,7 @@ =item B<--siteconfigpath>=I<path> Use the specified path for locating site-specific configuration files. Ignore -the default directories (usually C</etc/mail/spamassassin> or similar). +the default directories (usually C</etc/spamassassin> or similar). =item B<--cf='config line'> diff -urNad spamassassin~/sa-learn.raw spamassassin/sa-learn.raw --- spamassassin~/sa-learn.raw 2007-05-01 09:54:33.000000000 -0400 +++ spamassassin/sa-learn.raw 2007-05-21 10:42:33.000000000 -0400 @@ -598,7 +598,7 @@ -p prefs, --prefspath=file, --prefs-file=file Set user preferences file --siteconfigpath=path Path for site configs - (default: /etc/mail/spamassassin) + (default: /etc/spamassassin) --cf='config line' Additional line of configuration -D, --debug [area=n,...] Print debugging messages -V, --version Print version @@ -755,7 +755,7 @@ =item B<--siteconfigpath>=I<path> Use the specified path for locating site-specific configuration files. Ignore -the default directories (usually C</etc/mail/spamassassin> or similar). +the default directories (usually C</etc/spamassassin> or similar). =item B<--cf='config line'> diff -urNad spamassassin~/spamc/spamc.pod spamassassin/spamc/spamc.pod --- spamassassin~/spamc/spamc.pod 2007-05-01 09:54:26.000000000 -0400 +++ spamassassin/spamc/spamc.pod 2007-05-21 10:40:00.000000000 -0400 @@ -255,8 +255,8 @@ If the B<-F> switch is specified, that file will be used. Otherwise, C<spamc> will attempt to load spamc.conf in C<SYSCONFDIR> (default: -/etc/mail/spamassassin). If that file doesn't exist, and the B<-F> -switch is not specified, no configuration file will be read. +/etc/spamassassin). If that file doesn't exist, and the B<-F> switch +is not specified, no configuration file will be read. Example: diff -urNad spamassassin~/spamd/README spamassassin/spamd/README --- spamassassin~/spamd/README 2007-05-01 09:54:33.000000000 -0400 +++ spamassassin/spamd/README 2007-05-21 10:40:00.000000000 -0400 @@ -105,7 +105,7 @@ If you plan to use Bayesian classification (the BAYES rules) with spamd, you will need to either - 1. modify /etc/mail/spamassassin/local.cf to use a shared database of + 1. modify /etc/spamassassin/local.cf to use a shared database of tokens, by setting the 'bayes_path' setting to a path all users can read and write to. You will also need to set the 'bayes_file_mode' setting to 0666 so that created files are shared, too. diff -urNad spamassassin~/spamd/README.vpopmail spamassassin/spamd/README.vpopmail --- spamassassin~/spamd/README.vpopmail 2007-05-01 09:54:33.000000000 -0400 +++ spamassassin/spamd/README.vpopmail 2007-05-21 10:40:00.000000000 -0400 @@ -43,7 +43,7 @@ /home/vpopmail/domains/somedomain.net/4/userid/.spamassassin/user_prefs 5. One gotcha - cannot have personal AWL dbs - only a sitewide AWL will work. -This is specified in your /etc/mail/spamassassin/local.cf file. Perhaps a +This is specified in your /etc/spamassassin/local.cf file. Perhaps a future enhancement would be to add the capability to have personal AWL db. 6. Of course vpopmail must have the seekable patch installed (see diff -urNad spamassassin~/spamd/spamd.raw spamassassin/spamd/spamd.raw --- spamassassin~/spamd/spamd.raw 2007-05-01 09:54:33.000000000 -0400 +++ spamassassin/spamd/spamd.raw 2007-05-21 10:40:00.000000000 -0400 @@ -2670,7 +2670,7 @@ =item B<--siteconfigpath>=I<path> Use the specified path for locating site-specific configuration files. Ignore -the default directories (usually C</etc/mail/spamassassin> or similar). +the default directories (usually C</etc/spamassassin> or similar). =item B<--cf='config line'> diff -urNad spamassassin~/sql/README spamassassin/sql/README --- spamassassin~/sql/README 2007-05-01 09:54:24.000000000 -0400 +++ spamassassin/sql/README 2007-05-21 10:40:00.000000000 -0400 @@ -18,7 +18,7 @@ SQL preferences. SpamAssassin will check the global configuration file (ie. any file matching -/etc/mail/spamassassin/*.cf) for the following settings: +/etc/spamassassin/*.cf) for the following settings: user_scores_dsn DBI:driver:connection user_scores_sql_username dbusername diff -urNad spamassassin~/sql/README.awl spamassassin/sql/README.awl --- spamassassin~/sql/README.awl 2007-05-01 09:54:24.000000000 -0400 +++ spamassassin/sql/README.awl 2007-05-21 10:40:00.000000000 -0400 @@ -15,7 +15,7 @@ auto_whitelist_factory Mail::SpamAssassin::SQLBasedAddrList SpamAssassin will check the global configuration file (ie. any file -matching /etc/mail/spamassassin/*.cf) for the following settings: +matching /etc/spamassassin/*.cf) for the following settings: user_awl_dsn DBI:driver:database:hostname[:port] user_awl_sql_username dbusername diff -urNad spamassassin~/t/data/testplugin.pm spamassassin/t/data/testplugin.pm --- spamassassin~/t/data/testplugin.pm 2007-05-01 09:54:33.000000000 -0400 +++ spamassassin/t/data/testplugin.pm 2007-05-21 10:40:00.000000000 -0400 @@ -1,6 +1,6 @@ =head1 -To try this out, write these lines to /etc/mail/spamassassin/plugintest.cf: +To try this out, write these lines to /etc/spamassassin/plugintest.cf: loadplugin myTestPlugin header MY_TEST_PLUGIN eval:check_test_plugin()
pgpRAAa6jBXRi.pgp
Description: PGP signature