🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.nntp
Article #79864

Re: Bug in INN support script mod-active

#79864
From: D. Stussy
Date: Thu, 11 Dec 2008 20:16
34 lines
2393 bytes
I don't know if this is a defect or intentional:  It is possible to
add groups via the mod-active script that have invalid characters in
their names.

I can see the merit of accepting invalid group names by the script
itself - for the rmgroup (and perhaps the changegroups) operation(s).
However, should this be allowed for the newgroup operation?  I have
noted bogus group names that contain "&", ";", and "@" showing up in
my $pathlog"/unwanted.log" file, so apparently people are also using
such bad groups.

About line 69-70:

for (sort keys %toadd) {
  $add = "$_ 0000000000 0000000001 $toadd{$_}\n";

Insert this somewhere near there (inside the loop):

  next if $_ != ~/[a-z0-9._+-]*/;  (or ending "*/i;" to add A-Z)

I think that's what we want; I'm not perl proficient.  I don't know if
we should allow capital letters too (since some groups do use them).
Of course, this doesn't check for other invalid issues (e.g. all
numeric component).

Maybe mod-active is only meant to take actsync output (and actsync
already filters for bad names) or checkgroups output (does checkgroups
filter for this?).

If the script is left "as is," then let's warn people in the manual
page that no syntax checking is performed on group names by the
script.

Technical Details
Message-ID: <ghrsfb$atf$1@snarked.org>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.20141118.mbox.gz!border1.nntp.dca.giganews.com!nntp.giganews.com!news-in-01.newsfeed.easynews.com!news-in-02.newsfeed.easynews.com!easynews.com!easynews!news.he.net!news.snarked.org!not-for-mail
References: <gh2r9u$g3$1@snarked.org>

Show Full Headers
Complete Article Headers
Message-ID: <ghrsfb$atf$1@snarked.org>
Subject: Re: Bug in INN support script mod-active
Date: Thu, 11 Dec 2008 12:16:38 -0800
From: "D. Stussy" <spam@bde-arc.ampr.org>
References: <gh2r9u$g3$1@snarked.org>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.20141118.mbox.gz!border1.nntp.dca.giganews.com!nntp.giganews.com!news-in-01.newsfeed.easynews.com!news-in-02.newsfeed.easynews.com!easynews.com!easynews!news.he.net!news.snarked.org!not-for-mail
Newsgroups: news.software.nntp
Lines: 34
Reply-To: "D. Stussy" <replies@newsgroups.kd6lvw.ampr.org>
NNTP-Posting-Host: pool-71-106-211-175.lsanca.dsl-w.verizon.net
X-Trace: snarked.org 1229026604 11183 71.106.211.175 (11 Dec 2008 20:16:44 GMT)
X-Complaints-To: newsmaster@snarked.org
NNTP-Posting-Date: Thu, 11 Dec 2008 20:16:44 +0000 (UTC)
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1478
X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2800.1478