Skip to content

OpenVAS / GVM vulnerability scanning — deploy and triage

Standing up Greenbone Vulnerability Management, running authenticated scans against a fleet, and turning the CVE report into something operations can act on.

OpenVAS is the open-source vulnerability scanner inside the Greenbone Vulnerability Management (GVM) suite. It probes hosts and services against a vulnerability feed that ships tens of thousands of network vulnerability tests (NVTs). The hard part is not installing it — the Greenbone container stack does that. The hard part is feeding it credentials so the scan is authenticated (which finds 10x what an unauthenticated scan finds), and turning the CVE list into a triaged backlog rather than a wall of red text.

How to verify

If GVM is already deployed, check the state and the last scan:

sudo docker ps --filter name=gvmd --filter name=ospd --filter name=openvas
sudo docker exec -it gvmd gvmd --get-users
sudo docker exec -it gvmd gvmd --list-scanners
sudo docker logs --tail 30 gvmd 2>&1 | grep -iE 'sync|feed|task'
curl -k https://gvm.local:9392/ -o /dev/null -w '%{http_code}\n'

The Greenbone Community Edition runs as a 10+ container stack — gvmd, ospd-openvas, openvas-scanner, redis, postgres, gsa (the web UI), and helpers. The image tags are versioned together; mismatched versions cause silent feed failures.

What’s happening

GVM has three layers. The scanner (openvas-scanner) executes NVTs against target hosts. The manager (gvmd) stores tasks, schedules, credentials, and reports in a Postgres database, and exchanges OSP (Open Scanner Protocol) messages with the scanner. The web UI (gsa) is the operator-facing dashboard. The vulnerability feed is the NVT corpus — refreshed several times daily from Greenbone’s mirror.

An unauthenticated scan probes services on the network and infers what’s installed. An authenticated scan SSHes into the target (or uses SMB / SNMP) and reads the installed package list directly — turning a noisy “this might be vulnerable” into an exact “this is package X version Y, here is the CVE”. Authenticated scans are 5-10x faster, more accurate, and produce less noise. They cost you an SSH credential per target — manage them like any other privileged credential.

The feed sync is large (multi-gigabyte) and slow on first run. Pre-warm it before the first scan or you get an empty report.

The procedure

  1. Deploy the stack. The Greenbone community Docker Compose file is the path of least resistance: git clone https://github.com/greenbone/docker.git && cd docker && docker compose -f docker-compose.yml up -d.
  2. Wait for the feed sync. docker logs -f gvmd | grep -i 'sync'. The first sync can take 60+ minutes. Subsequent syncs are incremental.
  3. Create an admin user. docker exec -it gvmd gvmd --create-user=admin --password='<chosen-password>'. The password is hashed and stored in the gvmd database.
  4. Browse to the UI. https://<gvm-host>:9392/. Accept the self-signed cert (or terminate TLS at a reverse proxy with a real cert).
  5. Add SSH credentials for authenticated scans. UI → Configuration → Credentials → New → Username + password, or SSH key. The credential is stored encrypted in gvmd’s Postgres.
  6. Create a target. UI → Configuration → Targets → New. Define the IP range or hostnames, attach the credential. For Linux hosts, the SSH credential needs sudo for the package check NVTs to find vulnerable kernel packages.
  7. Run a task. UI → Scans → Tasks → New. Pick the “Full and very deep ultimate” scan config for a complete audit, or “Discovery” for first-time network mapping. Schedule recurring scans for production cadence (weekly is typical).
  8. Triage the report. UI → Scans → Reports. Filter by CVSS score (Critical/High first), then by “Solution available” — vulnerabilities with no fix are not actionable from a patching standpoint. Export the filtered list to CSV and feed into your ticket system.

Common pitfalls

  • A new install with no feed sync produces empty reports that look like “no vulnerabilities”. Confirm the feed status (UI → Administration → Feed Status) before trusting any scan output.
  • Authenticated scans against a host with sudo NOPASSWD are easy; with a password-required sudo, GVM cannot run the package checks. Use a scan-specific sudo rule: gvm-scan ALL=(root) NOPASSWD: /usr/bin/apt list --installed, /usr/bin/dpkg -l, /usr/bin/rpm -qa.
  • The “Full and very deep ultimate” scan policy includes safe-but-noisy checks that can crash old or fragile services (anything Java-based pre-2015 is suspect). Test against staging before sweeping production.
  • GVM stores PII when you scan internal hosts — usernames in process lists, hostnames in service banners. The PG database needs the same retention and access controls you apply to your other security data.
  • The community edition feed is rate-limited; large fleets get throttled. Greenbone Enterprise feed costs money but updates faster and includes additional NVTs.

In the engagements we run, vulnerability scans feed a backlog that the operations team works through with the patch cadence. The CVE-to-package-to-host correlation is part of Managed Operations — a scan that produces a report no one acts on is worse than no scan, because the report becomes the alibi.