Gnus development mailing list
 help / color / mirror / Atom feed
* Reporting spam for gmane.org
@ 2003-08-28 18:32 Nicolas Bareil
  2003-08-29 15:34 ` Ted Zlatanov
  0 siblings, 1 reply; 2+ messages in thread
From: Nicolas Bareil @ 2003-08-28 18:32 UTC (permalink / raw)



Hi,

 Background : I  have a personnal news server  which retrieve feeds from
different servers (As news.gmane.org).

I use spam-report.el  to mark article as spam for  gmane groups. So this
function is called :

,----
| (defun spam-report-gmane (article)
|   "Report an article as spam through Gmane"
|   (interactive "nEnter the article number: ")
|   (when (and gnus-newsgroup-name
| 	     (or (null spam-report-gmane-regex)
| 		 (string-match spam-report-gmane-regex gnus-newsgroup-name)))
|     (gnus-message 6 "Reporting spam article %d to spam.gmane.org..." article)
|       (if spam-report-gmane-use-article-number
| 	  (spam-report-url-ping "spam.gmane.org" 
| 		    (format "/%s:%d"
| 			    (gnus-group-real-name gnus-newsgroup-name)
| 			    article))
| 	(with-current-buffer nntp-server-buffer
| 	  (gnus-request-head article gnus-newsgroup-name)
| 	  (goto-char (point-min))
| 	  (if (re-search-forward spam-report-gmane-spam-header nil t)
| 	      (let* ((host (match-string 1))
| 		     (report (match-string 2))
| 		     (url (format "http://%s%s" host report)))
| 		(gnus-message 10 "Reporting spam through URL %s..." url)
| 		(spam-report-url-ping host report))
| 	    (gnus-message 10 "Could not find X-Report-Spam in article %d..."
| 			  article))))))
`----

By   default,  spam-report-gmane-use-article-number  doesn't   exist  so
spam-report.el tries to  get the article number (On  *my* news server) and
contact spam.gmane.org. 

But the  article number is different  between nntp://news.gmane.org/ and
nntp://my.news.server/ so legitimate article are marked as spam.

Could we just change the default setting, or write a warning in the Gnus
manual ?

PS : Personnaly, I've just put this in my ~/.gnus :
(setq spam-report-gmane-use-article-number nil)

-- 
BOFH excuse #309:

firewall needs cooling




^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Reporting spam for gmane.org
  2003-08-28 18:32 Reporting spam for gmane.org Nicolas Bareil
@ 2003-08-29 15:34 ` Ted Zlatanov
  0 siblings, 0 replies; 2+ messages in thread
From: Ted Zlatanov @ 2003-08-29 15:34 UTC (permalink / raw)
  Cc: ding

On Thu, 28 Aug 2003, nbareil+gmane@plop.dyndns.org wrote:

> By default, spam-report-gmane-use-article-number doesn't exist so
> spam-report.el tries to get the article number (On *my* news server)
> and contact spam.gmane.org.
> 
> But the article number is different between nntp://news.gmane.org/
> and nntp://my.news.server/ so legitimate article are marked as spam.
> 
> Could we just change the default setting, or write a warning in the
> Gnus manual ?
> 
> PS : Personnaly, I've just put this in my ~/.gnus :
> (setq spam-report-gmane-use-article-number nil)

I fixed the manual, the diff is appended for your reference.  Thanks
for the report.

I think the default should be to use the article number because the
vast majority of people don't run their own news server.

Ted

Index: gnus.texi
===================================================================
RCS file: /usr/local/cvsroot/gnus/texi/gnus.texi,v
retrieving revision 6.540
diff -u -r6.540 gnus.texi
--- gnus.texi   8 Aug 2003 16:29:26 -0000       6.540
+++ gnus.texi   29 Aug 2003 15:41:01 -0000
@@ -22676,7 +22676,21 @@
 customizing the group parameters or the
 @code{gnus-spam-process-newsgroups} variable.  When this symbol is
 added to a group's @code{spam-process} parameter, the spam-marked
-articles groups will be reported to the Gmane administrators.
+articles groups will be reported to the Gmane administrators via a
+HTTP request.
+
+Gmane can be found at @uref{http://gmane.org}.
+
+@end defvar
+
+@defvar spam-report-gmane-use-article-number
+
+This variable is @code{t} by default.  Set it to @code{nil} if you are
+running your own news server, for instance, and the local article
+numbers don't correspond to the Gmane article numbers.  When
+@code{spam-report-gmane-use-article-number} is @code{nil},
+@code{spam-report.el} will use the @code{X-Report-Spam} header that
+Gmane provides.
 
 @end defvar



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2003-08-29 15:34 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-08-28 18:32 Reporting spam for gmane.org Nicolas Bareil
2003-08-29 15:34 ` Ted Zlatanov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).