(Below is an extract of a perl script used once the latest tar file is pulled down. Yeah, it's a kluge, but it works...)
# kluge perl script to update signatures
# must be run as root
# goto directory where latest tarfile is
cd $NESSUS_HOME/all_plugins/
# Expand the tarfile and replace all current plugins
tar -xvzf all-2.0.tar.gz
mv *.nasl $NESSUS_HOME/plugins
mv *.inc $NESSUS_HOME/plugins
# reset the owner & group for all plugins
chown 0 $NESSUS_HOME/plugins/*.inc
chgrp 0 $NESSUS_HOME/plugins/*.inc
chown 0 $NESSUS_HOME/plugins/*.nasl
chgrp 0 $NESSUS_HOME/plugins/*.nasl
# (perl script to find Nessus PID) -
$mycmd = "ps -C nessusd -o pid=";
$myPid = `$mycmd 2>/dev/null`;
chop($myPid);
$myPid =~ s/ //g;
# restart the nessus daemond
kill -HUP $myPid
| Renaud Deraison <[EMAIL PROTECTED]>
Sent by: [EMAIL PROTECTED] 10/28/2003 09:44 AM |
|
On Tue, Oct 28, 2003 at 07:43:51AM -0700, Jay Jacobson wrote:
> > Hi, I want to run the script under another account... What do i have to
> > change to make it works?
> >
> > Chmod ??? /usr/local/sbin/nessus-update-plugins
> > Chmod ??? /usr/local/etc/nessus/nessusd.conf
> > Chmod ??? /usr/local/lib/nessus/plugins
> >
> > What more?
>
>
> You could 'chown -r user /usr/local/lib/nessus/plugins', but that would
> still not work because the script has to HUP the nessusd process which
> runs as root. There are compile-time flags to install Nessus as a non-root
> user, but I believe that is for development only and might break some
> things in production.
And in addition to that the script themselves check that the user is
indeed root.
