Chapter 5. Restricting users 145
2. Link the necessary commands and programs in the reduced bin directory. For
example, give access to the ls and vi commands:
# ln -s /usr/bin/ls /usr/rbin/ls
# ln -s /usr/bin/vi /usr/rbin/vi
3. Add Rsh as a valid shell in /etc/security/login.cfg:
# vi /etc/security/login.cfg
4. Add /usr/bin/Rsh to the list of shells in the usw stanza:
usw:
shells =
/bin/sh,/bin/bsh,/bin/csh,/bin/ksh,/bin/tsh,/bin/ksh93,/usr/bin/sh,/usr/bin
/bsh,/usr/bin/csh,/usr/bin/ksh,/usr/bin/tsh,/usr/bin/ksh93,/usr/sbin/uucp/u
ucico,/usr/sbin/sliplogin,/usr/sbin/snapp,/usr/bin/Rsh
5. Add the restricted shell user:
# mkuser shell=”/usr/bin/Rsh” alex
6. Assign an initial password:
# passwd alex
7. Change the ownership of the users profile to root:
# chown ...