Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/3/84; site delftcc.UUCP Path: utzoo!watmath!clyde!burl!ulysses!bellcore!decvax!decwrl!pyramid!pesnta!phri!delftcc!sam From: sam@delftcc.UUCP (Sam Kendall) Newsgroups: net.mail Subject: Pathalias/uumail: some algorithms and questions Message-ID: <122@delftcc.UUCP> Date: Sat, 1-Feb-86 03:01:42 EST Article-I.D.: delftcc.122 Posted: Sat Feb 1 03:01:42 1986 Date-Received: Mon, 3-Feb-86 05:35:16 EST Organization: Delft Consulting Corp., New York Lines: 85 I think the algorithms that underly a pathalias-routing program such as Stan Barber's uumail are worth discussing, independent of their implementation. What we need is a sort of "Guide to Using the Pathalias Database". I think there are two independent questions: first, given an address, what name(s) do we look up. (I am using "name" to mean site name, possibly qualified with domains.) Second, how do we look up those name(s). Okay, first question. Given a path a!b!c!...!p!q!r!stuff@z which name(s) do we try to look up? Basically, either (1) "a", or (2) "r", or (3) "z". We can refine these choices a bit: (1) if we don't find "a" in the database, we try "b", then "c", and so on; likewise, (2) if we don't find "r", we try "q", then "p", and so on. Also, (3) if we don't find "z", graduate to option (1) or (2). "uumail" lacks these refinements, I think, and it also has no option (2). Second question. Give an algorithm for mapping a name into a path. This is a series of alternatives to be tried in order until one works, something like: First strip off any ".uucp" domain; it is default, sort of. (Note: I am assuming case-independence, as in pathalias -i.) (1) Look it (the name) up in the pathalias database. (2) Look up all domains (if any), inner to outer (e.g., for "ernie.berkeley.edu", look up ".berkeley.edu" then ".edu"). If found, use the fully domain-qualified name in the path. (3) Prepend a "." to the name, and look it up. This is to cover things like "larry.rosler@ATT.UUCP" or "sob@harvard.edu"; "ATT.UUCP" and "harvard.edu" are domains, not actual hosts, but it can still make sense to send things to them. (I'm not sure that these addresses actually work.) (4) A questionable step: append ".UUCP" and use step (2), i.e., send the letter to the nearest UUCP gateway. This is justified if UUCP gateways tend to have more up-to-date pathalias entries than most sites. UUCP gateways should omit this step. But this might lead to UUCP gateways getting a lot of traffic in dead letters; this will be more tolerable when there are more UUCP gateways. (5) Give up. This assumes domain names have an initial dot, as in the latest version of pathalias. I don't know if this makes "uumail"'s domain table obsolete; the domain table is more flexible than domains handled through pathalias, but it would be much more elegant and convenient to handle domains entirely through pathalias. Certainly pathalias's domain handling (when combined with the algorithm above) is sufficient for my needs, but my site is UUCP-only. Implemented, I think my loose outline would result in at least two layers of subroutines. The top layer (which corresponds to my first question) parses the address, picking out names from it and calling the bottom layer (second question) to do the lookup(s). Finally, a couple of miscellaneous items. First, another question: that of private names. RFC 822 says that you can leave off the domain part of your destination site name if it is the same as your own. I don't remember how this works in a routing spec. Anyway, suppose I am mailing from site "a.WOMBAT.EDU" (also on the UUCP network) to site "x.WOMBAT.EDU". If I mail to "user@x", RFC 822 says it should go to "x.WOMBAT.EDU". No problem so far. But there is an actual site "x" on the UUCP network. Where should a letter to "x!user" go, "x.UUCP" or "x.WOMBAT.EDU"? There are frustrating name collision problems inherent in merging domains and the flat and/or relative UUCP namespace. Second, Peter Honeyman doesn't worry too much about address routing using just pathalias, I guess, because he is working with his more ambitious edge database. He talks about it a bit in the current issue of Unix Review. Eric Allman interviewed him, and it was pretty interesting to me (but I haven't been following net.mail for more than a few months). Comments, anyone? ---- Sam Kendall allegra \ Delft Consulting Corp. seismo!cmcl2 ! delftcc!sam +1 212 243-8700 ihnp4 / ARPA: delftcc!sam@nyu.ARPA