Greetings Greenbone Community,
I’m an OpenVAS User. I’m trying to use GVM_CLI to create tasks following the gvm-tools documentation.
As GVM_CLI needs to run as non-root user in Linux, I’ve installed it in the nonroot user account i’ve made. But while launching, it gives “bash:gvm-cli command not found”. I fixed it by installing the GVM_TOOLS in root account and then accessing it in the non-root account.
OpenVAS on the other hand was unable to be launched as a non-root user with sudo, it throws error ( E: Could not get lock /var/lib/dpkg/lock), because it was installed in the root account. So I removed it in the root account and installed in the nonroot account, then i could launch OpenVAS with sudo.
Now in the Non-root Account, instances of GVMCLI and OpenVAS are running, but GVM_CLI is unable to acquire Socket Permission for Openvassd.sock [ERROR13]
nonroot@kali:~$ gvm-cli socket --xml “<get_version/>”
Traceback (most recent call last):
File “/usr/local/bin/gvm-cli”, line 10, in
File “/home/nonroot/.local/lib/python3.7/site-packages/gvmtools/cli.py”, line 127, in main
with protocol_class(connection, transform=transform) as protocol:
File “/home/nonroot/.local/lib/python3.7/site-packages/gvm/protocols/gmp.py”, line 117, in enter
gmp = self.determine_supported_gmp()
File “/home/nonroot/.local/lib/python3.7/site-packages/gvm/protocols/gmp.py”, line 100, in determine_supported_gmp
version = self.determine_remote_gmp_version()
File “/home/nonroot/.local/lib/python3.7/site-packages/gvm/protocols/gmp.py”, line 83, in determine_remote_gmp_version
File “/home/nonroot/.local/lib/python3.7/site-packages/gvm/protocols/base.py”, line 107, in connect
File “/home/nonroot/.local/lib/python3.7/site-packages/gvm/connections.py”, line 355, in connect
) from None
gvm.errors.GvmError: Socket /var/run/openvasmd.sock does not exist