🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.nntp
Article #42539

Re: Header-Only feeds

#42539
From: Frank Durda IV
Date: Tue, 28 Dec 1999 00:00
257 lines
15827 bytes
[17]Frank Durda IV <uhclem.jan00@nemesis.lonestar.org> wrote:
[17]Require a post to be available from the first N (say three)
[17]"participating" servers in the Path: header.  Also, instead of going to
[17]the originating server, go to the closest server (left-most offering host
[17]by Path:) first, which hopefully will disperse the volume of requests for
[17]the same article over several different servers.  The more feeds the
[17]first three sites deliver the complete article to, the more dispersed the
[17]query volume will be for that article.

[18]Curt Welch (curt@kcwc.com) wrote:
[18]Yeah that's a neat technique.  You're not going to patent it are you? :).

Although I have a few patents from years ago, software patents are stupid,
and if I had spare time, I would blow time invalidating various stupid patents.
I found prior art for TIs POST diagnostics patent and a former employer used
that not to invalidate the patent, but to negotiate some other deal, leaving
TI free to sue others with their invalid patent.  I also know a few of MSes
patents can be destroyed with a little time and determination because there
aren't enough survivable claims.  However, this is a sport for the rich and
those with vast quantities of time.

In real life, only the rich/powerful/monopolistic can afford to file and/or
try to invalidate patents, and these fat cats are the same ones who feel they
can ignore or engineer around any patent that gets in their way from a smaller
company or individual, making software patents a tool to block smaller
developers from being in the software business, as the big boys will prosecute
any violation by the small guy and the small guy won't be able to take on the
big guy when the big guy violates the small companies patents.  This is not
what patents were originally envisioned to do, but that's how they are used
these days.  This behavior makes patents useless apart from being a device to
shore-up the odd abusive software industry monopoly.  

Enough of that, now to the subject at hand.


[18]Another good feature of your algorithm is that it integrates nicely with
[18]the current feed network.  That is, we don't have to build a parallel set
[18]of servers which support the "new" system.  With most the other techniques
[18]we talked about I could only see it working if you set up a separate feed
[18]network on the side.

The entire point was to remain COMPLETELY within the current infrastructure,
even down to selecting trigger characters for the Path: that are already
legal for that header per existing RFC.  Further, NO new server commands are
required.  Sure you can add some, but there is no point.  In the setup I
suggest, there is never an article that has no body, so no special command
is needed to handle this situation.  It ALWAYS has the original body, or a
"mini body" that says something like: "body available at URL:....".  Even
if we didn't want to provide this functional toe-hold for people using servers
that don't know how to get the full bodies (the URL pointer), a blank line in
the body would still be sent to guarantee backward article handling
compatibility.

I recommend only a single added header line to the headers to make detection
of a mini-body to be determinable just by looking at the headers via HEAD and
similar handshakes.  It could also be an extension to an existing header, but
chances are that would break things, so a new header line is best.  This extra
header line would tell a server that that if a reader asks for the body via
BODY or ARTICLE commands, it needs to go get it from the addresses stipulated
in the Path: header.  The Nth hop, where the full body is replaced with the
mini-body would be responsible for adding this extra header line, say
	 "Body-Truncated-at: %s, %d bytes"
where the first %s is pointing to Hop N, the first place to go when the mini
body needs to be replaced with the full body.   The %d indicates the true size
of the full body, as this is needed info on the receiving end.


[18]If you were willing to convert your site to one which used the header-only
[18]system, all you have to do is upgrade your current transit server to one
[18]which knows about the new technology.  And I'm thinking you would probably
[18]set up a new server to act as a body server to the world as well (but the
[18]transit server could try to do that).

The transit server is the wrong place for getting full bodies, because most
transit servers have tiny spools (at least that is the case on the "big"
servers out there), and so a site would have an article on its main article
spool days or even weeks after it was no longer available on that sites
transit servers.  Since most sites add their main server name to the Path:
in addition to the transit server names (hey - you want a low Freenix
number, right?), so providing the correct location should not be an issue.


Of course, this scheme raises a concern that some people* likely have, which
is "If I participate in such a scheme, what's to prevent people from just
scanning headers looking for effectively "free read" servers and sucking all
articles off my server, no matter what?"   Good question.  This problem
has to be solved by having the donor server (one that offers full-bodies)
be obnoxious.  A donor server should only provide article bodies requested
when that article on that server has the "+" tag in the Path: on the local
copy of the article.  In other words, the donor server will offer ONLY the
articles for which it has agreed to be the donor, those from the first three
hops.  If that server is secretly holding other articles, it won't provide
them to strangers even if it has them.  That's to prevent someone from just
going to a known fast server in their area of the net with a big retention
time and just sucking down every article they can think of at the expense
of that donor server.

*   Those of us who run premimum servers have to protect our systems on this
    point or no one would bother to buy the premimum news service.  Whether
    this provides enough protection against freeloaders is a study left to
    ponder.

Along these lines, donor servers should only provide articles requested by
message-ID, not by group/article number, don't offer headers and none of the 
XHDR/XOVER/NEWNEWS/GROUP/LIST type commands work for strangers.  It might
even be prudent to limit the number of BODY/ARTICLE commands per connection
without authenticating, something that would match the behavior of a 
well-behaved remote server that was responding to random requests for articles
by contacting various different systems based on the Path: data, and so it
would not hold the connection to a given server open very long.

The Donor server could also limit how many days later a full body can be
requested to something less than the expiration time on that server.  This
protects the expense some sites have of terrabytes of storage for longer
retention time for theyr paying customers but still allows them to participate
in the donor server strategy.  Since a lot of the big posts are posted
via the premimum servers, their cooperation in this is essential if any sort
of scheme like this was ever to work.

NNRPD (or similar newsreader servers) have to be modified enough to accept
BODY <message-ID> (and perhaps ARTICLE <message-ID>) while in a 480 state
(not yet authenticated) and return the article only if it's own name appears
in the Path: of that article with a "+".  Example:

	Asking the infringement.net news server for BODY <xyzzy@foobar>
	would work if the Path: at infringement.net was:
    Path: +infringement.net!there.net!+nowhere.edu!+place.com!pirate-o-matic
    Path: +infringement.net!bar.com!+place.com!pirate-o-matic
    Path: +infringement.net!bell.com!frobozz
    Path: +infringement.net!not-for-mail
	or any Path: that starts with a "+", but not if the Path: at
	infringement.net was:
    Path: infringement.net!+there.net!+nowhere.edu!+place.com!pirate-o-matic
	or any other Path: that doesn't start with a "+".  That is the only
	test that has to be made.  

So someone can only suck an article from a given donor server if the article
in question arrived at that donor server in the first N participating hops
of the propagation.   

Donor server administrators might also limit donor connections to servers that
have a reverse DNS of two or three segments (eg, foobar.com or
news.foobar.com), eliminating most direct connections from modem pools and
other individual client PCs who have no reverse domain names or far longer
domain names, eg ppp145.clarksdale.foobar.com or cf.dd.a1.09.adsl.foobar.com.


[18]You could run the "body-server" as a separate process on
[18]the same box you use for transit as well of course.

There is no reason to have a separate server or even a separate daemon for
the donor server function.  The main server where the longer expiration
time would be the place that such a query should go anyway.

A less-ideal solution would be to define a global donor server port number
to separate that traffic from normal local NNTP/NNRP traffic.  However,
in my opinion, it would better to use the traditional port and make minor
changes to the NNRPD (or equivalent) daemon to know how to be a donor and
limiting access when in that mode.  If not by permissions, perhaps a new
command "DONOR" to put it in the mode.   You have to go in that code module
anyway to teach the daemon how to go to a donor server should someone ask
for the full body of an article when locally you only have the mini body
right now.

On the recipient server who has a request for an article from some news
reader and finds that all it has locally is a mini-body, what it must do to
obtain the full body is understood and discussed above and in the earlier
post.  It must be expected that this server will replace the mini-body
locally with the full body, remove the special header and store that
re-assembled article for as long as that article would be kept normally had
it arrived here complete and intact originally, and deliver this to the
originally querying newsreader, plus delivering the local complete copy to
any other readers that request the same article.

For CFS spool systems, you need the ability to free (or skip) the space
originally used for the header and mini body, and add a new copy of the
complete article to the spool (BODY AND HEADERS - remember you have to zap
the line in the headers that says you don't have the complete body - now
you do).  This means the mini-body strategy is more complex or slightly more
wasteful at CFS sites.  Traditional spools can simply construct and write-out
a new article file with no wasted/gas spool storage.

A variant on this is to always use a NNTP caching system and make it
responsible for obtaining the various pieces and storing it in its cache rather
than perform article substitution in the main spool.  This may makes updates
of mini-bodies for full-body articles simpler that what would have to be done
on CFS spool setups, but regardless of method, the goal is to not go back to
the donor server more than a few times for the same article over its retention
life.  In a popular binary group, a given part may be requested several
hundred times on each server, and some donor server isn't going to appreciate
your server (and thousands of others) constantly asking for the exact same
article over and over.  Plus you are blowing expensive bandwidth doing this.
Buy drives.


Oh, another benefit of such a scheme:  forging the Path: line becomes a thing
of the past, unless you don't really want anybody to see your article.
If you fake donor sites, those sites won't return the articles because their
name won't appear in the right place in the Path: on the copy they have,
assuming they got the article at all (in theory they should not).  If you add
fake non-donor sites, to the Path:, it will be even more obvious where the
real propagation path starts, where the + signs start to appear.   You might
as well put out flares...


[18]That works, but I think using the Path: header isn't the right solution for
[18]this.  As you say below, it causes complexities with aliases, and it also
[18]causes problems with systems such as frenix and things like that which look
[18]at path hosts.

If freenix can't grep out the odd "+" character when they process their
logs at the end of the month, then it should prove beyond question that the
stats produced are as useless today as they were in the eighties, when a
little Tandy 6000 (sys1) showed up as the number #1 site on the planet, simply
because it put its name in the Path: a *lot* and offered a few dozen feeds 
that were "badly" configured to systems known to be "close" to the freenix
feeds.  Yeah, this stunt made some people mad at the time, but it pretty much
proved the point that the formula used is subject to error and deception.


[18]If you mix it in the Path:, then you end up breaking existing systems
[18]with the new feature (even if only in minor ways).  

Not really.  I have neighbors tell me they are adding this or that backup
server and hand me additional aliases all the time.  Someone who is going
to be a donor simply has to tell their feed neighbors to alias out whatever
they alias out now, plus the same system names with a + on the front.
That's not breaking anything, that's configuration.  At worst, they will offer
articles back to the donor server needlessly, just like they do now when the
aliases aren't set right.


[18]Also, there's the issue of sites wanting to know how large the full article
[18]is (in bytes) when it's only got the header.  You need it for the XOVER
[18]data and for testing the size on outging feeds.

See above.  When a server converts the body of a post into a mini-body,
it adds a header (I suggested "Body-Truncated-at:"),  which provides the
true article size.  The overview data must reflect the size of the full
article, even if the system only has the mini-body currently.


Now, because it's so compatible with the existing scheme of things, someone
with some spare time can come up with a patch in a couple of hours, right?  :-)
That'll take care of all the INN/NNRPD servers out there.  Now we get to
wait for all the others to steal the idea and try to call it their own...


Frank Durda IV - only this address works:|"I picked up a Magic 8-Ball the
   <uhclem.jan00%nemesis.lonestar.org>   | other day and it said 'Outlook
			                 | not so good'.  I said 'Sure,
This Anti-spam address expires Jan. 31st | but Microsoft still ships it.'"
Copr. 1999, ask before reprinting.



Technical Details
Message-ID: <497C2C5D1309A679.AAC6286A5981D3B9.CB5C362B8D377A8F@lp.airnews.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
References: <09B506169F5CCAD5.ADBCDABED18E442A.5B349B33E0C2C1F4@lp.airnews.net> <19991222223519.382$HN@newsreader.com>

Show Full Headers
Complete Article Headers
Message-ID: <497C2C5D1309A679.AAC6286A5981D3B9.CB5C362B8D377A8F@lp.airnews.net>
Subject: Re: Header-Only feeds
Date: Tue, 28 Dec 1999 00:00:00 +0000
From: uhclem.jan00@nemesis.lonestar.org (Frank Durda IV)
References: <09B506169F5CCAD5.ADBCDABED18E442A.5B349B33E0C2C1F4@lp.airnews.net> <19991222223519.382$HN@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-mail
X-Deja-AN: 565571064
X-Orig-Message-ID: <849kpq$6nh@library1.airnews.net>
Followup-To: news.software.nntp,news.software.readers
NNTP-Posting-Time: Tue Dec 28 00:19:38 1999
Organization: The Big Blue Box
NNTP-Proxy-Relay: library1.airnews.net
Abuse-Reports-To: abuse at airmail.net to report improper postings
Newsgroups: news.software.nntp,news.software.readers