HP Visualize J282 IRIX to HP-UX Migration Guide - Page 61
ftp/bin/ls
View all HP Visualize J282 manuals
Add to My Manuals
Save this manual to your list of manuals |
Page 61 highlights
Configuring TCP/IP The login shell /dev/null is recommended, but not required, and the home directory can be anywhere, with exceptions as explained in the next step. 2. Create an FTP home directory: # mkdir /disk2/ftp 3. Change directory to the ftp home directory, and create the subdirectories used for FTP access: # cd /disk2/ftp # mkdir bin dev etc lib pub incoming 4. Copy the ls command from /sbin to ~ftp/bin: # cp /sbin/ls bin 5. Copy /etc/passwd and /etc/group to ~ftp/etc, and edit them to an acceptable minimum: # cp /etc/passwd /etc/group etc A good choice for the contents of ~ftp/etc/passwd might be: root:*:0:0:Super-User:/:/dev/null bin:*:2:2:System Tools Owner:/bin:/dev/null sys:*:4:0:System Activity Owner:/var/adm:/dev/null ftp:*:997:999:Anonymous FTP Account:/disk2/ftp:/dev/null A good choice for the contents of ~ftp/etc/group might be: sys:*:0: other::995: guest:*:998: 6. Add appropriate device and library files for anonymous FTP as follows: # /sbin/mknod dev/zero c 37 0 # cp /lib/libc.so.1 /lib/rld lib The dev/zero file helps zero out sensitive data; ~ftp/bin/ls requires the library files. 7. Set restrictive permissions on ~ftp/etc/passwd, ~ftp/etc/group and ~ftp/dev/zero: # chmod 444 etc/* dev/* 8. Make sure the bin, dev, etc, lib and ~ftp directories are owned by root, and the group (set to sys) has restricted write permission: # chown root.sys bin dev etc lib . # chmod 511 bin dev etc lib . In the chown command, the dot separates owner and group. 9. For the pub directory, set the owner to root, the group to sys, and activate global read and access permission: 56