Discussion:
getting MYSQLUIDInSignature to work under 3.6.1
Chris Ryland
2005-11-23 18:09:21 UTC
Permalink
Running 3.6.1 with Postfix, following README's "best case" spam
correction recipe, have

spam: "|/usr/local/dspam/bin/dspam --user root --class=spam
--source=error"

in /etc/postfix/aliases, and

MySQLUIDInSignature on

in $BASE/etc/dspam.conf (though ParseToUser, etc. are all turned off--
is this right?), but DSPAM still isn't able to find the signature,
when I forward spam to spam@<mydomain>.com:

Nov 23 13:01:04 new dspam[6306]: Signature retrieval for
'2,4384ae4262971073712149' failed
Nov 23 13:01:04 new dspam[6306]: Unable to find a valid signature.
Aborting.
Nov 23 13:01:04 new dspam[6306]: process_message returned error -5.
dropping message.

I also have spam-<user> aliases defined (left over from the "old
way"), and when I forward the same spam message to the proper alias,
it's handled correctly.

I'm not using groups of any kind.

I'm sure this has been hashed to death already (I remember various
flare-ups on the mailing list, though I think most of them involved
groups), but can anyone think of anything else I should check?

Cheers & thanks!
--Chris Ryland / Em Software, Inc. / www.emsoftware.com
Shawn Sivy
2005-11-23 21:06:41 UTC
Permalink
I'm not sure which version of MySQL you are using, but I'm using some
build of version 4.1 and needed to enable this line in the dspam.conf file.

# Use this if you have the 4.1 quote bug (see doc/mysql.txt)
MySQLSupressQuote on

-Shawn
Post by Chris Ryland
Running 3.6.1 with Postfix, following README's "best case" spam
correction recipe, have
spam: "|/usr/local/dspam/bin/dspam --user root --class=spam
--source=error"
in /etc/postfix/aliases, and
MySQLUIDInSignature on
in $BASE/etc/dspam.conf (though ParseToUser, etc. are all turned off--
is this right?), but DSPAM still isn't able to find the signature,
Nov 23 13:01:04 new dspam[6306]: Signature retrieval for
'2,4384ae4262971073712149' failed
Nov 23 13:01:04 new dspam[6306]: Unable to find a valid signature.
Aborting.
Nov 23 13:01:04 new dspam[6306]: process_message returned error -5.
dropping message.
I also have spam-<user> aliases defined (left over from the "old
way"), and when I forward the same spam message to the proper alias,
it's handled correctly.
I'm not using groups of any kind.
I'm sure this has been hashed to death already (I remember various
flare-ups on the mailing list, though I think most of them involved
groups), but can anyone think of anything else I should check?
Cheers & thanks!
--Chris Ryland / Em Software, Inc. / www.emsoftware.com
Chris Ryland
2005-11-23 21:11:19 UTC
Permalink
Yes, sorry, meant to mention that I do have that on, given that I'm
running on a PPC (Xserve), and I definitely have the bug without it
being on. (Tested it by hand.)

(Even though Suppress is misspelled; too late to fix now. ;-)
Post by Shawn Sivy
I'm not sure which version of MySQL you are using, but I'm using
some build of version 4.1 and needed to enable this line in the
dspam.conf file.
# Use this if you have the 4.1 quote bug (see doc/mysql.txt)
MySQLSupressQuote on
-Shawn
Post by Chris Ryland
Running 3.6.1 with Postfix, following README's "best case" spam
correction recipe, have
spam: "|/usr/local/dspam/bin/dspam --user root --
class=spam --source=error"
in /etc/postfix/aliases, and
MySQLUIDInSignature on
in $BASE/etc/dspam.conf (though ParseToUser, etc. are all turned
off-- is this right?), but DSPAM still isn't able to find the
Nov 23 13:01:04 new dspam[6306]: Signature retrieval for
'2,4384ae4262971073712149' failed
Nov 23 13:01:04 new dspam[6306]: Unable to find a valid
signature. Aborting.
Nov 23 13:01:04 new dspam[6306]: process_message returned error
-5. dropping message.
I also have spam-<user> aliases defined (left over from the "old
way"), and when I forward the same spam message to the proper
alias, it's handled correctly.
I'm not using groups of any kind.
I'm sure this has been hashed to death already (I remember
various flare-ups on the mailing list, though I think most of
them involved groups), but can anyone think of anything else I
should check?
Cheers & thanks!
--Chris Ryland / Em Software, Inc. / www.emsoftware.com
!DSPAM:2,4384d9f684225209328925!
Cheers!
--Chris Ryland / Em Software, Inc. / www.emsoftware.com
Chris Ryland
2005-11-26 22:07:51 UTC
Permalink
Michael--

That was it! Thanks a zillion.

Jonathan--

Perhaps the documentation should be fixed to say
The 'root' user represents any existing (or any virtual
DSPAM) user on the system. It is
necessary to supply a username on the commandline or DSPAM
will
bail on an error, however the user will be changed
internally once
the signature is read.
to emphasize that it must be a DSPAM user, not a system user, when
using virtual ids.
Hi Chris
I hoped to send this to the list which I tried to join a few days
back. For some reason my list membership hasn't been approved
(yet?) so I've given up.
I'll post this if confirmation come through.
Thought this might help.
Michael
----------
I also had the same problem with the global spam alias as described by
Chris and a number of others recently.
My spam alias is this (I use qmail, so this is my .qmail-spam file)
|/var/dspam/bin/dspam --user root --class=spam --source=error
'signature retrieval for .. failed',
'Unable to find a valid signature', and
'process_message returned error -5',
and doing a manual query for the signature returns 1 record from the
mysql database.
My problem turned out to be that I didn't have a *dspam* user named
'root', even though the user gets changed for retraining.
So I copied an email message to msg.txt then issued the following
# /var/dspam/bin/dspam --user root --deliver=innocent,spam --mode=teft
--feature=chained,noise \
-m -p /var/vpopmail/domains/domain.com/someuser/.procmailrc <
./msg.txt
(procmail refused to deliver it, but all I really wanted was to
create a
dspam user named root).
After that, all my errors disappeared, and mail started getting
retrained as spam.
I later went back and re-read the README file for setting up dspam,
and
The 'root' user represents any existing user on the system.
It is
necessary to supply a username on the commandline or DSPAM
will
bail on an error, however the user will be changed
internally once
the signature is read.
I now take that to mean 'any existing dspam user' if you have virtual
users. In theory I could've just changed my global alias to use
"--user mikedick" rather than issue the shell command above.
A bit about my setup: I use qmail 1.03, dspam-3.6.1, MySQL 4.1.15 and
procmail 3.22.
My dspam config included --enable-virtual-users and --enable-domain-
scale
In dspam.conf I have
MySQLUIDInSignature On
Preference "signatureLocation=headers"
For me, it works with signatureLocation as either headers or message.
I'm not using groups either.
I don't know if this is the whole solution to the problem, but
hopefully it'll help someone.
Cheers,
Michael
Post by Chris Ryland
Running 3.6.1 with Postfix, following README's "best case" spam
correction recipe, have
spam: "|/usr/local/dspam/bin/dspam --user root --
class=spam --source=error"
in /etc/postfix/aliases, and
MySQLUIDInSignature on
in $BASE/etc/dspam.conf (though ParseToUser, etc. are all turned
off-- is this right?), but DSPAM still isn't able to find the
Nov 23 13:01:04 new dspam[6306]: Signature retrieval for
'2,4384ae4262971073712149' failed
Nov 23 13:01:04 new dspam[6306]: Unable to find a valid
signature. Aborting.
Nov 23 13:01:04 new dspam[6306]: process_message returned error
-5. dropping message.
I also have spam-<user> aliases defined (left over from the
"old way"), and when I forward the same spam message to the
proper alias, it's handled correctly.
I'm not using groups of any kind.
I'm sure this has been hashed to death already (I remember
various flare-ups on the mailing list, though I think most of
them involved groups), but can anyone think of anything else I
should check?
Cheers & thanks!
--Chris Ryland / Em Software, Inc. / www.emsoftware.com
!DSPAM:2,4388b97887791774325810!
Cheers!
--Chris Ryland / Em Software, Inc. / www.emsoftware.com

Loading...