Article View: news.software.nntp
Article #26818Re: NNTP followup/response method
From: Curt Welch
Date: Thu, 12 Mar 1998 00:00
Date: Thu, 12 Mar 1998 00:00
83 lines
4533 bytes
4533 bytes
mibsoft@mibsoftware.com (Forrest J. Cavalier III) wrote:
> In article <6e6r65$d13@darkmere.gen.nz>, simon@darkmere.gen.nz wrote...
> >Forrest J. Cavalier III <mibsoft@mibsoftware.com> wrote:
> >> References: (Append one, deleting the first one(s) to
> >> limit the line length to 512 bytes)
> >
Here's some of what son-of-1036 has to say about this:
"Followup agents SHOULD not shorten References headers. If
it is absolutely necessary to shorten the header, as a des-
perate last resort, a followup agent MAY do this by deleting
some of the message IDs. However, it MUST not delete the
first message ID, the last three message IDs (including that
of the immediate precursor), or any message ID mentioned in
the body of the followup."
> >Hmm there might be a little bit of debate on this, the only reason you
> >should ever delete existing ones is some stupid bug in INN.. Does anyone
> >know if this has been fixed recently?
It's not a stupid bug. It's a feature! Son-of-1036 says that news
transports should not limit lines to any length, but:
"If it is absolutely necessary for an implementation to
impose a limit on the length of header lines, body lines, or
header logical lines, that limit shall be at least 1000
octets, including EOL representations."
Which means that some transports may not be able to handle lines which
are over 1000 octets. So, to make sure that the article will be able
to get to every point in the Usenet network, you should limit your lines
to 1000 octets or less. Inn therefore forces new posts to follow this.
However, in my testing, I found that INN 1.5.1 actually limited the line
to 999 bytes, not 1000 like it should.
> ....Not that I am aware.....
>
> To be able to discuss this in more detail, I just dug through the INN
> code again....
>
> The limit on any line in a post is actually 1000 characters, (I
> remembered it incorrectly as 512.) The limit is set by
> ART_LINE_LENGTH in nnrpd.h, and the code in
> nnrpd/commands.c::CMDpost().
Thanks for the pointer. I looked at the code, and sure enough, in inn
1.5.1 it's wrong.
The problem is in READline(). If the line, including the CR LF, is 1000
bytes or more, READline() will return a too-long indication. To match the
wording of the RFC it should only return that error if the line is OVER
1000 bytes. I don't know if this has been changed in later verions of INN.
It's clearly a bug in the way READline() is written because it's passed
a buffer which can hold over 1000 characters and an argument which tells
it to limit the line length to 1000 characters, but yet it returns an
error when it gets a line which is 1000 characters long.
Forrest, you're an inn expert. Has READline() changed in later versions
of inn?
> (There is a limit of 512 characters for NNTP commands specified in
> RFC977, which could be what I was remembering....)
>
> I don't think there is a limit in RFC1036, (which is what actually
> applies to the case in point: articles.)
Yes there is - or at least it is in son-of-1036 which is more important
these days than RFC 1036.
> I haven't tested this recently behavior recently, so there may be
> something I've missed, but I have seen reports of INN rejecting posts
> because of Reference lines which were too long.
inn 1.5.1 certainly rejects new posts which have long lines.
--
Curt Welch http://CurtWelch.Com/
curt@kcwc.com Webmaster for http://NewsReader.Com/
Technical Details
Message-ID:
<19980312133756.167$GQ@newsreader.com>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!not-for-mailReferences:
<6e6cnl$es$1@cc.tut.fi> <6e6in9$57q$1@nntp.epix.net> <6e6r65$d13@darkmere.gen.nz> <6e74ml$e5r$1@nntp.epix.net>Show Full Headers
Complete Article Headers
Message-ID: <19980312133756.167$GQ@newsreader.com>
Subject: Re: NNTP followup/response method
Date: Thu, 12 Mar 1998 00:00:00 +0000
From: curt@kcwc.com (Curt Welch)
References: <6e6cnl$es$1@cc.tut.fi> <6e6in9$57q$1@nntp.epix.net> <6e6r65$d13@darkmere.gen.nz> <6e74ml$e5r$1@nntp.epix.net>
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!not-for-mail
X-Deja-AN: 333411999
X-User: Curt@NewsReader.Com
X-Face: "p}G*1KH{+F7EYGKLb>ogDguabZ+%,?^epeFB!nzu`)`$=QcvL1KF6<0GH!Tbc!Sqo[|tV5 %IW48mQf3K=Ci&gZ7]]aazx@]Y-nq!r5{yH/#,?@lDdUDvOfByB2hVW0.@OM%{l/{cT'{w
Organization: KCW Consulting
X-Url: http://CurtWelch.Com/
Newsgroups: news.software.nntp