Hello,

while removing the preferences options related to
plugin upload (see http://www.openvas.org/openvas-cr-4.html)
I discovered the undocumented protocol command "HUP_FATHER".

See openvas-server/openvasd/ntp_11.c:

| if(!strcmp(input, "HUP_FATHER")) {
|   if(preferences_user_is_admin(globals, arg_get_value(globals,
|    "preferences")))
|     kill(getppid(), SIGHUP);
|     return 1;
|  }

Basically, this feature allows a user that is defined to be the admin
(this is identified via the user name specified in the global preferences
with default "admin") sends SIGHUP to the parent server process.
The server reacts on it by restarting openvasd.

I really wonder about this feature, because no use-case for it comes
to my mind. I guess its only purpose was to activate uploaded plugins.

BTW: The SIGHUP reaction appears broken to me. One the one hand
it changes PID and on the other hand it is not guaranteed that
the same program ist stated again (the binay openvasd may
have changed meanwhile). So far I've seen only daemon or server
processes that simply reread config and flush caches upon a SIGHUP.
But I am happy to learn I am wrong.

All in all I guess its part of the upload feature and I like to remove the
HUP_FATHER element. Any concerns? Thoughts?

Best

        Jan
-- 
Dr. Jan-Oliver Wagner                                   Intevation GmbH
Amtsgericht Osnabrück, HR B 18998             http://www.intevation.de/
Geschäftsführer: Frank Koormann, Bernhard Reiter, Dr. Jan-Oliver Wagner
_______________________________________________
Openvas-devel mailing list
[email protected]
http://lists.wald.intevation.org/mailman/listinfo/openvas-devel

Reply via email to