Restricted Shell

   

Korn Shell: Unix and Linux Programming Manual, Third Edition, The
By Anatole Olczak

Table of Contents
Chapter 7.  The Environment


This is a version of the shell that allows restricted access to Unix. Running under rsh is equivalent to ksh, except that the following is not allowed:

  • changing directories

  • setting the value of ENV, PATH, or SHELL variables

  • specifying path or command names containing /

  • redirecting output of a command with >, >|, <>, or >>

These restrictions apply only after the .profile and environment files have been processed.

Privileged Mode

Privileged mode allows execution of the environment and .profile files to be controlled. When enabled, the ~/.profile and environment files are not executed. Instead, /etc/suid_profile is read and executed.

The /etc/suid_profile file can be configured by the system administrator to control execution of setuid Korn shell scripts, track su invocations, set a default read only PATH, log commands, and more.

By default, privileged mode is disable, but is enabled whenever the real and effective user or group ids are not the same.


       
    Top
     



    Korn Shell. Unix and Linux Programming Manual, Third Edition
    Korn Shell. Unix and Linux Programming Manual, Third Edition
    ISBN: N/A
    EAN: N/A
    Year: 2000
    Pages: 177

    flylib.com © 2008-2017.
    If you may any questions please contact us: flylib@qtcs.net