From: V5068U%TEMPLEVM.BITNET@mitvma.mit.edu (jim wiegand)
Newsgroups: alt.os.linux
Subject: updated su (Was: Re: GCC and shell utils)
Date: 15 Apr 92 21:41:33 GMT
Article-I.D.: athena.1992Apr15.214133.19167
Reply-To: V5068U%TEMPLEVM.BITNET@mitvma.mit.edu
Organization: The Internet

This is an updated version of su that handles encrypted passwords.
It requires that you have the libufc.a from poeigl1.2 (poe init-getty-login)
installed in /usr/lib.

The reason the old su did not handle setgid properly is because
the syntax of chmod is (still) broken - a+sg causes the error
``invalid mode''! And, being a DOS weenie, i did not realize that
chmod 7555 accomplished the same end.

Please note that the source is derived from Berserkely code and is
therefore covered under their copyleft.

Also note the shell defaults to /bin/sh. This will be fixed after school
lets off^H^Hut.

-- jim wiegand v5068u at vm.temple.edu

begin 600 su.tar.Z
M'YV03<*L*6,F#9LR`!(J7,BPH<.'$"-*G$@1`(B+-FC0`&'QXL49'#W&T!C2
MH\D9-&Q<K!'CQ@P8+&O0@'$Q!@R4,BS"J,BSI\^?0`'4F4,GC)R+`-2D:1,4
MXM`R<II*G4JUJM6K6'D^$:)D"H@>(,Z4H0,GS)PY+MZ`F%,G+0@%1;`4`<M6
M@8(P;-CH`$$"1=PB*>RRW=MW:]?`"?H.&9*"KU^Y*5R,`=&"31TSDUNH[?LW
ML((T;HCBU:L@01L[CCL[3N)D"A7$8]"\N>/&\9,K3HI(:=R7M>L4+SA#+AV[
MS1LR(&[46+ZZ]>O@CP$31V,<>9@5<YK_AM[9[IB#8=SH*"VG#64Y9E)#!J$B
MK=VL\./+GT^_OGVI4HH$(=*DR/W_0'ED`PPT=>012`9>5*!)(K54PTHMO52#
M#!K1=)%R,MR@$X`<-C5444=QI!136,GQQAMT=*CBBBQV2`4::607(PCA@5`'
M'&2$04<9R-D!U1QIO%';&^FQ!0(=:.@(0I)ND'%0=F6X,88<><"Q(W)EG77'
M&W*0@98"2=`!@AQEQ%%'&F1FAZ22>;Q1QY)A^'@D&F6`P$8:8EPVA@MA@&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