summaryrefslogtreecommitdiffstats
path: root/sources
diff options
context:
space:
mode:
authorRoberto Hueso Gómez <rhueso@soleta.eu>2019-11-05 10:44:01 +0100
committerOpenGnSys Support Team <soporte-og@soleta.eu>2019-11-06 11:22:35 +0100
commit61059e1b2e66bf64098adac7f47e771739d48038 (patch)
tree6ccca307b45eb827405fa6a45623c2b2acba18e8 /sources
parentb403c7ae6cf1e2c423e8d26969d4dca201ebd93f (diff)
#915 Validate POST /shell/output REST API parameters
This patch ensures that all required parameters are sent in the request.
Diffstat (limited to 'sources')
-rw-r--r--sources/ogAdmServer.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/sources/ogAdmServer.cpp b/sources/ogAdmServer.cpp
index fb84355..5d17480 100644
--- a/sources/ogAdmServer.cpp
+++ b/sources/ogAdmServer.cpp
@@ -3729,6 +3729,9 @@ static int og_cmd_run_get(json_t *element, struct og_msg_params *params,
return err;
}
+ if (!og_msg_params_validate(params, OG_REST_PARAM_ADDR))
+ return -1;
+
array = json_array();
if (!array)
return -1;