# /etc/x29-auth -- control x29 logins.
#
# Example file for x29d from <pb@cl.cam.ac.uk> which is an extension of the
# format used by SUN -- this is intended to be upwards compatible.
# By using the #ignore and #x29do pragmats it can be guaranteed to be ....
#
#
# In case you still want to run the SUN x29 daemon, you can generate
# lines pairs of the form specified below, which are ignored by x29d.
#ignore
*@/bin/login
#
# Enough of the compatability lark -- lets do something useful ...
#
# It does a "first match", so put the most explicit patterns first ...
#
# Relay functions: telnet (or rlogin ?) to remote host.
#
# == SWITCH BY INCOMING DTE ==
# -- relay X.25 over TCP --
# Any x29 (-x) call to dte address (-a) 00000801170607 is actually a call
# for the machine jenny which is in the process of having its YuckBox removed
# So, Any calling address, exec /etc/x25r to relay the packets directly.
# Call it with args (-n) "jenny-relay" (command name) and "jenny" (argument).
.....
#
# -- gateway to simple telnet --
# Only accept calls whose CUDF (-d) is "telnet." and in this case the argument
# is the called_cudf with the first 11 characters (4 of protocol id and 7 of
# "telnet.") stripped off.
# Try direct telnet first (-t) and if that fails, generate a pty & invoke
# /usr/ucb/telnetd
*@/usr/ucb/telnet:-x -N -d telnet.* -n telnet-relay\ $called_cudf+11 -t $called_cudf+11:
# Any call for Sub-Address 45 goes to an ULTIX telnet/DECNET gateway
*:-x -T		     -a 00000801????45 -t dgate:
#
# -- invoke login --
# Amy call to SA 61 is calling out UUCP server
*@/bin/login:-x      -a 00000801????61 -n uucp-serv\ -h$calling_shortname:
#
# -- invoke random program --
# SA 39 is an X29 service which performs an NRS (nameserver) lookup.
* It needs to know the environment of the caller, so it passed over the
* short & longform names (UK specific)
*@/usr/lib/nfsbin/query:-x -a 00000801????39 -n query\ -z$calling_name\ -Z$calling_longname:
#
# calls from DTE range can call our NNTP-over-X29 server,
# only directly over telnet (-T), forcing echo off (-H) [ = hidden],
# using the telnet port nntp (-p)
000008010080*:-x -H -T -a 00000801????59 -t nntp-serv -p nntp:
#
#
# == SWITCH BY INCOMING CUDF ==
# Direct login
*@/bin/login:-x   -d gannet            -n x29d-login\ -h\ $calling_shortname:
# x. identifies that this is an x29 relay
*@/etc/x25r:-x -F -d x.*               -n x29r\ -zx$calling_dte\ -h$cudf+6:
# Explicit named hosts don't need x.
*@/etc/x25r:-x -F -d jenny|steve       -n x29r\ -zx$calling_dte\ -h$cudf+4:
# generic name maps to specific host
*@/etc/x25r:-x -F -d x.pbank|pbank     -n x29r\ -zx$calling_dte\ -hgrove:
# 
# == CATCHALL ==
# If we can't find any sort of match, generate a pty & invoke a shell script
# which can ask what to do, log username & do rlogin, tell user what to do,
# etc, etc, etc.  Pass lots of info for logging ...
# Only do this if all else fails, i.e. at end of last scan, which match
# against: 1: addr, cudf 2: name, cudf 3: addr, hexcudf 4: name hexcudf
# where name is e.g. uk.ac.cam.cl and addr is e.g. 000008010080
*@/etc/term-relay:-S 3 -x -n term-relay\ -h$calling_shortname\ -x=-=$called_dte//$called_ybts//$called_cudf_hex=\:
