Article View: news.software.nntp
Article #59508Re: News servers, nntpcache, slrn and the Usenet bug "From ".
From: itsy bitsy meowbot
Date: Sun, 07 Jul 2002 00:01
Date: Sun, 07 Jul 2002 00:01
39 lines
3317 bytes
3317 bytes
Kjetil Torgrim Homme wrote: > [itsy bitsy meowbot]: >> It's usually LF-only, given the Unix origins. The always-CRLF >> business comes from NNTP. >> The byte count in an rnews header should count a line ending as >> one character, regardless of how it is physically represented. > noooo! that's really broken :-( In fairness, the UU in UUCP does imply a specific line ending convention where that assumption makes perfect sense. The brokenness crept in with ports to other platforms that ignored this reality. Too bad no one thought at the outset to put that detail in writing :/ > ugh. so the algorithm is: read the N bytes specified, count the > number of CR LF's found (make sure you cover the case where the chunk > read ends with CR), then read that many extra bytes, and repeat. > ugly, ugly, ugly. In a way it's really no more ugly than what you end up having to do when deciphering NNTP/SMTP streams, looking for those silly dots and figuring out what they mean in context, and dealing with the occasional newsreader that uses the wrong flavor of line ending. I do tend to read stuff like that in chunks, make all the line endings consistent, and then worry about counting. Tossing in a bit of fudge and looking for an EOF or #! blah marker in the general vicinity of where you expect the end to be can help too. There is also the dumb-as-rocks approach used for a long time by INN, that seemed to work well enough in practice. It simply assumed that the whole world used Unix line endings, and too bad if you didn't.
Technical Details
Message-ID:
<3D2784F0.60509@meowing.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!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!news-out.nuthinbutnews.com!propagator-sterling!news-in.nuthinbutnews.com!cyclone1.gnilink.net!spamfinder.gnilink.net!nwrddc02.gnilink.net.POSTED!53ab2750!not-for-mailReferences:
<slrnaiaghh.333.nenosed@arthur.valhalla.net.oz> <87eleisdsw.fsf@erlenstar.demon.co.uk> <slrnaib0fg.3b6.nenosed@arthur.valhalla.net.oz> <DNhV8.6017$xf3.1063173@news11-gui.server.ntli.net> <ylbs9mnq1p.fsf@windlord.stanford.edu> <slrnaicuao.4d2.nenosed@arthur.valhalla.net.oz> <1fewk95.1evu0x518r39cqN%planB@newsreaders.com> <1rpty0vcq1.fsf@sex.ifi.uio.no> <3D27665A.4080106@meowing.net> <1rhejcv3gy.fsf@sex.ifi.uio.no>Show Full Headers
Complete Article Headers
Message-ID: <3D2784F0.60509@meowing.net> Subject: Re: News servers, nntpcache, slrn and the Usenet bug "From ". Date: Sun, 07 Jul 2002 00:01:40 GMT From: itsy bitsy meowbot <53ab2750@meowing.net> References: <slrnaiaghh.333.nenosed@arthur.valhalla.net.oz> <87eleisdsw.fsf@erlenstar.demon.co.uk> <slrnaib0fg.3b6.nenosed@arthur.valhalla.net.oz> <DNhV8.6017$xf3.1063173@news11-gui.server.ntli.net> <ylbs9mnq1p.fsf@windlord.stanford.edu> <slrnaicuao.4d2.nenosed@arthur.valhalla.net.oz> <1fewk95.1evu0x518r39cqN%planB@newsreaders.com> <1rpty0vcq1.fsf@sex.ifi.uio.no> <3D27665A.4080106@meowing.net> <1rhejcv3gy.fsf@sex.ifi.uio.no> 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!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!news-out.nuthinbutnews.com!propagator-sterling!news-in.nuthinbutnews.com!cyclone1.gnilink.net!spamfinder.gnilink.net!nwrddc02.gnilink.net.POSTED!53ab2750!not-for-mail Organization: a tyranny of meowing fascist censor cabalists User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.1a) Gecko/20020611 X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: news.software.nntp,news.software.readers Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Lines: 38 NNTP-Posting-Host: 141.154.209.21 X-Complaints-To: abuse@verizon.net X-Trace: nwrddc02.gnilink.net 1026000100 141.154.209.21 (Sat, 06 Jul 2002 20:01:40 EDT) NNTP-Posting-Date: Sat, 06 Jul 2002 20:01:40 EDT