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

ospd.errors.RequiredArgument: set_redisctx: Argument ctx is required #155

Closed
morph027 opened this issue Nov 15, 2019 · 3 comments
Closed
Labels
feedback required Additional information is required

Comments

@morph027
Copy link

I was just testing the new ospd-openvas scanner and encounter the following errors when running a scan:

# ospd-openvas -f --log-level DEBUG
2019-11-15 09:05:17,837 OSPD - openvas: DEBUG: (ospd_openvas.daemon) Loading vts in memory.
2019-11-15 09:05:34,495 OSPD - openvas: DEBUG: (ospd_openvas.daemon) Finish loading up vts.
2019-11-15 09:05:44,575 OSPD - openvas: DEBUG: (ospd.server) New connection from /var/run/ospd/ospd.sock
2019-11-15 09:05:54,613 OSPD - openvas: DEBUG: (ospd.server) New connection from /var/run/ospd/ospd.sock
2019-11-15 09:06:04,652 OSPD - openvas: DEBUG: (ospd.server) New connection from /var/run/ospd/ospd.sock
2019-11-15 09:06:14,694 OSPD - openvas: DEBUG: (ospd.server) New connection from /var/run/ospd/ospd.sock
2019-11-15 09:06:37,020 OSPD - openvas: DEBUG: (ospd.server) New connection from /var/run/ospd/ospd.sock
2019-11-15 09:06:47,059 OSPD - openvas: DEBUG: (ospd.server) New connection from /var/run/ospd/ospd.sock
2019-11-15 09:07:08,526 OSPD - openvas: DEBUG: (ospd.server) New connection from /var/run/ospd/ospd.sock
2019-11-15 09:07:09,368 OSPD - openvas: DEBUG: (ospd.server) New connection from /var/run/ospd/ospd.sock
2019-11-15 09:07:19,524 OSPD - openvas: INFO: (ospd.ospd) b8c9f193-5966-4df2-b571-16221cc1c87b: Scan started.
2019-11-15 09:07:19,525 OSPD - openvas: INFO: (ospd.ospd) x.x.x.x: Host scan started on ports T:1-65535,U:1-65535.
2019-11-15 09:07:19,539 OSPD - openvas: ERROR: (ospd.ospd) While scanning x.x.x.x:
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/ospd/ospd.py", line 777, in parallel_scan
    ret = self.exec_scan(scan_id, target)
  File "/usr/lib/python3/dist-packages/ospd_openvas/daemon.py", line 1277, in exec_scan
    self.openvas_db.set_redisctx(ctx)
  File "/usr/lib/python3/dist-packages/ospd_openvas/db.py", line 133, in set_redisctx
    raise RequiredArgument('set_redisctx', 'ctx')
ospd.errors.RequiredArgument: set_redisctx: Argument ctx is required
2019-11-15 09:07:19,591 OSPD - openvas: DEBUG: (ospd.server) New connection from /var/run/ospd/ospd.sock
2019-11-15 09:07:21,534 OSPD - openvas: INFO: (ospd.ospd) b8c9f193-5966-4df2-b571-16221cc1c87b: Scan finished.
@jjnicola
Copy link
Member

Hi @morph027,
which gvm-libs, openvas, ospd, and ospd-openvas did you installed? It seems ospd can not find the nvticache in redis. Redis was flushed or you are mixing module versions. Could you give more information about the modules you installed?.

PR #151 prevents to start ospd-openvas if there is an unsupported nvticache version in redis (gvm-libs version).

@jjnicola jjnicola added the feedback required Additional information is required label Nov 15, 2019
@morph027
Copy link
Author

Okay. Is there a way to rebuild the cache?

gvm-libs: 11.0.0
openvas: 7.0.0
ospd-openvas: 1.0.0
python3-ospd:: 2.0.0

(Hint: not compiled from source, all packages are from unofficial PPA https://launchpad.net/~mrazavi/+archive/ubuntu/gvm)

@jjnicola
Copy link
Member

@morph027,
As you are not using our sources, I can't help too much here. Probably this bug was already fixed.
I suggest you to visit our community, where this topic is being talked about.

ArnoStiefvater pushed a commit to ArnoStiefvater/ospd-openvas that referenced this issue Oct 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feedback required Additional information is required
Projects
None yet
Development

No branches or pull requests

2 participants