About OpenVAS Manager
---------------------

The OpenVAS Manager is a layer between the OpenVAS Scanner and various
client applications such as the web client GSA (Greenbone Security
Assistant), the command line client omp (of openvas-cli) and the classic
application GSD (Greenbone Security Desktop).  Among other features, it
adds server-side storage of scan results and it removes the need for a scan
client to keep the connection open until the scan finishes.  All
communication between OpenVAS Manager and its clients is done via the
XML-based OpenVAS Management Protocol (OMP).

OpenVAS Manager is licensed under GNU General Public License Version 2 or
any later version.  Please see file COPYING for details.

All parts of OpenVAS Manager are Copyright (C) by Greenbone Networks GmbH
(see http://www.greenbone.net).


Howto use
---------

Note that the Manager always connects to the scanner as user "om" and
uses certificate based authentication exclusively.  This user is not
installed by the build process, so you must add the "om" user to the
scanner manually.  Please see the file INSTALL for instructions.

Note also that the Manager will always refuse to authenticate this special
"om" user, so you must add another user in order to connect to the Manager.

For example, if openvassd is running on port 9391, the following command
starts the Manager on port 9390.

    openvasmd

A command like

    openvasmd --update

or

    openvasmd --rebuild

will update the Manager's NVT cache, and then exit.  The cache must be
updated every time the Scanner syncs with the NVT feed.  The --rebuild
option is faster as it locks the database the entire time, whereas --update
allows clients to access the Manager during the update.

A rebuild within a running Manager can also be invoked by sending the main
Manager process the SIGHUP signal (signal number 1).

The program usage message follows.

    Usage:
      openvasmd [OPTION...] - OpenVAS security scanner manager

    Help Options:
      -?, --help                  Show help options

    Application Options:
      -d, --database=<file>       Use <file> as database.
      -f, --foreground            Run in foreground.
      -a, --listen=<address>      Listen on <address>.
      -m, --migrate               Migrate the database and exit.
      --otp                       Serve OTP too.
      -p, --port=<number>         Use port number <number>.
      --rebuild                   Rebuild the NVT cache and exit.
      -l, --slisten=<address>     Scanner (openvassd) address.
      -s, --sport=<number>        Scanner (openvassd) port number.
      -u, --update                Update the NVT cache and exit.
      -v, --verbose               Print progress messages.
      --version                   Print version and exit.

Testing
-------

There are some tests under src/tests.  To run them, start your openvasmd,
for example with

    openvasmd

then set the environment variables for the user and password

    export OPENVAS_TEST_USER=user_created_by_openvas-adduser
    export OPENVAS_TEST_PASSWORD=that_user's_password

and optionally for the host and/or port

    export OPENVAS_TEST_HOST=host.example.org
    export OPENVAS_TEST_PORT=9999

and then run all the tests

    make test

or any one of the tests, for example

    src/tests/omp_get_report_0

or, any test containing 'help' in its name

    ctest -R help
