DataMuseum.dk

Presents historical artifacts from the history of:

DKUUG/EUUG Conference tapes

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about DKUUG/EUUG Conference tapes

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download
Index: ┃ A T

⟦f69379737⟧ TextFile

    Length: 16382 (0x3ffe)
    Types: TextFile
    Names: »Alias.guide«

Derivation

└─⟦a0efdde77⟧ Bits:30001252 EUUGD11 Tape, 1987 Spring Conference Helsinki
    └─ ⟦this⟧ »EUUGD11/euug-87hel/sec1/elm/doc/Alias.guide« 

TextFile

.PH ""
\"
\"  A guide to the ELM alias system and so on.
\"  format with 'troff -mm Config.guide > Config.format'
\"  or something similar.
\"  (C) Copyright 1986 Dave Taylor
\"
\"  Last modification: January 19th, 1987
\"
.SA 1
.nr Hy 1
.nr Pt 1
.nr Pi 8
.lg
.HM 1 1
.rs
.ds HF 3  3  
.ds HP 12 12 10 10 10
.PF ""
.ce 99
.sp 5
.ps 20
\fBELM Alias Users Guide\fR
.sp 4
.ps 12
\fIWhat aliases are and how to use them
in the \fBElm\fP mail system\fR
.sp 2
Dave Taylor
.sp
Hewlett-Packard Laboratories
1501 Page Mill Road
Palo Alto CA
94304
.sp 
email: taylor@hplabs.HPL.HP.COM or hplabs!taylor
.sp 7
.ps 18
\fB\(co\fR\s12 Copyright 1986, 1987 by Dave Taylor
.ps 10
.SK
.sp 5
.ps 14
\fBElm Alias Users Guide\fR
.PH "'Alias Users Guide''version 1.5'
.PF "''Page \\\\nP''"
.nr P 1
.sp
.ps 10
(version 1.5)
.sp 2
Dave Taylor
.sp
Hewlett-Packard Laboratories
1501 Page Mill Road
Palo Alto CA
94304
.sp 
email: taylor@hplabs.HPL.HP.COM or hplabs!taylor
.sp 2
\*(DT
.ce 0
.sp 3
.P
This document is intended as a supplement to the \fIElm Users Guide\fR
and is only of interest to those users desiring more knowledge
about how aliases work and how to create strange and exciting
aliases for their systems (alright, so it's not \fIthat\fR exciting!)
.sp
.P
This document is broken up into the following sections;
user aliases,
group aliases,
system aliases,
editing and installing new aliases,
the machine routing database,
the domain routing database,
and general warnings and other chitchat.
.sp
.H 1 "User Aliases"
The most simple sort of aliases in the \fBElm\fR system are individual
user aliases.  These are made up of three parts;
.nf

	\fIaliasname list\fR : \fIusername\fR : \fIaddress\fR

.fi
Where the \fIaliasname list\fR is either a single aliasname\*F
.FS
Please see the appendix for a full definition of what exactly an
aliasname consists of.
.FE
or a list of aliasnames separated by commas.
.P
\fIUsername\fR is used to indicate the full "real name" of the user.  
For example, if you had an alias for "dat" to get to me, the 
\fIusername\fR field would contain "Dave Taylor" or perhaps "Dave Taylor at HP"
or some other permutation.  Versions 1.2a and later of the \fBElm\fR
system use this information to add to the addresses of outbound mail
in the interest of more readable addresses.  It is recommended that this
field contain peoples names only.
.P
\fIAddress\fR is either the users full electronic mail address or, if
the machine routing database is installed, the minimum address needed
to specify the destination.  For example, say our routing database
contained information on how to get to machine "hp-sdd" and I wanted
to have an address for my friend Ken there - I could have his address
specified as simply "ken@hp-sdd" (or alternatively "hp-sdd!ken" since
the two are functionally equivalent).
.sp
.P 0
Let's get on to some examples, shall we?
.sp
Consider this excerpt from my own \fI.alias_text\fR file;
.nf

wunder,walter : Walter Underwood: wunder@hpcea
laubach       : Mark Laubach    : laubach@hpcea
mary          : Mary Hsia-Coron : hsia@hpindla
decot         : Dave Decot      : decot@hpda
 	
jeff	      : Jeff Wu         : hpcnoe!j_wu
dave	      : Dave Barrett    : hpcnof!d_barrett

.fi
Note that the alias for Walter Underwood has two \fIaliasnames\fR associated
with it, \fIwunder\fR and \fIwalterf\R.  Also notice that the first four aliases
use the Internet style naming convention (\fIuser@machine\fR) but the last two
use the UUCP style convention (\fImachine!user\fR).  In this context it is
independent.
.P
The only time when it \fIdoes\fR make a difference which notation you
use is if you have to specify more than the machine that the user is
receiving mail on.  That is, say we have a friend who receives mail at
a machine called \fBtwinkie\fR and our best connection is through Georgia
Institute of Technology (``gatech'')...Our alias for them could be;
.nf

  buddy         : Our friend      : gatech!twinkie!buddy

or

  buddy2        : Our friend      : gatech!buddy@twinkie

.fi
but not;
.nf

  buddy         : Our friend      : buddy@twinkie@gatech

.fi
(however, buddy%twinkie@gatech \fIwill\fR also work, but that's far
too bizarre a notation to be recommended!!) (besides there's no
guarantee that "gatech" will like it, nor the "buddy2" alias above!)
.P
Anyway, suffice to say that if you must specify any sort of route
that you should use the uucp notation as much as possible to ensure
that the system expands the correct machine name.
.sp
.H 1 "Group Aliases"
After the confusion of user aliases, group aliases are even more 
fun!  For the most part the notation is very similar;
.nf

	\fIaliasname list\fR : \fIgroupname\fR : \fIlist of people\fR

.fi
Where \fIaliasname list\fR and \fIgroupname\fR are exactly equivalent
to the corresponding fields in user aliases.
.P
The interesting part is the \fIlist of people\fR field!  This
field is actually in the same notation as the aliasname list,
so it's not quite as strange as I've lead you to believe.
It's best to illustrate by example;
.nf

friends, mypals, gang : The Gang of Six : joe, larry, mary, joanna,
					  nancy, michael

.fi
(Notice that you can continue onto as many lines as you'd like so
long as each additional line start with either a \s8SPACE\s10 or a \s8TAB\s10
character)
.P
The significant limitation with group aliases is that each of the
people in the list must be a \fIpreviously defined aliasname in either the
existing alias file or the system alias file\fR or a valid destination
on the current machine.
.P
What does this mean?  This means that the following excerpt from an
alias file;
.nf

hawaii : The Hawaiian Twins : joe@\s8RIT-CS.ARPA\s10, maoa
maoa   : Maoa Lichtenski Jr : maoa@Hawaii.cs.uh.\s8ARPA\s10

.fi
will fail for two reasons - not only does the group \fIlist of people\fR
contain a complex address, but it also contains an aliasname that is 
defined \fIlater\fR in the \fI.alias_text\fR file!  \fB** \s8BEWARE\s10!!! **\fR
.P
The correct way to have the previous alias in the file is to have it like;  
.nf

joe    : Joe Lichtenski     : joe@\s8RIT-CS\s10
maoa   : Maoa Lichtenski Jr : maoa@Hawaii
hawaii : The Hawaiian Twins : joe, maoa

.fi
which will then work correctly.
.P 0
This isn't too hard now, is it?
.sp
Fortunately, while this seems pretty tough, when you run \fInewalias\fR
to install the new aliases, it will give you relevent and meaningful
error messages that will help you fix the list up correctly!
.sp
.H 1 "System Aliases"
System aliases are functionally equivalent to the individual \fBElm\fR 
alias lists each \fBElm\fR user has (both user aliases and group aliases) 
but are "read only" for everyone but the \fBElm\fR administrator.  The 
format of the file is identical to the users file, and the only difference is
that this file is expected to be located in the directory that contains
the \fIsystem_hash_file\fR and \fIsystem_data_file\fR files (see the
\fIElm Configuration Guide\fR for more details on these variables).
.P
Simply create a \fI.alias_text\fR file in the specific directory
as you would a normal file, and install it the same way (see the
following section for more details on that).  
.P
Voila!!
.sp
.H 1 "Editing and Installing New Aliases"
To install new aliases, you need merely to create, or modify,
your \fI.alias_text\fR file in your home directory until you're
satisfied with it and it meets the requirements stated above.
You can then try to install it with the command;
.nf

	$ \fBnewalias\fR

.fi
which will either report back the number of aliases installed into 
the system or will report errors indicative of the changes that
the program expects before it can accept the alias list.
.P
Note that blank lines are no problem and that comments are not only
allowed but actually encouraged, and must have `\fB#\fR' as the first
character of each comment line.
.sp
Finally, if you find that you're hitting the ``Too many aliases'' error, 
then you'll need to reconfigure the entire \fBElm\fR system (again,
see the \fIElm Configuration Guide\fR).
.sp
.H 1 "The Hostname Routing Database"
Floating about on the various networks is a rather nifty program by
a number of people, including Peter Honeyman and Steve Bellovin, 
called \fIpathalias\fR.  What this incredibly handy program does is 
take the strange postings in netnews groups like "news.map" and massage
them into a file of the form;
.nf

  \fIhostname\fR    <tab>    \fIaddress\fR

.fi
which is then sorted alphabetically and stored in the file
pointed to by \fIpathfile\fR (guess where to look for more information!)
for \fBElm\fR to use.
.P
If you don't have the program, or don't want to use it, you can 
simulate this file by listing machines in the same format.  The
exact format expected is;
.nf

  \fIhostname\fR<tab>\fImachine-address\fR

.fi
where \fIhostname\fR is a limited identifier (no special characters) and
machine-address MUST contain the sequence `%s' (and consequently
any other percent signs that appear in the address must be paired)
so that the call in the program ``sprintf(buffer, machine-address, username)''
will generate a valid return address.
.P 0
By way of example, here are a few entries from my own file;
.nf

 \s8HPL\s10    hplabs!%s
 \s8PARC\s10   hplabs!%s@Xerox.\s8PA.COM\s10
 amc-hq     hplabs!%s@\s8AMC-HQ.ARPA\s10
 imsss	    hplabs!%s%%\s8IMSSS@SU-AI.ARPA\s10
 infopro    hpfcla!ihnp4!astrovax!infopro!%s
 interleaf  hpfcdc!hpda!sun!interleaf!%s
 jpl-vax    hplabs!%s@jpl-vax

.fi
As you can see, the addresses can get pretty complicated!!  In fact
it's due purely to the complication that a database file of this
sort can be so wonderful!!
.sp
If you'd like further information on the pathalias program, try
keeping track of the entries in the netnews group \fImod.sources\fR - 
it's posted about once a year or so...
.sp
.H 1 "The Domain Routing Database"
One of the more interesting features of the 3.2 and above
\fBElm\fR mailer is the domain routing database.  This is
the same database (in the same strange format) as used by
the most recent version of the \fIuumail\fR program.
.P
In a nutshell, the file contains information of the form;
.nf

   \fIdomain\fR   \fIpathtogateway\fR  \fIrewrite-template\fR

.fi
The \fIdomain\fR field must begin with a leading `.' and
should be ordered in the same notation as the standard
domain information (that is, "\s8.HP.COM\s10" not "\s8.COM.HP\s10").
.P
\fIPathtogateway\fR is routing information on how to get
to the particular gateway that this domain expects, and
always is a machine/host name (to be found in the pathalias
database, see the previous section) preceeded by a `>' 
character.
.P
\fIRewrite-template\fR is the most interesting of the
three, and is akin to a printf string for C.  The 
changes are that instead of `%s' `%d' and so on, the
actual "percent" values represent various parts of 
the address, namely;
.nf

	Symbol		Represents
	------          ----------
	  %U		The username in the To: address
	  %N		The remote machine name
	  %D		%N + domain information 
	  %R		path to %N from pathalias
	  %P		\fIpathtogateway\fR entry
	  %S		Obsolete!
	  %%		The `%' character

.fi
with this very intuitive setup, let's look at a few entries 
from the domains database and see how they work;
.nf

.ps 8
  .EUR.UUCP,,,%R!%U
  .ATT.UUCP,>\s10ihnp4\s8,,%P!%D!%U
  .HP.COM,,,%R!%U
  .UUCP,,,%R!%U
  .COM,>\s10hplabs\s8,,%P!%U@%D
  .CSNET,>\s10hplabs\s8,,%P!%U%%%D@CSNET-RELAY.ARPA
  .ARPA,>\s10hplabs\s8,,%P!%U@%D
.ps 10

.fi
(Note the presence of a third field that is always null.  This is
for compatability with the "uumail" program, but this field is
now always \fI\s8NULL\s10\fR)
.P
To see how it all works, let's suppose that we want to send a message
to "jad@Purdue.\s8ARPA\s10".  This would break down into the following fields:
.nf

	%U = jad
	%N = Purdue
	%D = Purdue.\s8ARPA\s10
	  
.fi
When the \fBelm\fR program matches the ".\s8ARPA\s10" entry
.nf

  .\s8ARPA\s10,>hplabs,,%P!%U@%D

.fi
the other fields instantiated would be:
.nf

	%P = <path to hplabs>
  template = %P!%U@%D

.fi
As is hopefully obvious, if our path to hplabs was "hpcnoe!hplabs" then
the fully expanded address would be;
.nf

	hpcnoe!hplabs!jad@Purdue.\s8ARPA\s10

.fi
And so on.  
.sp
.P
What does this mean to the average user?  It means that you can
for the most part send mail to people on different gateways by
simply using their full domain information, so that mail to 
addresses like "Jack@\s8MIT.MIT.EDU\s10" will work, and mail 
to "SueAnn@\s8BBN.MAILNET\s10"
will work and so on!!
.sp
.H 1 "Other Stuff not Covered Yet"
Probably the biggest question you have in your mind right now is
"But how the heck does this relate to the 'ole \fIBerkeley Mail\fR
aliases and the snazzo \fIsendmail\fR alias system??"  Well,
rest assured, \fIsendmail\fR fans, that if you \fIreally\fR want to have
your aliases down in the transport you can.  No problem.  All you'll
need to do is to turn off the address validation routine in \fBElm\fR
(I'm not even going to bother to tell you where to look for this one!!).
.P
For those \fIBerkeley Mail\fR fanatics out there, you can translate your 
aliases into the format that \fBElm\fR wants by running them
through the \fIawk\fR script listed in Appendix Two.
.sp
.P
Finally, if you have any problems or questions, try looking in 
the \fInewalias\fR manual entry, or dropping me a line at the
"usual" email address (ask your administrator!).
.SK
.ce 99
Appendix One

A BNF of the Alias File Grammar
.ce 0
.sp 2
In this listing, items in <> brackets are non-terminals, items in {}
are optional, and items in \fBbold face\fR are terminals.
.sp 2
.nf

<alias_file>  ::=  <line> { <alias_file> }

<line>	      ::=  <comment> | <empty> | <alias>

<comment>     ::=  .. any sequence of characters starting with '#' ..

<empty>	      ::=  .. an empty line ..

<alias>	      ::=  <user alias> | <group alias>

<user alias>  ::=  <aliaslist> \fB:\fR { <comment> \fB:\fR } 
		   {<whitespace>} <address>

<group alias> ::=  <aliaslist> \fB:\fR { <comment> \fB:\fR } 
		   {<whitespace>} <list of addresses>

<aliaslist>   ::=  <aliasname> { \fB,\fR <aliaslist> }

<aliasname>   ::=  <alpha-char> { <sequence-of-chars> }

<comment>     ::=  .. anything other than ":" ..

<address>     ::=  <username> | <arpa-address> | <uucp-address> | 
		   <complex-address>

<list-of-addresses> ::= <aliasname> { \fB,\fR <whitespace> } 
			{ <list-of-addresses> }

<username>    ::=  .. any valid mailbox name on the system ..

<arpa-address> ::= <username> ( \fB@\fR <hostname> | <postfix> )

<hostname>    ::=  .. any legal host machine name ..

<uucp-address> ::= <hostname> \fB!\fR <username>

<complex-address> ::= <prefix> ( <uucp-address> | <arpa-address> )

<prefix>      ::= <hostname> \fB!\fR { <prefix> }

<postfix>     ::= \fB%\fR <hostname> { <postfix> } \fB@\fR 
		  <hostname>

<sequence-of-chars> ::= .. any characters other than space, tab, 
		           return, or colon ..

<whitespace> ::= .. space, tab or newline followed by space or tab ..

.fi
.SK
.ce 99
Appendix Two

An AWK Script for 
Translating Aliases from a \fIBerkeley Mail\fR
".mailrc" File to an \fIElm\fR ".alias_text" File
.ce 0
.sp 2
.nf
.ce
-------------------------------------------------------------------

BEGIN { print "# ELM alias_text file, from a .mailrc file..." 
	print ""
      }

next_line == 1 { 
	next_line = 0;
        group = ""
	for (i = 1; i <= NF; i++) {
	  if (i == NF && $i == "\\\\") sep = ""
	  else                       sep = ", "
	  if ($i == "\\\\") {
	    group = sprintf("%s,", group)
	    next_line = 1;
	  }
	  else if (length(group) > 0)
	    group = sprintf("%s%s%s", group, sep, $i);
	  else
	    group = $i;
	  }
	  print "\\t" group
	}
$1 ~ /[Aa]lias|[Gg]roup/ { 
	if ( NF == 3)
	  print $2 " : user alias : " $3;
	else {
	  group = ""
	  for (i = 3; i <= NF; i++) {
	    if (i == NF && $i == "\\\\") sep = ""
	    else        sep = ", "
	
	    if ($i == "\\\\") {
 	      group = sprintf("%s,", group)
 	      next_line = 1;
	    }
	    else if (length(group) > 0) 
 	      group = sprintf("%s%s%s", group, sep, $i);
	    else
 	      group = $i;
	    }
	    print $2 " : group alias : " group;
	  }
 	}

.ce
-------------------------------------------------------------------
.fi
.P
Note: this script is contained in the release under the name 
"mailrc.awk" in the utilities directory "utils".