greenbone / openvas-scanner

This repository contains the scanner component for Greenbone Community Edition.
https://greenbone.github.io/docs/
GNU General Public License v2.0
3.37k stars 623 forks source link

Scan exits after one second and no result ouput #1468

Open iampilot opened 1 year ago

iampilot commented 1 year ago

Expected behavior Start a scan task,befor the task done, output result while the host is alive

Actual behavior Star a scan task, task become done quickly, maybe just spend no more than one minutes and no result ,but the target is alive. If I restart all the Greenbone Community Containers, the problem also can be solved. but sometime I restart the Greenbone Community Containers, the problem still exist

Steps to reproduce 1.Start Greenbone Community Containers and wait all the system server start

  1. create a task and start it
  2. Repeat the above steps several times

GVM versions docker images version: gsa:stable gvmd:stable ospd-openvas:stable

Environment redhat-7.9 + docker-compose-2.19.1

Logfiles `sd main:MESSAGE:2023-08-10 10h02.06 utc:141: openvas 22.7.2 started

sd main:MESSAGE:2023-08-10 10h02.06 utc:141: attack_network_init: INIT MQTT: SUCCESS

sd main:MESSAGE:2023-08-10 10h02.11 utc:141: Vulnerability scan a2951b15-469b-4479-abd4-ad5b61f2be33 started: Target has 1 hosts: 192.168.50.28, with max_hosts = 20 and max_checks = 4

libgvm boreas:MESSAGE:2023-08-10 10h02.11 utc:141: Alive scan a2951b15-469b-4479-abd4-ad5b61f2be33 started: Target has 1 hosts

sd main:MESSAGE:2023-08-10 10h02.12 utc:156: Vulnerability scan a2951b15-469b-4479-abd4-ad5b61f2be33 started for host: 192.168.50.28

libgvm boreas:MESSAGE:2023-08-10 10h02.12 utc:141: Alive scan a2951b15-469b-4479-abd4-ad5b61f2be33 finished in 1 seconds: 1 alive hosts of 1.

jjnicola commented 1 year ago

Hello @iampilot I was trying to reproduce this issue, but it was not possible for me. In any case, I would suggest to update the containers, since you are using a previous release. The current version for openvas is 22.7.3.

sd main:MESSAGE:2023-08-16 06h40.39 utc:5945: openvas 22.7.3 started

Also, it would be useful if you can pass the output of the command:

root@ospd-openvas:/ospd-openvas# openvas -V
OpenVAS 22.7.3
gvm-libs 22.4.1~dev1
Most new code since 2005: (C) 2022 Greenbone Networks GmbH
Nessus origin: (C) 2004 Renaud Deraison <deraison@nessus.org>
License GPLv2: GNU GPL version 2
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
jjnicola commented 1 year ago

Hello @iampilot where you able to update the containers and reproduce the issue?

iampilot commented 1 year ago

Hello @iampilot where you able to update the containers and reproduce the issue? sorry, so late to reply to you I try to fix the problem by update the openvas image version, but the problem still alive. Now I bulid GVM by source, It look like more stable, thanks for your help.