This plugin was generated by the OIA archetype and illustrates a way to connect the Greenbone OpenVAS vulnerability scanner to OpenNMS such that new nodes are automatically scanned. It relies on the REST gateway provided by Mixeway to connect the dots.
Build and install the plugin into your local Maven repository using:
mvn clean install
From the OpenNMS Karaf shell:
feature:repo-add mvn:com.opennms/karaf-features/1.0.0-SNAPSHOT/xml
feature:install opennms-plugins-scanvas
Update automatically:
bundle:watch *
Create a config file com.company.scanvas.cfg
containing the following properties:
url=https://openvas.example.com:8443/
keystore=/path/to/keystore.jks
password=keystorePassword
vasUsername=admin
vasPassword=adminpassword
Once installed, the plugin makes the following Karaf shell commands available:
- opennms-scanvas:stats - number of scans requested and failed requests
- opennms-scanvas:testvas - pings the REST gateway's /initialize endpoint
You can also access the REST endpoint mounted by the plugin at http://localhost:8980/opennms/rest/scanvas/ping