Here are some ways to accomplish this although there may be other methods to accomplish your goals with automation if you are a Python programmer and use python-gvm along with gvm-cli, part of the gvm-tools package.
You can create a custom scan configuration by cloning the Full and Fast scan config or the base scan config and then manually selecting the NVTs with the severity range you wish.
Again, you could write a custom script and use python-gvm to automate the process to modify a custom scan configuration, or use the method described in item #1 to limit NVTs to your desired scope.
There are so many factors that contribute to scan time. It’s really a combination of the target server(s) response, scanner host system resources, configuration settings, and perhaps other factors. Modification to the openvas.conf configuration file could help speed your scans. You can modify the max_hosts, optimize_test, time_between_request, open_sock_max_attempts and timeout_retry to optimize the scan config, lower the tested port range with port_range, and increase max_sysload to use more CPU power on the scanner host, but this will not account for a slow response from the target.
I can also add that limiting the port_range from the web-interface should reduce the scan time, but I’m not sure it that alone would achieve the increase you are looking for.
My best guess to optimize the scan would be run thin server and interact with openvas-scanner directly via the command line. That way, you can have more control.
thanks for this, this might guide me to right path
appreciated!
lastly just wanted to be clear, are there any gvm python library sources
not able to find proper documentation,
found only this: GMP v21.4 - python-gvm
i was trying to create a script to get all cves list and then from that use only high and crit ones, find nvt for those only and create new scan config, inspired from one of the post you posted!!
let me know what can be done would be more helpfull
issues i am facing:
not getting all cves list using get_cves
not able to properly parse xml, due to lack of doc
then nvt’s
for element in cve.iter():
if str(element.tag).__contains__("name") or str(element.tag).__contains__("severity") or str(element.tag).__contains__("creation_time"):
print(element.tag, element.text)