Missing UpdateChannels.txt

Use this forum for discussions about SpamAssassin and anti-spam in general.
Post Reply
palinka
Senior user
Senior user
Posts: 2321
Joined: 2017-09-12 17:57

Missing UpdateChannels.txt

Post by palinka » 2020-11-14 02:16

I had a server crash recently and reinstalled spamassassin and for some reason its missing UpdateChannels.txt. I can't update without it. I looked over the interwebs for a copy but came up short (my google fu is white belt). Anyone care to share a copy?

User avatar
jimimaseye
Moderator
Moderator
Posts: 8849
Joined: 2011-09-08 17:48

Re: Missing UpdateChannels.txt

Post by jimimaseye » 2020-11-14 10:33

I will fire up the computermator later and send it you.

[Entered by mobile. Excuse my spelling.]
5.7 on test.
SpamassassinForWindows 3.4.0 spamd service
AV: Clamwin + Clamd service + sanesecurity defs : https://www.hmailserver.com/forum/viewtopic.php?f=21&t=26829

palinka
Senior user
Senior user
Posts: 2321
Joined: 2017-09-12 17:57

Re: Missing UpdateChannels.txt

Post by palinka » 2020-11-14 15:04

Thanks! đź‘Ť

User avatar
jimimaseye
Moderator
Moderator
Posts: 8849
Joined: 2011-09-08 17:48

Re: Missing UpdateChannels.txt

Post by jimimaseye » 2020-11-14 15:42

This is the contents of my UpdateChannels.txt:

Code: Select all

updates.spamassassin.org
# xsaupdate.jam-software.com   ## REMOVED - no longer issued in free version due to duplications.
sa.zmi.at
sought.rules.yerp.org
spamassassin.heinlein-support.de
(This is from my laptop. I dont remember adjusting/adding anything, it is dated 2016 as is the rest of the files in the folder, so this should be as installed but I wouldnt want to bet my sons life on it).
5.7 on test.
SpamassassinForWindows 3.4.0 spamd service
AV: Clamwin + Clamd service + sanesecurity defs : https://www.hmailserver.com/forum/viewtopic.php?f=21&t=26829

palinka
Senior user
Senior user
Posts: 2321
Joined: 2017-09-12 17:57

Re: Missing UpdateChannels.txt

Post by palinka » 2020-11-14 16:06

Thank ye mightily!

Interesting ruleset. I don't recall seeing sa.zmi.at & sought.rules.yerp.org in my updates before. I wonder where i even obtained the channels i was using.

If updatechannels.txt is not part of jam SA, then i must have obtained it from a tutorial here. I wonder if it's ever been part of jam's install?

User avatar
jimimaseye
Moderator
Moderator
Posts: 8849
Joined: 2011-09-08 17:48

Re: Missing UpdateChannels.txt

Post by jimimaseye » 2020-11-14 16:19

palinka wrote: ↑
2020-11-14 16:06
If updatechannels.txt is not part of jam SA, then i must have obtained it from a tutorial here. I wonder if it's ever been part of jam's install?
It definitely is part of the Jam install. Dont know why you dont have it if you did a fresh install.

Ive looked further:

updates_spamassassin_org.cf = standard spamassassin

xsaupdate_jam-software_com.cf = standard Jam but I removed them due to duplicate rules

Code: Select all

include xsaupdate_jam-software_com/jam.cf
include xsaupdate_jam-software_com/x_jam_rescores.cf
spamassassin_heinlein-support_de.cf = I think Jam (German company) also added these (these are German language rules - I wouldnt be interested in that)

Code: Select all

include spamassassin_heinlein-support_de/20_blatspammer.cf
include spamassassin_heinlein-support_de/70_HS_body.cf
include spamassassin_heinlein-support_de/70_HS_header.cf
sa_zmi_at.cf = These also are German rules. Cant see why I would add them myself (so maybe also supplied by Jam)

Code: Select all

include sa_zmi_at/70_zmi_german.cf
sought_rules_yerp_org.cf = I think these were added by Jam but cant be sure.

Code: Select all

include sought_rules_yerp_org/20_sought.cf
include sought_rules_yerp_org/20_sought_fraud.cf
5.7 on test.
SpamassassinForWindows 3.4.0 spamd service
AV: Clamwin + Clamd service + sanesecurity defs : https://www.hmailserver.com/forum/viewtopic.php?f=21&t=26829

User avatar
SorenR
Senior user
Senior user
Posts: 4027
Joined: 2006-08-21 15:38
Location: Denmark

Re: Missing UpdateChannels.txt

Post by SorenR » 2020-11-14 17:29

Sought rules are defunkt and zmi and heinlein are german language.

Which leaves "updates.spamassassin.org" as the only choice :mrgreen:
SørenR.

Algorithm (noun.)
Word used by programmers when they do not want to explain what they did.

palinka
Senior user
Senior user
Posts: 2321
Joined: 2017-09-12 17:57

Re: Missing UpdateChannels.txt

Post by palinka » 2020-11-14 19:11

SorenR wrote: ↑
2020-11-14 17:29
Sought rules are defunkt and zmi and heinlein are german language.

Which leaves "updates.spamassassin.org" as the only choice :mrgreen:
That greatly simplifies things. :mrgreen:

palinka
Senior user
Senior user
Posts: 2321
Joined: 2017-09-12 17:57

Re: Missing UpdateChannels.txt

Post by palinka » 2020-11-14 19:20

So the update syntax should be:

Code: Select all

sa-update -v --nogpg --channel updates.spamassassin.org
Or just simply:

Code: Select all

sa-update --channel updates.spamassassin.org
? :?: ?

palinka
Senior user
Senior user
Posts: 2321
Joined: 2017-09-12 17:57

Re: Missing UpdateChannels.txt

Post by palinka » 2020-11-14 19:26

jimimaseye wrote: ↑
2020-11-14 16:19
It definitely is part of the Jam install. Dont know why you dont have it if you did a fresh install.
Very strange indeed. I searched the folder. Nothing. I looked in program data too, in case something got put there (no, as expected).

User avatar
jimimaseye
Moderator
Moderator
Posts: 8849
Joined: 2011-09-08 17:48

Re: Missing UpdateChannels.txt

Post by jimimaseye » 2020-11-14 21:56

sa-update.bat

Code: Select all

cd C:\Program Files\JAM Software\SpamAssassin for Windows
sa-update -v --nogpg --channelfile UpdateChannels.txt
(updatechannels.txt is in C:\Program Files\JAM Software\SpamAssassin for Windows)
5.7 on test.
SpamassassinForWindows 3.4.0 spamd service
AV: Clamwin + Clamd service + sanesecurity defs : https://www.hmailserver.com/forum/viewtopic.php?f=21&t=26829

palinka
Senior user
Senior user
Posts: 2321
Joined: 2017-09-12 17:57

Re: Missing UpdateChannels.txt

Post by palinka » 2020-11-15 04:54

jimimaseye wrote: ↑
2020-11-14 21:56
sa-update.bat

Code: Select all

cd C:\Program Files\JAM Software\SpamAssassin for Windows
sa-update -v --nogpg --channelfile UpdateChannels.txt
(updatechannels.txt is in C:\Program Files\JAM Software\SpamAssassin for Windows)
If there's only one usable channel, why not simply call it?

I looked up the arguments for sa-update.

Code: Select all

  --channel channel       Retrieve updates from this channel
                          Use multiple times for multiple channels
  --channelfile file      Retrieve updates from the channels in the file
  --checkonly             Check for update availability, do not install
  --install filename      Install updates directly from this file. Signature
                          verification will use "file.asc" and "file.sha1"
  --allowplugins          Allow updates to load plugin code
  --gpgkey key            Trust the key id to sign releases
                          Use multiple times for multiple keys
  --gpgkeyfile file       Trust the key ids in the file to sign releases
  --gpghomedir path       Store the GPG keyring in this directory
  --gpg and --nogpg       Use (or do not use) GPG to verify updates
                          (--gpg is assumed by use of the above
                          --gpgkey and --gpgkeyfile options)
  --import file           Import GPG key(s) from file into sa-update's
                          keyring. Use multiple times for multiple files
  --updatedir path        Directory to place updates, defaults to the
                          SpamAssassin site rules directory
                          (default: /home/parker/perl5/perlbrew/perls/perl-5.14.1/var/spamassassin/3.003003)
  --refreshmirrors        Force the MIRRORED.BY file to be updated
  -D, --debug [area=n,...]  Print debugging messages
  -v, --verbose           Be more verbose, like print updated channel names
  -V, --version           Print version
  -h, --help              Print usage message
I'm going to try sa-update -v --nogpg --channel updates.spamassassin.org in tonight's backup routine.

In my powershell backup script, -v is very helpful. If no fresh updates, I add a line to the email body so you know. That's to distinguish between an error and an informational message. That's one of the minor things that annoyed me about your otherwise really great backup script.

Code: Select all

	$SAUD = "$SADir\sa-update.exe"
	Try {
		$SAUpdate = & $SAUD -v --nogpg --channel updates.spamassassin.org | Out-String
		Debug $SAUpdate
		Debug "Finished updating SpamAssassin in $(ElapsedTime $BeginSAUpdate)"
		Email "[OK] SpamAssassin updated"
		If ($SAUpdate -match "Update finished, no fresh updates were available"){
			Email "[INFO] No fresh SpamAssassin updates available"
		}
	}
	Catch {
		Debug "[ERROR] SpamAssassin update : $Error"
		Email "[ERROR] SpamAssassin update : Check Debug Log"
	}


User avatar
jimimaseye
Moderator
Moderator
Posts: 8849
Joined: 2011-09-08 17:48

Re: Missing UpdateChannels.txt

Post by jimimaseye » 2020-11-15 10:30

If there's only one usable channel, why not simply call it?
I'm going to try sa-update -v --nogpg --channel updates.spamassassin.org
Sure. It's the same thing. The channel updates file method is useful if you require to list multiple channels (like as previously supplied by Jam) but also works with only 1.
5.7 on test.
SpamassassinForWindows 3.4.0 spamd service
AV: Clamwin + Clamd service + sanesecurity defs : https://www.hmailserver.com/forum/viewtopic.php?f=21&t=26829

Post Reply