Article View: news.software.nntp
Article #61163Re: [FNTP] 'in-completeness'
From: Russ Allbery
Date: Tue, 08 Oct 2002 04:53
Date: Tue, 08 Oct 2002 04:53
286 lines
16177 bytes
16177 bytes
Curt Welch <curt@kcwc.com> writes:
> Each of those translations is an "encoding" no different than uuencode
> or yEnc or multipart files in it's complexity (many like the form it's
> actually writen to a disk service is far more complex). The only
> difference is that it's a well defined and correctly engineered so it
> works.
Well, some of the cases that you're talking about are either dead-simple
(NNTP wire formatting), or the writer and the reader are the same person
(like your disk drive). You don't have to standardize the encoding on the
disk drive; all that you have to do is make sure the disk drive can read
its own encoding. (And there have been arguments about NNTP wire
formatting before, so it's not as clearly reversible as it looks.)
Encoding for transport is a bit different.
What I'm talking about is that when transporting files from one place to
another, the best way to do that is to transport them as the binary
streams that the other side wants to recover. Anything else adds
complexity, and the more complexity you add, the larger chance there is
that something will break. Every change you made has to be carefully
analyzed to be sure that it's reversible, which is work you don't have to
do if you minimize the number of changes you have to make.
> You are talking about turning that into 5 and that removes "all the
> encoding?". I don't think so. YOu just need to make the top level
> (yEnc + multipart) as sold of an endoding standard as all the levels
> below it.
Headers are not the same thing as encoding, either at the packet level or
at the message level. Putting something in an envelope isn't the same as
changing the materials it's made out of.
>> There's no such thing as a 5 part post that contains 12 uuencoded
>> pictures. :)
> There are. I've seen them. My newsreader decodes them correctly. I'll
> be happey to send you the Message-Ids of the set next time I spot one.
Okay, fair enough. I don't know enough about the strange stuff that
people do on Usenet.
> The "correct" algorithm for decoding a multipart uuencoded article is
> very simple. All you do is concatenate the body lines (being sure to
> not include the blank line between the header and the body), of all the
> articles into one large body. Then decode it as if it were one large
> article. If it has 5 jpgs uuencoded, it just works.
You're missing the whole reason why this isn't even remotely simple,
namely figuring out which posts to grab and what order to put them in.
That's the thing that multipart uuencode doesn't have, and exactly the
reason why dealing with them in news software is such a pain.
> uuencode multipart posts from 10 years ago did it perfectly.
So that's why you're spending a bunch of your time on this newsgroup right
now trying to, in part, reinvent message/partial? :) Or something very
much like message/partial, although perhaps a bit better. I haven't
analyzed them both very closely to compare.
> The hard part is that you have to cleanly define the mapping from one
> "encoding" to the next to make it a "solid" encoding system. We have no
> clean standards currently at this level, so it's impossible to convert
> without loosing important information.
Yes, actually, we do. Really, honestly, you should spend a bunch of time
reading the MIME standards, if you haven't already.
Seriously, people use this stuff every day. People send AppleDouble
messages. People send all sorts of multipart messages. People even send
entire web sites complete with PNGs. There's a formal structure that
explains exactly how to put them together and take them back apart again,
and they're even recoded in transit by mail servers and still work
properly.
MIME has got to be one of the most reinvented wheels in the history of
Internet standards, and the reason why that happens is precisely because
people take one look at MIME, don't really understand it, see that it's
really large and really complicated, notice that a lot of people have
written half-hearted implementations of it, and go off to do their own
thing instead. Because they have some other special requirement, and they
think it's easier to solve their little problem.
Then they find more edge cases, and then they discover they want to do a
few other things, and slowly their little simple system turns into
something as complicated as MIME, but with things tacked on at weird
angles and without the level of peer review and existing implementation
that MIME has.
If half that energy had been spent fixing the bugs in the existing MIME
implementations, more net forward progress would have been made, but
really understanding MIME and fixing bugs in implementations of it isn't
as much fun as building something new from the ground up.
Heaven knows I've wasted my time reinventing that particular wheel before,
and even more time arguing against the wheel that already exists. And
it's certainly true that MIME is large and complicated and hard to fully
implement properly. That's because the *problem* is large and complicated
and hard to implement properly. The complexity is mostly real complexity,
not complexity forced by an accident of implementation.
> No, there is no mime standard for doing what you can do with uuencoded
> data inserted into a text file (other than leaving it as a large
> text/plain segment which of course is not what you are after).
Well, yes, there is. It may not be currently followed by all MIME
clients, but there is, in fact, a standard.
> _every_ usenet newsreader that can decode pictures in-line will produce
> bascially the same end-user representation of a text article with
> multiple uuencoded pictures inserted a various places in-line. It's
> simply one large text article with pictures between the words.
Most Usenet newsreaders that I'm aware of can't decode pictures in-line.
:) So I can't really argue with this; it's outside of my experience.
Gnus, unsurprisingly, treats such an article exactly the same as the
corresponding MIME article.
> In mime, it's simple to encode the same data, you can do a
> multipart-mixed and put in alternating text/plan and image/jpeg
> segmetents.
> But very few mime "viewers" will display that the same way as _all_ the
> newsreaders displayed the article. Instead of making this one large
> page, they will do things like show the first text segment as the
> article, then show the the rest as "attachements".
And if they do this despite a Content-Disposition: inline header in the
MIME parts, they're wrong. There are a decent number of MIME
implementations that do get that wrong, and others that get that right.
One can put effort into fixing the ones that are wrong; my impression is
that a lot of binary readers already use specialized software, so it's not
like you have to fight the Outlook Express juggernaut to fix this.
> The encoding of the uuencoded text has a semantic understanding that it
> is "one page". MIME has no such thing for text segemnts.
Yes, see, it does. It's not widely implemented correctly, but if you read
RFC 2183, exactly how to do this is clearly specified.
2.1 The Inline Disposition Type
A bodypart should be marked `inline' if it is intended to be
displayed automatically upon display of the message. Inline
bodyparts should be presented in the order in which they occur,
subject to the normal semantics of multipart messages.
> What I'm saying is that it's NOT A STANDARD. The mapping from one type
> of multipart binary encoding to another is just not well defined.
And I'm disagreeing. :) I believe that it is, in fact, well-defined, and
much better defined than it is for legacy encodings like yEnc and
uuencode. It may not be *implemented* properly, but if you invent a new
standard, that isn't going to be implemented properly to start with
either.
> What Usenet could really use is a standard for what a "binary post"
> logicaly is. Then we can create various encoidngs to represent that
> standard and various ways to convert from one encoding to another
> without loosing any of the "real content" of the message.
I have a very hard time imagining how this would not end up looking quite
a lot like the existing MIME standard.
> Well, not in my mind because I'm trying to do something a little
> different than you I think.
> I'm on a mission to try and find a way to make large multipart binary
> files work much better on Usenet. So I'm looking at ideas of how we can
> make the usenet servers know they are transporting files, and not just
> articles.
Right, I understand. I think you're not going deep enough into the
fundamental brokeness of what's currently being done, but that in and of
itself is a laudible goal, and I won't argue with whatever results you get
out of it.
> But, for the text articles which doesn't fall under this idea of a
> "large file binary transport system", I don't care if they still contain
> pictures and sound files etc.
> You on the other hand want to see all binaries forced into a new system
> so you can easily filter and control their distribution.
Well, what this came out of was my observation that I think multipart
posts are inherently broken to the degree of being abusive in that they
inflict themselves on sites that don't want them and wouldn't deal with
them if they had some way of avoiding doing so.
So insofar as you're interested in eliminating or controlling multipart
posts so that sites can still make effective article size decisions, we're
pursuing similar goals, although you want them to propagate more smoothly
and I want to be able to opt out of responsibility for propagating them.
> Could be. But that's not what I'm seeing. I'm seeing a system that
> bascially allows people to point to a file on their disk and say "send
> that on Usenet and here's the From: and Subject: and Newsgroups: to put
> with it".
I think this is pretty limited, frankly. I think you'll run into the
limits very quickly. What you end up with is basically a p2p file sharing
system with central caches that happens to use NNTP as a transport
protocol, which I don't think is very interesting or very useful.
But I could be wrong.
What's *interesting*, I think, is supporting the full spectrum of
structured messages that MIME makes possible within the structure and
facilities of Usenet. Which includes large attachments.
But I agree that the current binary Usenet looks a lot more like a p2p
file sharing system, so maybe that's a good model to look at if what you
care about is making that existing system work better. I think this is,
in the long run, as much of a doomed effort as Napster was for many of the
same reasons, and think that designing technology that's just going to be
used almost exclusively for illegal activity and outside of that doesn't
really do anything all that *interesting* is kind of a waste of time.
But that's just a statement about what scratches my itches, and you're
certainly entitled to scratch your own.
> I don't know enough about MIME and message/partial to know for sure what
> you are getting into if you try that, but generally, I see MIME as a
> very large and complex beast which belongs at a level above what I'm
> looking at.
> Would you use MIME message-partial to split up a file into disk blocks
> on disk drive? That would be absurd. That's the level I'm thinking at
> here when I talk about splitting up files and transporting them in some
> formal, but very simple way, over usenet.
No, you're not talking about saving them on disk. You're talking about
transporting them over a network protocol.
This is *precisely* what message/partial was designed to do, to take a
message and split it apart into parts for transport over a network
protocol so that it can be reassembled by an application on the other
end. It is intended to include all the information required to identify
the parts and assemble them in the right order and make sure that the
resulting assembled article is valid and was decoded correctly.
The transport that it was designed for was SMTP rather than NNTP, so it's
hostile towards 8-bit, but other than that it looks a heck of a lot like
the wheel you're inventing.
> Another way to attack this multipart problems is to look for a formal
> way to define splitting up usenet articles (instead of files) and then
> transporting them over Usent. So you can post soemthing as a huge 10GB
> MIME single part article, and then under the covers, the usenet servers
> have some formal way for splitting that up into many smaller parts to
> make it easy to move around and store.
Right. This is exactly the sort of thing that message/partial is for,
although message/partial involves a degree of robustness that may not be
entirely necessary if you're only doing the disassembly and reassembly at
the transit layer rather than also storing the articles that way.
> But that approach mostly kills the conept of allowing multiple people to
> post parts of the same file. When you split and transport "files"
> instead of "articles" you end up with something that can be shared.
I don't see why this is useful.
> BTW, a file in my mind is fixed and ordered sequence of 8 bit bytes from
> 0 to N bytes long - and which there is _NO_ associated metadata supplied
> by the user (like file name, or content type, or creation date, etc).
> They can of course supply stuff like that in the headers, but it's
> outside the scope of what the usenet "system" is transporting.
I think this is a serious mistake. Files without metadata are
substantially less useful. This is a problem that's been rediscovered
independently by multiple different protocols, including SMTP, HTTP, and
the current news article format. You need the metadata to make reasonable
decisions about what to do with the resulting file.
> The "hash" we use to identify file the file is not "assocaited metadata",
> supplied by the user, but instead something that is defined by the data.
Like Content-MD5.
--
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:
<yln0pp350z.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!news1.google.com!newsfeed.stanford.edu!shelby.stanford.edu!not-for-mailReferences:
<58068.n92202@archiver.winews.net> <20020924011222.716$tx@newsreader.com> <ylofabv431.fsf@windlord.stanford.edu> <4319b.4a2200@archiver.winews.net> <ylzntuxir5.fsf@windlord.stanford.edu> <041020021438385411%planb@newsreaders.com> <yl7kgyrpwd.fsf@windlord.stanford.edu> <041020021954536744%planb@newsreaders.com> <ylwuoxhhhx.fsf@windlord.stanford.edu> <20021005022430.397$TR@newsreader.com> <yld6qpv0rd.fsf@windlord.stanford.edu> <20021005043816.517$kr@newsreader.com> <yld6qosu9b.fsf@windlord.stanford.edu> <20021005183917.837$Qo@newsreader.com> <ylfzvkcwue.fsf@windlord.stanford.edu> <20021005233454.131$iS@newsreader.com> <ylu1jxaoda.fsf@windlord.stanford.edu> <20021007233918.512$5h@newsreader.com>Show Full Headers
Complete Article Headers
Message-ID: <yln0pp350z.fsf@windlord.stanford.edu> Subject: Re: [FNTP] 'in-completeness' Date: Mon, 07 Oct 2002 21:53:32 -0700 From: Russ Allbery <rra@stanford.edu> References: <58068.n92202@archiver.winews.net> <20020924011222.716$tx@newsreader.com> <ylofabv431.fsf@windlord.stanford.edu> <4319b.4a2200@archiver.winews.net> <ylzntuxir5.fsf@windlord.stanford.edu> <041020021438385411%planb@newsreaders.com> <yl7kgyrpwd.fsf@windlord.stanford.edu> <041020021954536744%planb@newsreaders.com> <ylwuoxhhhx.fsf@windlord.stanford.edu> <20021005022430.397$TR@newsreader.com> <yld6qpv0rd.fsf@windlord.stanford.edu> <20021005043816.517$kr@newsreader.com> <yld6qosu9b.fsf@windlord.stanford.edu> <20021005183917.837$Qo@newsreader.com> <ylfzvkcwue.fsf@windlord.stanford.edu> <20021005233454.131$iS@newsreader.com> <ylu1jxaoda.fsf@windlord.stanford.edu> <20021007233918.512$5h@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!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!shelby.stanford.edu!not-for-mail Newsgroups: news.software.nntp Organization: The Eyrie Lines: 285 NNTP-Posting-Host: windlord.stanford.edu Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: news.Stanford.EDU 1034052813 21439 171.64.13.23 (8 Oct 2002 04:53:33 GMT) X-Complaints-To: news@news.stanford.edu User-Agent: Gnus/5.090008 (Oort Gnus v0.08) XEmacs/21.4 (Honest Recruiter, sparc-sun-solaris2.6) Cancel-Lock: sha1:y71Yu2oKT7HiF60FU3fLB/dtNus=