🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nntp
8 messages
8 total messages Started by Roy Tripp III Mon, 16 Dec 1996 00:00
limiting crosposted articles ?
#13328
Author: Roy Tripp III
Date: Mon, 16 Dec 1996 00:00
18 lines
801 bytes


Hello there!

	Is there a simple way to reject articles that are heavely
	crossposted ?

	ie, if an articles is crossposted to more than 4 groups, I
	would like to reject it, (or maybe post it to the first 4 groups
	on the list).

	Thanks.

	Just in case, I am pipping to crosspost!


Re: limiting crosposted articles ?
#13317
Author: darrell
Date: Mon, 16 Dec 1996 00:00
27 lines
1234 bytes
rtripp2@communique.net (Roy Tripp III) writes:


> 	Is there a simple way to reject articles that are heavely
> 	crossposted ?
> 
> 	ie, if an articles is crossposted to more than 4 groups, I
> 	would like to reject it, (or maybe post it to the first 4 groups

if you build INN 1.5 with the TCL module:

proc filter_news {} {
  global Headers
  set newsgroups [split $Headers(Newsgroups) ,]
  if {[llength $newsgroups] > 4} {
      return "Excessively Crossposted"
  }
  return "accept"
}

I don't know if the TCL modules allows headers to be edited
before the article is processed.  I suspect not.

Darrell Fuhriman

Re: limiting crosposted articles ?
#13391
Author: Andy Burgess
Date: Wed, 18 Dec 1996 00:00
11 lines
852 bytes
In <qzrakqf0vz.fsf@structured.net> darrell@structured.net writes:

>I don't know if the TCL modules allows headers to be edited
>before the article is processed.  I suspect not.

Sounds like a feature. I think this could be done for the perl filter.
Anybody think its a bad idea?


Re: limiting crosposted articles ?
#13426
Author: James Brister
Date: Thu, 19 Dec 1996 00:00
19 lines
1068 bytes
aab@cichlid.com (Andy Burgess) writes:

> In <qzrakqf0vz.fsf@structured.net> darrell@structured.net writes:
> 
> >I don't know if the TCL modules allows headers to be edited
> >before the article is processed.  I suspect not.
> 
> Sounds like a feature. I think this could be done for the perl filter.
> Anybody think its a bad idea?

I do.

James
-- 
James Brister                                            brister@vix.com
Internet Software Consortium    http://www.isc.org/isc   inn@isc.org 

Re: limiting crosposted articles ?
#13438
Author: Andy Burgess
Date: Fri, 20 Dec 1996 00:00
52 lines
2354 bytes
In <yy3raklsdhu.fsf@velo.pp.vix.com> James Brister <brister@vix.com> writes:

<regarding changing article headers in the perl & tcl filters>

Thanks for responding James.

>So, firstly the perl
>and tcl hooks are there to let you help innd decide whether you want to
>accept and article or not. They're not intended for modifying article
>contents

Yes that's true. This would be added functionality.

>-- all such modifications (and they are kept to a minimum) should
>be kept inside innd itself if only because calling into perl or tcl is not
>a lightweight operation.

It seems to me that if you are using the perl filter already any added
functionality is free of overhead. You are already running the perl
script. 

>Secondly, a slightly broken perl/tcl script that was modifying articles
>would have disaterous consequences.

Bugs anywhere can have consequences, in the perl filter or in
innd or ...

>Thirdly, you can already modify
>articles via an entry in newsfeeds,

Yes. You could have two seperate perl scripts.

>so write access to the article from
>perl/tcl isn't necessary.

It seems that for some cases it would be more efficient. It would be
nice to avoid copying the article body but if the perl script could
get a pointer to it then r/w access is pretty much overhead free.

>> But how about some sort of r/o pointer to the complete message-header and
>> -body? Would be a nice thing for logging and auto-replying purposes etc.

>These will be coming later.

Enforcing r/o would be more overhead would it not?

I'm looking forward to yours and others additional input on this
topic.


Re: limiting crosposted articles ?
#13446
Author: James Brister
Date: Fri, 20 Dec 1996 00:00
31 lines
1816 bytes
sven@oops.sub.de (Sven Paulus) writes:

> In news.software.nntp James Brister <brister@vix.com> wrote:
> >> Sounds like a feature. I think this could be done for the perl filter.
> >> Anybody think its a bad idea?
>  JB> I do.

Andrew Burgess took me to task for being so curt... So, firstly the perl
and tcl hooks are there to let you help innd decide whether you want to
accept and article or not. They're not intended for modifying article
contents -- all such modifications (and they are kept to a minimum) should
be kept inside innd itself if only because calling into perl or tcl is not
a lightweight operation.

Secondly, a slightly broken perl/tcl script that was modifying articles
would have disaterous consequences. Thirdly, you can already modify
articles via an entry in newsfeeds, so write access to the article from
perl/tcl isn't necessary.

> But how about some sort of r/o pointer to the complete message-header and
> -body? Would be a nice thing for logging and auto-replying purposes etc.

These will be coming later.

James
-- 
James Brister                                            brister@vix.com
Internet Software Consortium    http://www.isc.org/isc   inn@isc.org 

Re: limiting crosposted articles ?
#13453
Author: Sven Paulus
Date: Fri, 20 Dec 1996 00:00
17 lines
1291 bytes
In news.software.nntp James Brister <brister@vix.com> wrote:
>> Sounds like a feature. I think this could be done for the perl filter.
>> Anybody think its a bad idea?
 JB> I do.

But how about some sort of r/o pointer to the complete message-header and
-body? Would be a nice thing for logging and auto-replying purposes etc.

Sven
-- 
--Sven-Paulus----------28-48-32--3-----ub6v@rz.uni-karlsruhe.de------
--Karlstr.-55----------30--2-50-29-----sven@oops.sub.de--------------
--D-76133-Karlsruhe----44-49-10--8-----T#-49-721-9375094-------irc---
--Fido-2:2476/557.20----9-12-19-71-----F#-49-721-9375095-----svennie-

Re: limiting crosposted articles ?
#13483
Author: James Brister
Date: Sat, 21 Dec 1996 00:00
47 lines
2444 bytes
aab@cichlid.com (Andy Burgess) writes:

<regarding changing article headers in the perl & tcl filters>

> >-- all such modifications (and they are kept to a minimum) should
> >be kept inside innd itself if only because calling into perl or tcl is not
> >a lightweight operation.
> 
> It seems to me that if you are using the perl filter already any added
> functionality is free of overhead. You are already running the perl
> script. 

Not so free. There would be the Perl overhead and then there is the extra
buffer management overhead that innd would have to do to copy the buffers
back out. It would either have to check every header to see if it
changed, or just copy everything back out always on all articles. Not an
insignificant amount of work.

> >Secondly, a slightly broken perl/tcl script that was modifying articles
> >would have disaterous consequences.
> 
> Bugs anywhere can have consequences, in the perl filter or in
> innd or ...

True. But broken scripts now just mean you're rejecting good
articles. Broken scripts that modify articles mean you propogate broken
articles.

I haven't seen anyone explain why they want to modify articles they didn't
generate locally.

> It seems that for some cases it would be more efficient. It would be
> nice to avoid copying the article body but if the perl script could
> get a pointer to it then r/w access is pretty much overhead free.

The perl interface isn't so simple. It looks like Everything that gets
passed in gets copied. I don't think I'm going to be able to supply r/o
access to anything. I will eventually get all headers in there, and
optionally the body, but that's going to be a memory hit.

James
-- 
James Brister                                            brister@vix.com
Internet Software Consortium    http://www.isc.org/isc   inn@isc.org 

Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads