On Wed, 2014-10-01 at 13:19 +0200, A. Schulze wrote: > Hello, > > I had the idea to run my own updateserver for two purposes: > 1. distribute own rules > 2. override existing rules > > But somehow I fail on #2. > > > SA rules normally reside in /var/.../spamassassin/$SA-VERSION/channelname/*.cf > Also the are files /var/.../spamassassin/$SA-VERSION/channelname.cf > including the real files in channelname/ > > Now I had some rules overriding existing SA rules in > /etc/mail/spamassassin/local.cf > These rules I moved to my own channelname and now the defaults from > updates_spamassassin_org > are active again. > > My guess: rules are included in lexical order from
Correct. > /var/.../spamassassin/$SA-VERSION/channelname.cf > and my new channel spamassassin_example_org is *not after* > updates_spamassassin_org > > I proved my guess by "renaming" the channelfiles to z_spamassassin_example_org > ( adjusted the .cf + include also ) > > Immediately the intended override was active again. > > Is my guess right? Yes. > If so, any (other then renaming the channel) chance to modify the order? No. The directory name and accompanying cf file are generated by sa-update based on the channel name. There is no way for the channel to enforce order. Besides picking a channel name that lexicographically comes after the to-be-overridden target channel, you're limited to local post sa-update rename or symlink hacks with additional maintenance cost. -- char *t="\10pse\0r\0dtu\0.@ghno\x4e\xc8\x79\xf4\xab\x51\x8a\x10\xf4\xf4\xc4"; main(){ char h,m=h=*t++,*x=t+2*h,c,i,l=*x,s=0; for (i=0;i<l;i++){ i%8? c<<=1: (c=*++x); c&128 && (s+=h); if (!(h>>=1)||!t[s+h]){ putchar(t[s]);h=m;s=0; }}}