Path: utzoo!attcan!uunet!wuarchive!cs.utexas.edu!rice!sun-spots-request From: tjcm@stl.stc.co.uk Newsgroups: comp.sys.sun Subject: Anonymous FTP on Sun Keywords: Networks Message-ID: <3223@brazos.Rice.edu> Date: 20 Nov 89 17:49:28 GMT Sender: root@rice.edu Organization: Sun-Spots Lines: 63 Approved: Sun-Spots@rice.edu X-Sun-Spots-Digest: Volume 8, Issue 204, message 10 of 18 I am currently trying to set up an anonymous ftp service on a Sun 3/260 running SunOS 4.0.1. I am not entirely sure how to go about this, but we do have other Non-Sun machines around the site which have been successfully configured and I have based my initial attempt on those. The set-up is as follows: Create an ftp user in /etc/passwd: ftp:*:5555:6:Anon. FTP:/usr/spool/ftp: Create a directory /usr/spool/ftp with two sub-directories ./bin and ./etc. Place the binaries 'sh' and 'ls' in the ./bin directory. Place a 'passwd' file in the ./etc directory. The 'passwd file contains the following three users: root:*:0:1:Operator,SYSTEM:/: nobody:*:32767:32767:Mismatched NFS ID's:/: ftp:*:5555:6:Anon. FTP:/: When I try to make an ftp connection from another machine I get the following complaint when I use the 'ls' command within ftp: mach1% ftp -n mach2 Connected to mach2 220 mach2 FTP server (SunOS 4.0) ready. ftp> user ftp root 331 Guest login ok, send ident as password. 230 Guest login ok, access restrictions apply. ftp> ls 200 PORT command successful. 150 ASCII data connection for /bin/ls (XXX.YYY.200.6,1513). crt0: no /usr/lib/ld.so 226 ASCII Transfer complete. 25 bytes received in 0.06 seconds (.41 Kbytes/s) ftp> It would appear that the problem is that /bin/ls is a dynamically linked executable. Other commands appear to work fine; I created a directory /usr/spool/ftp/pub and place a few files in there which can all be accessed using the 'get' command. I tried placing a copy of 'ld.so' in /usr/spool/ftp/usr/lib/ld.so but ftp complained with: 150 ASCII data connection for /bin/ls (XXX.YYY.200.6,1534). crt0: no /dev/zero 226 ASCII Transfer complete. My initial use for anon. ftp is to allow other machines to copy certain files from my machine on a nightly basis; So any batch scripts which I create will work fine. Does anyone know what further steps I must take to allow users to log in to ftp and browse through the files I am exporting using the 'ls' command. Is their a version of 'ls' somewhere in the SunOS filesystem which is not dynamically linked ?! Any comments or suggestions would be appreciated. Thanks, Crawford Macnab ( tjcm@stl.stc.co.uk +44-279-29531 Ext 2153 )