From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.user/17541 Path: news.gmane.org!not-for-mail From: Steven Arntson Newsgroups: gmane.emacs.gnus.user Subject: Re: newbie spam filtering with gnus Date: Thu, 02 Apr 2015 14:54:42 -0700 Message-ID: <87619eqjq5.fsf@stevenarntson.com> References: <87ego44m0v.fsf@stevenarntson.com> <87oan8c6js.fsf@enricoschumann.net> <87pp7msc3b.fsf@stevenarntson.com> <878ueapdrx.fsf@enricoschumann.net> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1428011713 2240 80.91.229.3 (2 Apr 2015 21:55:13 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 2 Apr 2015 21:55:13 +0000 (UTC) To: info-gnus-english@gnu.org Original-X-From: info-gnus-english-bounces+gegu-info-gnus-english=m.gmane.org@gnu.org Thu Apr 02 23:55:01 2015 Return-path: Envelope-to: gegu-info-gnus-english@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Ydn4m-0003Vk-EG for gegu-info-gnus-english@m.gmane.org; Thu, 02 Apr 2015 23:55:00 +0200 Original-Received: from localhost ([::1]:60259 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ydn4l-0003pA-Sd for gegu-info-gnus-english@m.gmane.org; Thu, 02 Apr 2015 17:54:59 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:58721) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ydn4i-0003on-BU for info-gnus-english@gnu.org; Thu, 02 Apr 2015 17:54:57 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Ydn4f-0007Gq-4p for info-gnus-english@gnu.org; Thu, 02 Apr 2015 17:54:56 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:34712) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ydn4e-0007Ed-Tu for info-gnus-english@gnu.org; Thu, 02 Apr 2015 17:54:53 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1Ydn4c-0003OZ-8L for info-gnus-english@gnu.org; Thu, 02 Apr 2015 23:54:50 +0200 Original-Received: from 104.244.220.59 ([104.244.220.59]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 02 Apr 2015 23:54:50 +0200 Original-Received: from steven by 104.244.220.59 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 02 Apr 2015 23:54:50 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 100 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 104.244.220.59 User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4 (gnu/linux) Cancel-Lock: sha1:KVQ+NLyOP7kfkc/gVTUbvvNkIgk= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 X-BeenThere: info-gnus-english@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Announcements and discussions for GNUS, the GNU Emacs Usenet newsreader \(in English\)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: info-gnus-english-bounces+gegu-info-gnus-english=m.gmane.org@gnu.org Original-Sender: info-gnus-english-bounces+gegu-info-gnus-english=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.gnus.user:17541 Archived-At: Enrico Schumann writes: > On Thu, 02 Apr 2015, Steven Arntson writes: > >> Enrico Schumann writes: >> >>> On Wed, 01 Apr 2015, Steven Arntson writes: >>>> Is there any sort of simple "starter kit" for newcomers getting going on >>>> filtering out spam? >>>> >>>> Thank you for any advice aimed at a not-very-technical person! >>>> -steven >>>> >>> >>> When I used POP some years ago, what worked out of the box for me was >>> using SpamAssassin as an external programme (spamc) during splitting, as >>> described in the manual: >>> >>> http://www.gnu.org/software/emacs/manual/html_node/gnus/SpamAssassin.html >>> >>> To quote from the relevant section: >>> >>> ,---- >>> | [A] solution is to call the external tools during splitting. Example >>> | fancy split method: >>> | >>> | (setq nnmail-split-fancy '(| (: kevin-spamassassin) >>> | ...)) >>> | >>> | (defun kevin-spamassassin () >>> | (save-excursion >>> | (save-restriction >>> | (widen) >>> | (if (eq 1 (call-process-region (point-min) (point-max) >>> | "spamc" nil nil nil "-c")) >>> | "spam")))) >>> `---- >>> >>> >>> >>> Kind regards, >>> Enrico >> >> Thank you for this---I've read, or tried to, the page you've referenced, >> though it's far over my head. I put the code above into my .gnus.el >> file. However, I really am in the dark! For instance, is the `...' in >> the second line of that code an ellipsis telling me to put my own items >> in there, or is it active code that should be preserved? Do I really use >> "kevin-spamassassin" or am I to change that to something that has to do >> with my own system? At present, the code isn't doing anything as far as >> I can tell. > > [Caveat: I cannot test what I describe below since I do not use this > setup any more.] > > First, make sure that SpamAssassin is installed on your system. For > instance, open a terminal and type 'spamc -V', and it should tell you > the installed version. > > Then, in your .gnus.el, add something like this: > > (setq nnmail-split-methods 'nnmail-split-fancy > nnmail-split-fancy '(| (: kevin-spamassassin) > "catchall.inbox")) > > In which "catchall.inbox" is the group to which all non-spam mails go. > > Also add the function kevin-spamassassin, as given in the manual (and > above). The "spam" in the last line of the function is the group to > which spam emails go. > > Good luck. > > [And you may rename 'kevin-spamassassin' as you wish, as long as you > also use that name with 'nnmail-split-fancy'.] Spamc -V does give me a version number, so that seems to be working. I added the code you recommended, so the full splitting/spam-oriented lines of my .gnus are: | (setq nnmail-split-methods 'nnmail-split-fancy | nnmail-split-fancy '(| (: kevin-spamassassin) | "mail.misc")) | | (defun kevin-spamassassin () | (save-excursion | (save-restriction | (widen) | (if (eq 1 (call-process-region (point-min) (point-max) | "spamc" nil nil nil "-c")) | "spam")))) I can receive mail still---all seems to be working, but no spams have yet been filtered. Are there steps I need to take directly with Spamassassin to get it working? Thank you very much for all of your help here! This is the farthest I've yet gotten with this. -steven