On 25 Jul 2010, at 18:50, Alban Hertroys wrote:

> Hello,
> 
> I posted a couple of days back about this issue already, but didn't get any 
> replies - may have been because I wasn't subscribed yet.
> 
> In the meantime I switched to training via the Dovecot plugin (which requires 
> the signature to be in the header). I'm using DSPAM 3.9.0 from ports (FreeBSD 
> 7.3).
> 
> I'm seeing this in my logs:
> 
> Jul 25 18:36:52 solfertje dspam[72733]: Signature retrieval for 
> '3,4c4c60f8286211026045283' failed
> Jul 25 18:36:53 solfertje dspam[72733]: Unable to find a valid signature. 
> Aborting.
> Jul 25 18:36:53 solfertje dspam[72733]: process_message returned error -5.  
> dropping message.
> 
> So it successfully extracts the signature from the mail, but can't find it in 
> the database.
> While the database (PostgreSQL 8.3) says:
> 
> dspam=> select uid, signature from dspam_signature_data where signature = 
> '3,4c4
> c60f8286211026045283';                                                        
>   
> uid |         signature         
> -----+---------------------------
>   3 | 3,4c4c60f8286211026045283
> (1 row)
> 
> So the signature is there! What's happening?!?


I researched this some more by turning on more verbose query logging on my 
dspam database, and it turns out the signature lookup is failing to get results 
from a query in _pgsql_drv_getpwnam(), namely:

SELECT uid FROM dspam_virtual_uids WHERE username='user'

For some reason dspam is looking up a user as 'user', while the 
dspam_virtual_uids(username) column contains usernames รก la 
'u...@external.domain'.


My dspam.conf contains:

ParseToHeaders on
ChangeModeOnParse on
ChangeUserOnParse user

(Not all of these options are documented BTW, I had to look up the possible 
options in the source!)

So it should be using my system username ('user') all the way, shouldn't it? 
Instead it seems that it uses 'u...@external.domain' when invoked from Postfix, 
while it uses 'user' when invoked from Dovecot (or, probably, when I forward 
mail to 's...@internal.domain').

Any idea what's causing this discrepancy and what I can do about it?

Alban Hertroys

--
If you can't see the forest for the trees,
cut the trees and you'll see there is no forest.


!DSPAM:1126,4c4d5c52286211783268853!



------------------------------------------------------------------------------
The Palm PDK Hot Apps Program offers developers who use the
Plug-In Development Kit to bring their C/C++ apps to Palm for a share 
of $1 Million in cash or HP Products. Visit us here for more details:
http://ad.doubleclick.net/clk;226879339;13503038;l?
http://clk.atdmt.com/CRS/go/247765532/direct/01/
_______________________________________________
Dspam-user mailing list
Dspam-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspam-user

Reply via email to