in reply to Running Perl program w/root privs via cron

Another option.

The sudoers file allows you to specify that certain commands can be run by specific users as other users without a password. Scan its documentation for NOPASSWD for the syntax (unfortunately without any examples, nor do I have one handy).

This combines the advantages of the two solutions that you list.

  • Comment on Re: Running Perl program w/root privs via cron

Replies are listed 'Best First'.
Re: Re: Running Perl program w/root privs via cron
by virtualsue (Vicar) on Jun 09, 2002 at 11:03 UTC
    Thanks! This looks like a technique that will fit the situation very well. sudo is a swiss army setuid wrapper tool, and I should have read the sudoers man page after reading the sudo man page. This way, the code stays essentially the same, and we retain the excellent logging/auditing capabilities of sudo.