diff options
author | Marco Bonetti <sid77@slackware.it> | 2010-05-13 01:00:11 +0200 |
---|---|---|
committer | David Somero <xgizzmo@slackbuilds.org> | 2010-05-13 01:00:11 +0200 |
commit | c910da288b3bfcfd11f263df747e89c2e3b6348e (patch) | |
tree | 943a3283e26b5c792724df6f243fb67009936bf1 | |
parent | 34ff4e11c654e7ea05dfd326228d424c0259537c (diff) |
network/openvas-scanner: Added to 13.0 repository
-rw-r--r-- | network/openvas-scanner/README | 30 | ||||
-rw-r--r-- | network/openvas-scanner/doinst.sh | 21 | ||||
-rw-r--r-- | network/openvas-scanner/openvas-scanner.SlackBuild | 102 | ||||
-rw-r--r-- | network/openvas-scanner/openvas-scanner.info | 10 | ||||
-rw-r--r-- | network/openvas-scanner/rc.openvassd | 29 | ||||
-rw-r--r-- | network/openvas-scanner/slack-desc | 19 |
6 files changed, 211 insertions, 0 deletions
diff --git a/network/openvas-scanner/README b/network/openvas-scanner/README new file mode 100644 index 0000000000000..d974f3e880bf2 --- /dev/null +++ b/network/openvas-scanner/README @@ -0,0 +1,30 @@ +OpenVAS stands for Open Vulnerability Assessment System and is a network +security scanner with associated tools like a graphical user front-end. The +core component is a server with a set of network vulnerability tests (NVTs) +to detect security problems in remote systems and applications. + +OpenVAS products are Free Software under GNU GPL and a fork of Nessus. + +This package provides the OpenVAS scanner. To build a complete OpenVAS scanner +installation, however, you have to compile and install the packages in the +following sequence: + 1. openvas-libraries + 2. openvas-scanner + 3. openvas-client + +The openvas-client GUI is needed to interact with the OpenVAS scanner, however +there are some new optional modules: + 1. openvas-scanner for storing and organizing scans on a central server in a + SQL database + 2. openvas-administrator for User-, Feed- and Settings-Management + 3. greenbone-security-assistant for a web-based Vulnerability Management + +Speaking of changes: the daemon changed its name from openvasd to openavassd +(notice the extra "s"), so the rc script is /etc/rc.d/rc.openavssd now. + +As a last note, keep in mind that this is a major version transition: the +older openvas-libnasl and openvas-plugins packages no longer exists, +openvas-server has been replaced by the openvas-scanner package and there are +the new optional modules. A straight upgradepkg (with removal of deprecated +packages) *SHOULD* work but also consider to backup your old configuration and +starting over from a fresh OpenVAS installation. diff --git a/network/openvas-scanner/doinst.sh b/network/openvas-scanner/doinst.sh new file mode 100644 index 0000000000000..77dd8c45f0aa2 --- /dev/null +++ b/network/openvas-scanner/doinst.sh @@ -0,0 +1,21 @@ +config() { + NEW="$1" + OLD="`dirname $NEW`/`basename $NEW .new`" + # If there's no config file by that name, mv it over: + if [ ! -r $OLD ]; then + mv $NEW $OLD + elif [ "`cat $OLD | md5sum`" = "`cat $NEW | md5sum`" ]; then # toss the redundant copy + rm $NEW + fi + # Otherwise, we leave the .new copy for the admin to consider... +} + +# Keep same perms on rc.openvassd.new: +if [ -e etc/rc.d/rc.openvassd ]; then + cp -a etc/rc.d/rc.openvassd etc/rc.d/rc.openvassd.new.incoming + cat etc/rc.d/rc.openvassd.new > etc/rc.d/rc.openvassd.new.incoming + mv etc/rc.d/rc.openvassd.new.incoming etc/rc.d/rc.openvassd.new +fi + +config etc/rc.d/rc.openvassd.new + diff --git a/network/openvas-scanner/openvas-scanner.SlackBuild b/network/openvas-scanner/openvas-scanner.SlackBuild new file mode 100644 index 0000000000000..1420f4ebccc78 --- /dev/null +++ b/network/openvas-scanner/openvas-scanner.SlackBuild @@ -0,0 +1,102 @@ +#!/bin/sh + +# Slackware build script for OpenVAS scanner. +# +# Copyright 2010-2011 Marco Bonetti <sid77@slackware.it> +# All rights reserved. +# +# Redistribution and use of this script, with or without modification, is +# permitted provided that the following conditions are met: +# +# 1. Redistributions of this script must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ''AS IS'' AND ANY EXPRESS OR IMPLIED +# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; +# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +PRGNAM=openvas-scanner +VERSION=${VERSION:-3.0.1} +ARCH=${ARCH:-i486} +BUILD=${BUILD:-1} +TAG=${TAG:-_SBo} + +CWD=$(pwd) +TMP=${TMP:-/tmp/SBo} +PKG=$TMP/package-$PRGNAM +OUTPUT=${OUTPUT:-/tmp} + +DOCS="CHANGES COPYING ChangeLog" + +if [ "$ARCH" = "i486" ]; then + SLKCFLAGS="-O2 -march=i486 -mtune=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "i686" ]; then + SLKCFLAGS="-O2 -march=i686 -mtune=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "x86_64" ]; then + SLKCFLAGS="-O2 -fPIC" + LIBDIRSUFFIX="64" +fi + +set -e + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT +cd $TMP +rm -rf $PRGNAM-$VERSION +tar xvf $CWD/$PRGNAM-$VERSION.tar.gz +cd $PRGNAM-$VERSION + +mkdir -p $PKG/etc/rc.d +cat $CWD/rc.openvassd > $PKG/etc/rc.d/rc.openvassd.new + +chown -R root:root . +find . \ + \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \ + -exec chmod 755 {} \; -o \ + \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ + -exec chmod 644 {} \; + +CFLAGS="$SLKCFLAGS" \ +CXXFLAGS="$SLKCFLAGS" \ +./configure \ + --prefix=/usr \ + --libdir=/usr/lib${LIBDIRSUFFIX} \ + --mandir=/usr/man \ + --sysconfdir=/etc \ + --localstatedir=/var \ + --build=$ARCH-slackware-linux + +make +make install DESTDIR=$PKG + +( cd $PKG + find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | \ + xargs strip --strip-unneeded 2> /dev/null || true + find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | \ + xargs strip --strip-unneeded 2> /dev/null +) + +( cd $PKG/usr/man + find . -type f -exec gzip -9 {} \; + for i in $( find . -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done +) + +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION +cp -a $DOCS $PKG/usr/doc/$PRGNAM-$VERSION +cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild + +mkdir -p $PKG/install +cat $CWD/slack-desc > $PKG/install/slack-desc +cat $CWD/doinst.sh > $PKG/install/doinst.sh + +cd $PKG +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz} diff --git a/network/openvas-scanner/openvas-scanner.info b/network/openvas-scanner/openvas-scanner.info new file mode 100644 index 0000000000000..8e9df92a5761c --- /dev/null +++ b/network/openvas-scanner/openvas-scanner.info @@ -0,0 +1,10 @@ +PRGNAM="openvas-scanner" +VERSION="3.0.1" +HOMEPAGE="http://www.openvas.org/" +DOWNLOAD="http://wald.intevation.org/frs/download.php/696/openvas-scanner-3.0.1.tar.gz" +DOWNLOAD_x86_64="" +MD5SUM="bc16660a65007a521b774e7eb474e89c" +MD5SUM_x86_64="" +MAINTAINER="Marco Bonetti" +EMAIL="sid77@slackware.it" +APPROVED="dsomero" diff --git a/network/openvas-scanner/rc.openvassd b/network/openvas-scanner/rc.openvassd new file mode 100644 index 0000000000000..4ae0183ccea18 --- /dev/null +++ b/network/openvas-scanner/rc.openvassd @@ -0,0 +1,29 @@ +#!/bin/sh + +PIDFILE="/var/run/openvassd.pid" + +start() { + echo "Starting OpenVAS scanner..." + openvassd +} + +stop() { + echo "Stopping OpenVAS scanner..." + kill `cat $PIDFILE` +} + +case "$1" in + start) + start + ;; + stop) + stop + ;; + restart) + stop + sleep 1 + start + ;; + *) + echo "Usage: $0 (start|stop|restart)" +esac diff --git a/network/openvas-scanner/slack-desc b/network/openvas-scanner/slack-desc new file mode 100644 index 0000000000000..e392f3e48eeaa --- /dev/null +++ b/network/openvas-scanner/slack-desc @@ -0,0 +1,19 @@ +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. Line +# up the first '|' above the ':' following the base package name, and the '|' +# on the right side marks the last column you can put a character in. You must +# make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':'. + + |-----handy-ruler------------------------------------------------------| +openvas-scanner: OpenVAS scanner (OpenVAS scanner) +openvas-scanner: +openvas-scanner: OpenVAS stands for Open Vulnerability Assessment System and is a +openvas-scanner: network security scanner with associated tools like a graphical user +openvas-scanner: front-end. The core component is a server with a set of network +openvas-scanner: vulnerability tests (NVTs) to detect security problems in remote +openvas-scanner: systems and applications. +openvas-scanner: +openvas-scanner: OpenVAS products are Free Software under GNU GPL and a fork of Nessus. +openvas-scanner: +openvas-scanner: This package provides the OpenVAS scanner. |