Package: openvas.omplib
Author:Hartmut Goebel <h.goebel@goebel-consult.de>Version:Version 0.1.0Copyright:GNU Public Licence v3 (GPLv3)Homepage:http://www.openvas.org/OpenVAS(Open Vulnerability Assessment System) is a network security
scanner with associated tools. OpenVAS Version 3 introduces a new core
component: The OpenVAS-Manager, a layer between OpenVAS-Scanner and
various client applications such as OpenVAS-Client or Greenbone
Security Assistant. Among other features, it adds server-side storage
of scan results and it makes it unnecessary for a scan client to keep
the connection open until the scan finishes.OpenVAS Management Protocol (OMP) is the protocol based on XML to talk
to the OpenVAS-Manager.openvas.omplibis a pure-Python
implementation of OMP which allows easy access to the OpenVAS-Manager.This package also includes a command line toolomp-clifor
interacting with openvas-manager. For easy of usage, this tool uses
sub-commands much like svn or openssl does.Example:manager = openvas.omplib.OMPClient(host=sensor)
manager.open(username, password)
manager.create_target(job_name, targets, comment)
task_id = manager.create_task(job_name, comment, config=config_name,
                              target=job_name)
report_id = manager.start_task(task_id)
# ... later ...
report = manager.get_report(report_id)
print etree.tostring(report)openvas.opmlibalso supports a low-level interface where you can send
OMP XML directly:help_text = manager.xml('<help/>')Examples foromp-cliusage:omp-cli --help             # get help
omp-cli get-report --help  # get help on subcommand get-report
omp-cli get-status         # list tasks with stati and report-ids

                           # Retreive a report in PDF format
omp-cli get-report -fPDF 343435d6-91b0-11de-9478-ffd71f4c6f30 \
                   -o some-report.pdfRequirements and Installationopenvas.omplibrequiresPython 2.5or higher with SSL support (which should be thedefault on most platforms) (NB: Python 3.x isnotsupported)setuptoolsfor installation (see below).argparse(already included in Python starting with Python 2.7)Hints for installing on Windows:Following the links above you will
find .msi and .exe-installers. Simply install them and continue
withinstalling openvas.omplib.Hints for installing on GNU/Linux:Most current GNU/Linux distributions
provide packages for the requirements. Look for packages names likepython-setuptoolsandpython-argparse. Simply install them and
continue withinstalling openvas.omplib.Hint for installing on other platforms:Many vendors provide Python.
Please check your vendors software repository. Otherwise please
download Python 2.6 (or any higer version from the 2.x series) fromhttp://www.python.org/download/and follow the installation
instructions there.After installing Python, installsetuptools. You may want to
readMore Hints on Installing setuptoolsfirst.Using setuptools, compiling and installing the remaining
requirements is a piece of cake:# if the system has network access
easy_install argparse

# without network access download argparse
# from http://pypi.python.org/pypi/argparse and run
easy_install argparse-*.zipInstalling openvas.omplibWhen you are reading this you most probably already downloaded and
unpackedopenvas.omplib. Thus installing is as easy as running:python ./setup.py installOtherwise you may install directly using setuptools/easy_install. If
your system has network access installingopenvas.omplibis a
breeze:easy_install openvas.omplibWithout network access downloadopenvas.omplibfromhttp://pypi.python.org/pypi/openvas.ompliband run:easy_install openvas.omplib-*.tar.gzMore Hints on Installing setuptoolsopenvas.omplibuses setuptools for installation. Thus you need
eithernetwork access, so the install script will automatically download
and install setuptools if they are not already installedorthe correct version of setuptools preinstalled using theEasyInstall installation instructions. Those instructions also
have tips for dealing with firewalls as well as how to manually
download and install setuptools.Custom Installation Locationsopenvas.omplibis just a single script (aka Python program). So you can
copy it where ever you want (maybe fixing the first line). But it’s
easier to just use:# install to /usr/local/bin
python ./setup.py install --prefix /usr/local

# install to your Home directory (~/bin)
python ./setup.py install --home ~Please mind: This effects also the installation of argparse (and
setuptools) if they are not already installed.For more information about Custom Installation Locations please refer
to theCustom Installation Locations Instructionsbefore
installingopenvas.omplib.