You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@spamassassin.apache.org by "Todd A. Jacobs" <no...@codegnome.org> on 2006/11/26 11:49:53 UTC

How to use --allow-tell?

I was perusing the man pages for spamd in spamassassin 3.1.7, and came
across something that seems to imply that I can use spamc to tell spamd
to update a sitewide bayesian database:

    -l, --allow-tell
	Allow learning and forgetting (to a local Bayes database),
	reporting and revoking (to a remote database) by spamd. The
	client issues a TELL command to tell what type of message is
	being processed and whether local (learn/forget) or remote
	(report/revoke) databases should be updated.

However, I can't find any explanation of how to actually *do* this. What
am I missing here?

-- 
Unabashedly littering the information superhighway with detritus like
this for over 15 years now.


Re: How to use --allow-tell?

Posted by Craig Morrison <cr...@2cah.com>.
Craig Morrison wrote:
> Todd A. Jacobs wrote:
>> I was perusing the man pages for spamd in spamassassin 3.1.7, and came
>> across something that seems to imply that I can use spamc to tell spamd
>> to update a sitewide bayesian database:
>>
>>     -l, --allow-tell
>>     Allow learning and forgetting (to a local Bayes database),
>>     reporting and revoking (to a remote database) by spamd. The
>>     client issues a TELL command to tell what type of message is
>>     being processed and whether local (learn/forget) or remote
>>     (report/revoke) databases should be updated.
>>
>> However, I can't find any explanation of how to actually *do* this. What
>> am I missing here?
>>
> 
> Look at the source code for spamc.. Its in there.
> 
> If you are writing your own `spamc' client, the header set up is:
> 
> TELL SPAMC/1.3
> Message-class: spam|ham
> Set: local|remote
> *or*
> Remove: local|remote
> 
> Followed by the usual 'user' and 'content-length' spamd headers.
> 
> For spamc:
> 
> spamc ... -L spam|ham|forget -C report|revoke ...
> 

Okay, my interpretation of the code was a bit off, but I did find this
(after scratching my head for a while):

http://svn.apache.org/repos/asf/spamassassin/tags/spamassassin_current_release_3.1.x/spamd/PROTOCOL

-- 
Craig

Re: How to use --allow-tell?

Posted by Craig Morrison <cr...@2cah.com>.
Todd A. Jacobs wrote:
> I was perusing the man pages for spamd in spamassassin 3.1.7, and came
> across something that seems to imply that I can use spamc to tell spamd
> to update a sitewide bayesian database:
> 
>     -l, --allow-tell
> 	Allow learning and forgetting (to a local Bayes database),
> 	reporting and revoking (to a remote database) by spamd. The
> 	client issues a TELL command to tell what type of message is
> 	being processed and whether local (learn/forget) or remote
> 	(report/revoke) databases should be updated.
> 
> However, I can't find any explanation of how to actually *do* this. What
> am I missing here?
> 

Look at the source code for spamc.. Its in there.

If you are writing your own `spamc' client, the header set up is:

TELL SPAMC/1.3
Message-class: spam|ham
Set: local|remote
*or*
Remove: local|remote

Followed by the usual 'user' and 'content-length' spamd headers.

For spamc:

spamc ... -L spam|ham|forget -C report|revoke ...

-- 
Craig

Re: How to use --allow-tell?

Posted by Michael Parker <pa...@pobox.com>.
Todd A. Jacobs wrote:
> I was perusing the man pages for spamd in spamassassin 3.1.7, and came
> across something that seems to imply that I can use spamc to tell spamd
> to update a sitewide bayesian database:
> 
>     -l, --allow-tell
> 	Allow learning and forgetting (to a local Bayes database),
> 	reporting and revoking (to a remote database) by spamd. The
> 	client issues a TELL command to tell what type of message is
> 	being processed and whether local (learn/forget) or remote
> 	(report/revoke) databases should be updated.
> 
> However, I can't find any explanation of how to actually *do* this. What
> am I missing here?
> 

Indeed, --allow-tell turns on the TELL command for the spamd protocol.
You can find more about the protocol here:

http://svn.apache.org/repos/asf/spamassassin/trunk/spamd/PROTOCOL

You only need to worry about the specifics of the protocol if you aren't
going to using spamc, since spamc has the commands built in.

>From the spamc man page:

-L learn type
    Send message to spamd for learning.  The "learn type" can be either
spam, ham or
    forget.  The exitcode for spamc will be set to 5 if the message was
learned, or 6
    if it was already learned.

    Note that the "spamd" must run with the "--allow-tell" option for
this to work.


And:

-C report type
    Report or revoke a message to one of the configured collaborative
filtering
    databases.  The "report type" can be either report or revoke.

    Note that the "spamd" must run with the "--allow-tell" option for
this to work.


And example might be:

spamc -u <username> -L spam < spammsg.txt

There are also extensions available for Thunderbird and Outlook that do
this for you:

http://sourceforge.net/projects/soc2006spamd/

Michael