Commit 8fcff19
committed
Fix: Stop and clean finished/running openvas process before resumming a scan
If Ospd-Openvas crashes during a scan, probably the scan will continue
running in background, leaving the kb in redis occupied.
After ospd-openvas is initialized, the task can be resumed.
In this case, the scan id of the task will be the same one as before,
and there will be two kbs for the old and the new tasks with the same scanid.
This patch ensure that there is no kb in redis in used with the same scan id,
and also it will stop the scan in case it is still running.
This first commit add a function to check for kbs with the given scan id.1 parent 0772e48 commit 8fcff19
1 file changed
+19
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
648 | 648 | | |
649 | 649 | | |
650 | 650 | | |
| 651 | + | |
| 652 | + | |
| 653 | + | |
| 654 | + | |
| 655 | + | |
| 656 | + | |
| 657 | + | |
| 658 | + | |
| 659 | + | |
| 660 | + | |
| 661 | + | |
| 662 | + | |
| 663 | + | |
| 664 | + | |
| 665 | + | |
| 666 | + | |
| 667 | + | |
| 668 | + | |
| 669 | + | |
651 | 670 | | |
652 | 671 | | |
653 | 672 | | |
| |||
0 commit comments