Article View: news.software.nntp
Article #73169Re: Identify text messages and binaries
From: DanS
Date: Sat, 04 Feb 2006 15:43
Date: Sat, 04 Feb 2006 15:43
51 lines
3259 bytes
3259 bytes
Philippe wrote in news:43df7917$0$21284$8fcfb975@news.wanadoo.fr: > Good afternoon, > > I have read RFC 977, 1036 and 2980 in order to understand the NNTP > protocol but i have a problem for identifying the kind of the message : > for example, when i select a group like alt.binaries.yyyyy, the > messages attached to this newsgroup can be text message or binaries. > Unfortunately, the header "content-type" is not mandatory and it's > difficult for me to understand how i can identify the message (text or > binary) ? > > Is there a way to perform this operation (Xover only returns the fields > described in overview.fmt) ? For example, get the n first bytes of the > body in order to analyze it ? Do you know where i can find > documentations ? > > Thank you, > > Regards, > > Philippe. > If an X-header is not present, there is really no way to tell other than by parsing the subject line. The question I have, is how do you get the first X amount of bytes of the body? The server's I've dealt with don't accept further commands until sending the body to you is done, as in there's no effective way of cancelling it other than disconnecting, which is a bad thing. This was/is an on-going issue with the ever-increasing binary feed, from way back as Usenet was never intended to send binary data, it is all text based. For multipart binaries, TYPICALLY, the subject line will end with (1/20), (2/20),(3/20), etc, indicating each part for the attached file. Some posting programs allow you to change this though, so that is not 100% true all of the time. Throw in typos and other small deviation's from the norm, and you've got quite a bit to handle. I spent 2 solid months of work, 2 - 3 hours a day, on this part of my binary d/l'r which was subsequently cancelled after the release of NewsLeecher. I was writing a (better) clone of ZeoNews. Regards, DanS
Technical Details
Message-ID:
<Xns97606D3AEE0B6idispcom@216.196.97.142>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!number1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!local01.nntp.dca.giganews.com!nntp.adelphia.com!news.adelphia.com.POSTED!not-for-mailReferences:
<43df7917$0$21284$8fcfb975@news.wanadoo.fr>Show Full Headers
Complete Article Headers
Message-ID: <Xns97606D3AEE0B6idispcom@216.196.97.142> Subject: Re: Identify text messages and binaries Date: Sat, 04 Feb 2006 09:43:41 -0600 From: DanS <t.h.i.s.n.t.h.a.t@a.d.e.l.p.h.i.a..n.e.t> References: <43df7917$0$21284$8fcfb975@news.wanadoo.fr> 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!number1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!local01.nntp.dca.giganews.com!nntp.adelphia.com!news.adelphia.com.POSTED!not-for-mail NNTP-Posting-Date: Sat, 04 Feb 2006 09:43:41 -0600 Newsgroups: news.software.nntp Organization: Home User-Agent: Xnews/5.04.25 Lines: 51 NNTP-Posting-Host: 24.51.47.12 X-Trace: sv3-wxfGtO+R1p7AK+2grbfQOeoSBHk7D8fOzfcTbdG8h6ioudCjAJWEbfQ42w1XY6OxtFMmlzQKDUQ3/T9!QQb8Xmd5hiIRZga5hcFTMiOQ+teoaD3lhmr0GiK4n47SfZlhhRaRBavjb2ROIEw83u1xAgivH3bm!CENPm7JQSgioZv0m6H9B X-Complaints-To: abuse@adelphia.net X-DMCA-Complaints-To: copyright@adelphia.net X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly X-Postfilter: 1.3.32