No subject


Mon Aug 12 20:06:32 UTC 2013


-e  The -e (edit) option indicates that, instead of running a command,
    the user wishes to edit one or more files.  In lieu of a command,
    the string "sudoedit" is used when consulting the sudoers file.
    If the user is authorized by sudoers the following steps are
    taken:

    1.  Temporary copies are made of the files to be edited with the
        owner set to the invoking user.

    2.  The editor specified by the VISUAL or EDITOR environment vari-
        ables is run to edit the temporary files.  If neither VISUAL
        nor EDITOR are set, the program listed in the editor sudoers
        variable is used.

    3.  If they have been modified, the temporary files are copied
        back to their original location and the temporary versions are
        removed.

    If the specified file does not exist, it will be created.  Note
    that unlike most commands run by sudo, the editor is run with the
    invoking user's environment unmodified.  If, for some reason, sudo
    is unable to update a file with its edited version, the user will
    receive a warning and the edited copy will remain in a temporary

I've used sudoedit for restricted editing quite a bit, and had great
success with it.

> Dan

-- 
Christopher



More information about the OLUG mailing list