Subject: Re: Guestgroup /bin/ls on IRIX5.3 (still...)

From: Mark Bergstrom <[email-masked]>
Date: Wed, 2 Apr 1997 22:31:42 -0600 (CST)

Frans-
I have now built from 2 different wu-distributions, one older that I had to
hack around to get the make; one the newest Beta-13.  The 'ls' behavior is
identical no matter what for guestgroup (as I said before, real and
anonymous work). Since I also built the 'ls' in the bin from the GNU
fileutils as expressly non-shared. 

[as provable via:  strings -a bin/ls | grep \\.so yielding nothing]

I have run the tests with debug set in client line and the -d flag on the
daemon in the inetd.conf.  (also -a -L -l).  The excerpted transaction
pertinent from the STDOUT is

220 hostxx FTP server (Version wu-2.4.2-academ[BETA-13](1) Wed Apr 2
18:22:11 PST 1997) ready.
Name (hostxx:root): sample
331 Password required for sample.
Password:
230 User sample logged in.  Access restrictions apply.
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> debug
Debugging on (debug=1).
ftp> debug 99
Debugging on (debug=99).
ftp> pwd
---> PWD
257 "/sample" is current directory.
ftp> ls
---> PORT 75,10,40,4,121,132
200 PORT command successful.
---> LIST
150 Opening ASCII mode data connection for /bin/ls.
226 Transfer complete.
ftp> quit
---> QUIT
221 Goodbye.

and from the SYSLOG output

Apr  3 03:53:14 7D:hostxx ftpd[17472]: <--- 220 
Apr  3 03:53:14 7D:hostxx ftpd[17472]: hostxx FTP server (Version wu-2.4.2-acade
m[BETA-13](1) Wed Apr 2 18:22:11 PST 1997) ready.
Apr  3 03:53:17 7D:hostxx ftpd[17472]: command: USER sample^M
Apr  3 03:53:17 7D:hostxx ftpd[17472]: <--- 331 
Apr  3 03:53:17 7D:hostxx ftpd[17472]: Password required for sample.
Apr  3 03:53:20 7D:hostxx ftpd[17472]: command: PASS password^M
Apr  3 03:53:20 7D:hostxx ftpd[17472]: <--- 230 
Apr  3 03:53:20 7D:hostxx ftpd[17472]: User sample logged in.  Access restrictio
ns apply.
Apr  3 03:53:20 6D:hostxx ftpd[17472]: FTP LOGIN FROM pigpen [75.10.40.4],
sample
Apr  3 03:53:20 7D:pigpen ftpd[17472]: command: SYST^M
Apr  3 03:53:20 7D:pigpen ftpd[17472]: <--- 215 
Apr  3 03:53:20 7D:hostxx ftpd[17472]: UNIX Type: L8
Apr  3 03:53:35 7D:hostxx ftpd[17472]: command: PWD^M
Apr  3 03:53:35 7D:hostxx ftpd[17472]: <--- 257 
Apr  3 03:53:35 7D:hostxx ftpd[17472]: "/sample" is current directory.
Apr  3 03:53:37 7D:hostxx ftpd[17472]: command: PORT 75,10,40,4,121,132^M
Apr  3 03:53:37 7D:hostxx ftpd[17472]: <--- 200 
Apr  3 03:53:37 7D:hostxx ftpd[17472]: PORT command successful.
Apr  3 03:53:37 7D:hostxx ftpd[17472]: command: LIST^M
Apr  3 03:53:37 7D:hostxx ftpd[17472]: <--- 150 
Apr  3 03:53:37 7D:hostxx ftpd[17472]: Opening ASCII mode data connection for /b
in/ls.
Apr  3 03:53:37 7D:hostxx ftpd[17472]: <--- 226 
Apr  3 03:53:37 7D:hostxx ftpd[17472]: Transfer complete.

Apr  3 03:55:10 7D:hostxx ftpd[17472]: command: QUIT^M
Apr  3 03:55:10 7D:hostxx ftpd[17472]: <--- 221 
Apr  3 03:55:10 7D:hostxx ftpd[17472]: Goodbye.
Apr  3 03:55:10 6D:hostxx ftpd[17472]: FTP session closed

>From: Frans Stekelenberg <[email-masked]>
>Subject: Re: Guestgroup /bin/ls on IRIX5.3
>
>>>From <[email-masked]> Wed Apr 02 05:22:59 1997
>>Comments: Authenticated sender is <[email-masked]>
>>From: "frans stekelenburg" <[email-masked]>
>>Organization: KNMI
>>To: Mark Bergstrom <[email-masked]>
>>Date: Wed, 2 Apr 1997 15:25:44 +0100
>>Subject: Re: Guestgroup /bin/ls on IRIX5.3
>>Priority: normal
>>
>>On  1 Apr 97 at 20:45, Mark Bergstrom wrote:
>>
>>> I'll get this back into the regular mailing list, but I have now been
>>> fighting with it for so many days (weeks) that I'm looking for anybody with
>>> a successful prior experience.
>>> As
>>> you can read, the /dev and /lib are per the guest-how-to for IRIX.  Still no
>>> go.
>>> 
>>> Mark
>>
>>	Allright, I gladly will try to help you out here.
>>	First I'll sum the files installed here:
>>
>>=========================================================================
>>/etc/passwd: (relevant lines)
>> ftp:NoLogin:100:100:Anonymous FTP account:/mydisk/FTP/ftpdata:/bin/false
>>
__________________-Here is mine
sample:x:1731:925:sample ftponly acct:/usr/people/./sample:/bin/ftponly

>>[513]me@myhost:/mydisk/FTP/ftpdata  ls -la ~ftp
>>total 24
>>dr-xr-xr-x   10 ftp      ftp          153 Mar 21 13:15 ./
>>dr-xr-xr-x    7 ftp      ftp          105 Mar 31 18:00 ../
>>-rw-r--r--    1 root     sys          556 Jan  6 14:57 .message
>>dr-x--x--x    2 root     sys           76 Jan 13 18:10 bin/
>>dr-x--x--x    2 root     sys           22 Feb  3 12:23 dev/
>>dr-x--x--x    2 root     sys           55 Jan 13 18:10 etc/
>>d-wx-wx-wx    6 incoming sys           72 Apr  2 11:30 incoming/
>>dr-x--x--x    2 root     sys           39 Jan 13 18:11 lib/
>>drwx--x--x   16 root     ftp         4096 Mar 14 16:19 project/
>>dr-x--xr-x    3 ftp      sys           22 Apr  2 12:25 pub/
>>drwxr-x--x    3 root     sys           24 Mar 21 13:15 staff/
>>-r-x--x--x    1 ftp      sys          556 Jan 13 08:04 welcome.msg*
>>
____________________-Here is mine

hostxx 17# ls -al /usr/people/sample
total 7
drwxr-xr-x    8 sample   client       156 Apr  2 11:29 .
drwxr-xr-x   62 root     sys         3072 Mar 31 16:43 ..
-r--------    1 root     sys            0 Mar 25 19:25 .forward
-rw-r--r--    1 root     sys           12 Apr  2 11:30 .message
-r--------    1 root     sys            0 Mar 25 19:25 .rhosts
dr-x--x--x    2 root     sys           78 Apr  2 11:10 bin
dr-x--x--x    2 root     sys           22 Mar 25 19:37 dev
dr-x--x--x    2 root     sys           38 Mar 25 19:55 etc
d-wx-wx-wx    2 sample   sys            9 Apr  2 11:22 incoming
dr-x--x--x    2 root     sys           39 Apr  2 12:09 lib
dr-x--xr-x    2 sample   sys            9 Apr  2 11:21 pub
-r-x--x--x    1 sample   sys            0 Apr  2 11:29 welcome.msg

I have had bin dev etc lib both ways: 511 and 111. No difference.

>>
>>[/mydisk/FTP/ftpdata/bin]
>>[514]me@myhost:/mydisk/FTP/ftpdata ls -la ~ftp/bin
>>total 280
>>dr-x--x--x    2 root     sys           76 Jan 13 18:10 ./
>>dr-xr-xr-x   10 ftp      ftp          153 Mar 21 13:15 ../
>>---x--x--x    1 nobody   sys        25508 Jan  6 14:42 compress*
>>-rwxr-xr-x    1 root     sys          308 Jan 13 08:55 false*
>>---x--x--x    1 nobody   sys        29604 Jan  7 13:19 ls*
>>---x--x--x    1 nobody   sys        70564 Jan  7 13:20 tar*
>>-rwxr-xr-x    1 root     sys          321 Jan 13 08:56 true*
>>
>>* Note: these are _copied_ into ~ftp/bin. Though hard-links oughtta be
>possible 
>>too.
__________________-Here is mine
hostxx 18# ls -al /usr/people/sample/bin
total 819
dr-x--x--x    2 root     sys           78 Apr  2 11:10 .
drwxr-xr-x    8 sample   client       156 Apr  2 11:29 ..
---x--x--x    1 root     sys        27440 Apr  2 11:10 compress
-r-xr-xr-x    1 root     sys          295 Apr  2 11:08 ftponly
---x--x--x    1 root     sys        88832 Apr  2 11:10 gzip
---x--x--x    1 root     sys       222616 Mar 27 17:49 ls
---x--x--x    1 root     sys        79096 Apr  2 11:09 tar

Note if I do: strings -a ./ls | grep \\.so
There are NO .so's since I compiled it that way

>>
>>[515]me@myhost:/mydisk/FTP/ftpdata   ls -la ~ftp/dev
>>total 0
>>dr-x--x--x    2 root     sys           22 Feb  3 12:23 ./
>>dr-xr-xr-x   10 ftp      ftp          153 Mar 21 13:15 ../
>>cr--r--r--    1 root     sys       37,  0 Feb  3 12:23 zero
>>
>>* made with "mknod c 37 0"
>>
__________________-Here is mine (Ditto your process)
hostxx 31# ls -al dev
total 0
dr-x--x--x    2 root     sys           22 Mar 25 19:37 .
drwxr-xr-x    8 sample   client       156 Apr  2 11:29 ..
cr--r--r--    1 root     sys       37,  0 Mar 25 19:37 zero

>>
>>[516]me@myhost:/mydisk/FTP/ftpdata   ls -la ~ftp/lib
>>total 4608
>>dr-x--x--x    2 root     sys           39 Jan 13 18:11 ./
>>dr-xr-xr-x   10 ftp      ftp          153 Mar 21 13:15 ../
>>-r-xr-xr-x    1 root     sys      1805232 Jan 13 08:12 libc.so.1*
>>-r-xr-xr-x    1 root     sys       552916 Jan 13 08:29 rld*
>>
>>* these'r copied, too.
__________________-Here is mine (Ditto your process)
hostxx 32# ls -al lib
total 4097
dr-x--x--x    2 root     sys           39 Apr  2 12:09 .
drwxr-xr-x    8 sample   client       156 Apr  2 11:29 ..
-r-xr-xr-x    1 root     sys      1511168 Apr  2 12:08 libc.so.1
-r-xr-xr-x    1 root     sys       585876 Apr  2 12:09 rld

Note the One thing I notice is your libc.so is about 20% huger, but for the
function of my static ls this is irrelevant.
>>
>>[517]me@myhost:/mydisk/FTP/ftpdata   ls -la ~ftp/etc
>>total 24
>>dr-x--x--x    2 root     sys           55 Jan 13 18:10 ./
>>dr-xr-xr-x   10 ftp      ftp          153 Mar 21 13:15 ../
>>-r--r--r--    1 bin      bin          152 Jan  7 13:31 group
>>-r--r--r--    1 bin      bin          494 Jan 30 15:17 passwd
>>
>>* put the bare basics in these file.
__________________-Here is mine (Just to be thorough, the entries too)
hostxx 33# ls -al etc
total 2
dr-x--x--x    2 root     sys           38 Mar 25 19:55 .
drwxr-xr-x    8 sample   client       156 Apr  2 11:29 ..
-r--r--r--    1 root     sys           56 Apr  2 18:03 group
-r--r--r--    1 root     sys           99 Apr  2 16:47 passwd

hostxx 35# more etc/group
sys::0:root,bin,sys,adm
root::0:root
client::925:sample

hostxx 38# more etc/passwd
root:*:0:0::/:/bin/fptonly
sample:x:1731:925:sample ftponly acct:/usr/people/./sample:/bin/ftponly

>>==================================================================
>>
>>
>>These are the surroundings, in which wu-ftp 2.4 is running. 
>>Now on a Irix 6.2 system; before on a 5.3 system. Though a little
>>quirk between these versions, it should work prettu similair.
>>I can't remember what or if special tricks where needed, after the
>>Irix upgrade. Though if I recall I needed the zero file afterwards.
>>Mind you that you _IF NEEDED_ may have to mknod with other params.
>>
>>Further more here's an excerpt of the ftpaccess file:
>>
>>
>>==================================================================
>>loginfails 2
>>
>>class   local   real,guest,anonymous *.domain 0.0.0.0
>>class   remote  real,guest,anonymous *
>>
>>limit   local   20  Any                 /mydisk/FTP/etc/msgs/msg.toomany
>>limit   remote  30  SaSu|Any1800-0600   /mydisk/FTP/etc/msgs/msg.toomany
>>limit   remote  20  Any                 /mydisk/FTP/etc/msgs/msg.toomany
>>
>>readme  README*    login
>>readme  README*    cwd=*
>>
>>message /welcome.msg            login
>>message .message                cwd=*
>>
>>compress        yes             local remote
>>tar             yes             local remote
>>
>># allow use of private file for SITE GROUP and SITE GPASS?
>>private         yes
>>
>># passwd-check  <none|trivial|rfc822>  [<enforce|warn>]
>>passwd-check    rfc822  enforce
>># log commands real,anonymous,guest
>>log transfers anonymous,real,guest inbound,outbound
>>
>>shutdown /etc/shutmsg
>>
>># all the following default to "yes" for everybody
>>delete          no      anonymous         # delete permission?
>>overwrite       no      anonymous         # overwrite permission?
>>rename          no      anonymous               # rename permission?
>>chmod           no      anonymous               # chmod permission?
>>umask           no      anonymous               # umask permission?
>>
>># guestgroups
>>guestgroup   ftpguest project1 project2 client1 client3 user5
>>
>># specify the upload directory information
>>upload  /mydisk/FTP/ftpdata  *             no
>>upload  /mydisk/FTP/ftpdata  /incoming     yes  incoming  daemon    0600
nodirs
>>upload  /mydisk/FTP/ftpdata  /incoming/temp yes  ftp  doc    0744 dirs
>>
>># directory aliases...  [note, the ":" is not required]
>>alias   inc:    /incoming
>>alias   people  /pub/people
>>
>># cdpath
>>cdpath  /incoming
>>cdpath  /pub
>>cdpath  /mydisk/WWW/people
>>cdpath  /
>>
>># path-filter...
>>path-filter  anonymous  /etc/pathmsg  ^[-A-Za-z0-9_\.]*$  ^\.  ^-
>>path-filter  guest      /etc/pathmsg  ^[-A-Za-z0-9_\.]*$  ^\.  ^-
>>
>># specify which group of users will be treated as "guests".
>>guestgroup ftponly
>>
>>email [email-masked]
>>
>>==========================
>>
__________________-Here is mine (Trivial next to yours)
hostxx 40# more /usr/local/etc/ftpaccess
class   local   real,guest,anonymous    *.pmi   0.0.0.0
class   remote  real,guest,anonymous    *
delete          no      anonymous,guest
overwrite       no      anonymous,guest
rename          no      anonymous,guest
chmod           no      anonymous,guest
umask           no      anonymous,guest
path-filter     guest   /etc/pathmsg    ^[-A-Za-z0-9_\.]*$ ^\. ^-
guestgroup client
log transfers anonymous,real,guest inbound,outbound

The only significant difference between yours and mine is I see in yours is
that you define guestgroup twice.

>>Please let me know if this brings you forward, I'll be glad to help in every 
>>way to solve your problem.
>>
>>--gjs

Unfortunately, I cannot report any guestgroup 'ls' success in spite of these
layers and layers of effort. As I noted before, all other facets are working
correctly.  SEND,RECV via telnet-style. get,put,et alyi via ftpclient-style.

Mark