Usenet comp.unix.osf.osf1 (1992-2004)
 help / color / mirror / Atom feed
* xdm sessions at C2 security
@ 1998-02-13  5:00 Jim Yehle - Leppert Lab
  0 siblings, 0 replies; only message in thread
From: Jim Yehle - Leppert Lab @ 1998-02-13  5:00 UTC (permalink / raw)



The FAQ writeup applies to 3.x, and it all changed in 4.x.

Try this script for OS v 4.x:

#!/usr/bin/sh
#
# xdm-c2.sh
#
# Add a terminal to XDM allowables list under C2 (enhanced security)

PATH=$PATH:/usr/tcb/bin; export PATH
echo -n "Enter name or IP address of trusted X host: > "
read host
#n just look 'em both up
#n if echo "$host" |egrep '^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$' >/dev/null
nslookup $host >/dev/null
EX=$?
if [ $EX != 0 ]; then
   echo "nslookup failed w/ exit status $EX"
   exit $EX
fi
qualhost=`nslookup $host |egrep '^Name:' |awk '{print $2}'`
lochost=`echo $qualhost |cut -d. -f1` # Chop off domain

echo "Attempting to add the following tty entry:"
edauth -g -d t local:0 |sed "s/local/$lochost/g"
edauth -g -d t local:0 |sed "s/local/$lochost/g" |edauth -d t -s -C

echo "Attempting to add the following devassign entry:"
echo "$lochost\:0:v_devs=$lochost\:0:v_type=xdisplay:chkent:"
echo "$lochost\:0:v_devs=$lochost\:0:v_type=xdisplay:chkent:" \
 |edauth -d v -s -C

echo -n "Allow logins as root from $lochost? "
read rootyesno
case _$rootyesno in
   _Yy*) 
      if egrep "^$lochost:0\$" >/dev/null; then
         echo Appending $lochost:0 to /etc/securettys
         echo $lochost:0 >>/etc/securettys
      fi
      if egrep "^$qualhost:0\$" >/dev/null; then
         echo Appending $qualhost:0 to /etc/securettys
         echo $qualhost:0 >>/etc/securettys
      fi
      ;;
   *)
      ;;
esac

--
Jim
--
jim.yehle%at%genetics%dot%utah%dot%edu
Eccles Institute of Human Genetics
University of Utah, Salt Lake 84112



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~1998-02-13  5:00 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1998-02-13  5:00 xdm sessions at C2 security Jim Yehle - Leppert Lab

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox