Article View: news.software.nntp
Article #53519Re: Transit INN 2.3.2 dying on a control messages(?)
From: Russ Allbery
Date: Sat, 28 Jul 2001 09:37
Date: Sat, 28 Jul 2001 09:37
77 lines
3345 bytes
3345 bytes
Matti Saarinen <mjs@cc.tut.fi> writes:
> I am runnig controlchan and have noticed similar messages. Here
> is an example of one article the processing of which has resulted
> in the syslog message above:
[...]
> The problem appears to be in these lines of the controlchan
> script:
> -----line 181
> $progname = lc($hdrval{Control});
> }
> next CHANITEM if ($progname =~ /^(cancel)$/);
> if ($progname !~ /(^[a-z]+$)/) {
> logmsg ('notice', 'Naughty control in article %s', $msgid);
> } else {
> $progname = $1;
> }
> -----line 190
Thanks. Fixed in STABLE thusly:
Index: controlchan.in
===================================================================
RCS file: /dist1/cvs/isc/inn/inn/backends/Attic/controlchan.in,v
retrieving revision 1.3.2.1
diff -u -r1.3.2.1 controlchan.in
--- controlchan.in 2000/09/19 06:31:40 1.3.2.1
+++ controlchan.in 2001/07/28 09:29:38
@@ -185,6 +185,7 @@
if ($progname !~ /(^[a-z]+$)/) {
logmsg ('notice', 'Naughty control in article %s', $msgid);
+ next;
} else {
$progname = $1;
}
Index: art.c
===================================================================
RCS file: /dist1/cvs/isc/inn/inn/innd/art.c,v
retrieving revision 1.131.2.14
diff -u -r1.131.2.14 art.c
--- art.c 2001/02/06 15:07:07 1.131.2.14
+++ art.c 2001/07/28 09:35:35
@@ -24,6 +24,10 @@
#define EXECUTE_BITS 0111
#endif /* defined(S_IXUSR) */
+#if !defined(S_ISDIR)
+#define S_ISDIR(mode) (((mode) & 0xF000) == 0x4000)
+#endif
+
/*
** For speed we build a binary tree of the headers, sorted by their
@@ -1137,7 +1141,8 @@
FileGlue(buff, innconf->pathcontrol, '/', _PATH_BADCONTROLPROG);
else {
FileGlue(buff, innconf->pathcontrol, '/', Control);
- if (stat(buff, &Sb) < 0 || (Sb.st_mode & EXECUTE_BITS) == 0)
+ if (stat(buff, &Sb) < 0 || (Sb.st_mode & EXECUTE_BITS) == 0
+ || S_ISDIR(Sb.st_mode))
FileGlue(buff, innconf->pathcontrol, '/', _PATH_BADCONTROLPROG);
}
--
Russ Allbery (rra@stanford.edu) <http://www.eyrie.org/~eagle/>
Please post questions rather than mailing me directly.
<http://www.eyrie.org/~eagle/faqs/questions.html> explains why.
Technical Details
Message-ID:
<yln15pv1h6.fsf@windlord.stanford.edu>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!nntp.stanford.edu!not-for-mailReferences:
<3B60A04F.B306F290@clinet.fi> <yl66cf2qvo.fsf@windlord.stanford.edu> <qzu3d7in4yn.fsf@lagavulin.cc.tut.fi>Show Full Headers
Complete Article Headers
Message-ID: <yln15pv1h6.fsf@windlord.stanford.edu> Subject: Re: Transit INN 2.3.2 dying on a control messages(?) Date: Sat, 28 Jul 2001 09:37:09 +0000 From: Russ Allbery <rra@stanford.edu> References: <3B60A04F.B306F290@clinet.fi> <yl66cf2qvo.fsf@windlord.stanford.edu> <qzu3d7in4yn.fsf@lagavulin.cc.tut.fi> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!nntp.stanford.edu!not-for-mail Newsgroups: news.software.nntp Organization: The Eyrie Lines: 76 NNTP-Posting-Host: windlord.stanford.edu Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: news.Stanford.EDU 996313029 25541 171.64.13.23 (28 Jul 2001 09:37:09 GMT) X-Complaints-To: news@news.stanford.edu User-Agent: Gnus/5.0807 (Gnus v5.8.7) XEmacs/21.1 (Channel Islands)