Skip to content
Snippets Groups Projects
Commit d8830590 authored by Eric Vidal's avatar Eric Vidal :speech_balloon:
Browse files

deny external frontend service for any module directory

parent 271096f2
No related branches found
No related tags found
No related merge requests found
...@@ -274,9 +274,15 @@ void parse_module(resolve_service_t *res, resolve_service_t *ares, unsigned int ...@@ -274,9 +274,15 @@ void parse_module(resolve_service_t *res, resolve_service_t *ares, unsigned int
/** Search first inside the module directory. /** Search first inside the module directory.
* If not found, search in the entire system. */ * If not found, search in the entire system. */
if (!service_frontend_path(&sa, fname, info->owner, copy, exclude)) { if (!service_frontend_path(&sa, fname, info->owner, copy, exclude)) {
/** a module directory can contain the service in its activated/frontend
* directory. Module do not know anything about the system or about
* any other module.
*
* The frontend need to come from outside any module directory.*/
char const *inside[3] = { ebase, dirname, 0 } ; char const *exclude[3] = { SS_MODULE_ACTIVATED + 1, SS_MODULE_FRONTEND + 1, 0 } ;
if (!service_frontend_path(&sa, fname, info->owner, 0, inside))
if (!service_frontend_path(&sa, fname, info->owner, 0, exclude))
log_dieu(LOG_EXIT_USER, "find service frontend file of: ", fname) ; log_dieu(LOG_EXIT_USER, "find service frontend file of: ", fname) ;
out++; out++;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment