Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ mh-alias(5) — AIX PS/2 1.2.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

group

passwd

ali

conflict

post

send

sendmail

whom



MH-ALIAS(5,F)               AIX Technical Reference               MH-ALIAS(5,F)



-------------------------------------------------------------------------------
mh-alias



PURPOSE

Defines aliases for the Message Handling (MH) Package.

DESCRIPTION

The Message Handling (MH) Package supports both personal alias files and a
system-wide alias file, /usr/lib/mh/MailAliases.  Depending on the MH
configuration, MH may also honor system-wide alias defined for the sendmail
command.  An alias file contains lines that associate an alias name with an
address or a group of addresses.

File Format

Each line of an alias file has one of the following formats:

   alias : address-group

   alias ; address-group

   <file

where

address-group   :=   address-list
                |    <file
                |    =AIX-group
                |    +AIX-group
                |    "*"

address-list    :=   address
                |    address-list, address

You can continue an alias definition on the next line by ending the line to be
continued with the \ (backslash) character followed by the new-line character.

The alias-file and file parameters must be AIX file names.  AIX-group must be a
group name (or number) from /etc/group.  address must be a simple
Internet-style address.  MH treats alias file names as case sensitive names but
ignores case elsewhere in alias files.

If a line starts with the "<" (less than) character, MH reads the file
specified after the "<" for more alias definitions. The reading is done
recursively.






Processed November 7, 1990       MH-ALIAS(5,F)                                1





MH-ALIAS(5,F)               AIX Technical Reference               MH-ALIAS(5,F)



If an address group starts with the "<" (less than) character, MH reads the
file specified after the "<" and adds the contents of that file to the address
list for the alias.

If an address group starts with the "=" (equal) character, MH consults the
/etc/group file for the AIX group specified after the equal character.  MH adds
each login name occurring as a member of the group to the address list for the
alias.

If an address group starts with the "+" (plus) character, MH consults the
/etc/group file to determine the group ID of the AIX group specified after the
plus character.  MH adds each login name occurring in the /etc/passwd file
whose group ID is indicated by this group to the address list for the alias.

If an address group is specified as "*" (asterisk), MH consults the /etc/passwd
file and adds all login names with a UID greater than 200, or the value set for
everyone in /usr/lib/mh/mtstailor to the address list for the alias.

An approximation of the way the system resolves aliases at posting time:

  1. The system builds a list of all addresses from the message to be
    delivered, eliminating duplicate addresses.

  2. If the draft originated on the local host, the system performs alias
    resolution for those addresses in the message that have no host specified.

  3. For each line in the alias file, the system compares the alias with all
    existing addresses.  If a match is found, the system removes the matched
    alias from the address list, and adds each new address in the address group
    to the address list if it is not already in the list.  The alias itself is
    not usually output; the address group that the alias maps to is output
    instead.  If the alias is terminated with a ";" (semicolon) instead of a
    ":" (colon), both the alias and the address are output in the correct form.
    (This correct form makes replies possible since MH aliases and personal
    aliases are unknown to the mail transport system.)

In the MH system, aliases in alias files are expanded into the headers of
messages posted.  This aliasing occurs first, at posting time, without the
knowledge of the message transport system.  In contrast, once the message
transport system is given a message to deliver to a list of addresses, for each
address that appears to be local, a system-wide alias file is consulted.  These
aliases are not expanded into the headers of messages delivered.

Since alias files are read line by line, forward references work, but backward
references are not recognized.  Although this forward referencing semantics
prevents recursion, the <alias-file syntax may defeat this.  Since the number
of file descriptors is limited, such recursion will end when all file
descriptors are depleted.

EXAMPLE

The following example of a mh-alias file illustrates some features:



Processed November 7, 1990       MH-ALIAS(5,F)                                2





MH-ALIAS(5,F)               AIX Technical Reference               MH-ALIAS(5,F)




       </user/lib/mh/DraftingAlias
       temps:peggy,tina
       tina:temp5@NODE3
       p1:<project1.aliases
       staff:=staff
       support:+syssup
       everyone:*
       news.*:news

The first line says that more aliases should immediately be read from the file
"/usr/lib/mh/DraftingAliases".  Following this, "tina" is defined as an alias
for "temp5@NODE3", and "temps" is defined as an alias for the two names "peggy"
and "tina".  The definition of "p1" is given by reading the file
user_mh_directory"/project1.aliases".  "staff" is defined as all users who are
listed as members of the group "staff" in the /etc/group file, and "support" is
defined as all users whose group ID in /etc/passwd is equivalent to the
"syssup" group.  Finally, "everyone" is defined as all users with a user ID in
/etc/passwd greater than 200, and all aliases of the form "news."anything are
defined to be "news".

FILES

/usr/lib/mh/MailAliases   The default system alias file.

/usr/lib/mh/mtstailor     The MH tailor file.

RELATED INFORMATION

In this book:  "group" and "passwd."

The ali, conflict, post, send, sendmail, and whom commands in AIX Operating
System Commands Reference.

The "Overview of the Message Handling Package" in Managing the AIX Operating
System.



















Processed November 7, 1990       MH-ALIAS(5,F)                                3



Typewritten Software • bear@typewritten.org • Edmonds, WA 98026