Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix stop resume #1568

Merged
merged 3 commits into from
Jun 22, 2021
Merged

Conversation

ArnoStiefvater
Copy link
Member

@ArnoStiefvater ArnoStiefvater commented Jun 18, 2021

What:

Fix stop resume feature by sending the correct exclude list to ospd-openvas.

Why:

Fix bug.

How did you test it:

It can be reproduced with any scan which has multiple hosts and is stopped and resumed. The following only makes it a bit simpler to see in the openvas.log.

max_checks = 1
max_hosts = 1
scan config: only host_alive_detection.nasl (formally ping_host.nasl)
scan_alive_hosts_only = no
target: something like 192.168.56.10-110
exclude hosts: something like 192.168.56.10-20

Start task. Stop task after some percentage. Resume task. See in the openvas.log that all previously finished hosts are scanned again. The finished hosts are not taken into account at all. Its basically the same as starting the task again (not resuming).

For every hosts which is scanned again there are duplicate results in the report.

With the fix resume works as intended.

Checklist:

@ArnoStiefvater ArnoStiefvater requested a review from a team as a code owner June 18, 2021 09:51
@ArnoStiefvater ArnoStiefvater added backport-to-21.04 backport-to-main This pull request will be ported to the master branch labels Jun 18, 2021
Previously the wrong exlude host list was used
for the target which meant the stop-resume
feature was not working correctly.
The original exlude hosts were used instead of
the original plus the finished hosts.
@timopollmeier timopollmeier merged commit f4c3d55 into greenbone:gvmd-20.08 Jun 22, 2021
timopollmeier added a commit that referenced this pull request Jun 22, 2021
timopollmeier added a commit that referenced this pull request Jun 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport-to-main This pull request will be ported to the master branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants