-
Notifications
You must be signed in to change notification settings - Fork 32
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
QACTL: Validate configuration file input parameters #1711
Comments
We have been discussing how are we going to validate the configuration file for QACTL. The best solution will be to add a validation phase in the qa-ctl tool that will use a validator tool, filtering problems like writing numbers in fields where a string is expected.
We are going to start by using the JSON schema solution because this will avoid an extra dependency (the JSON schema is already installed to check that FIM produces the events in a valid JSON format). If we encounter any problem, we will think about using Cerberus or another tool like it. |
@fernandolojano will continue with this issue development |
During the first approach in implementing the new function and checking it's proper functionality, a few issues were found in the JSON schema file used as validator.
After solving this problems and reviewing the validator function's code, It seems that the new implementation is working fine. However, in order to definitely confirm that the new script is working correctly, it is necessary to make a deep testing of all the possible error cases. We need to check and improve the json schema file configuration as well. |
Proven error case scenariosDeployment moduleVagrant scenario
Docker scenario
Provision moduleHost info section
Wazuh deployment section
QA framework section
Testing moduleHost info section
Test section
|
After an exhaustive study of most possible error cases for the validation function, it is safe to confirm that the function is working properly for the deployment and provisioning modules of the Some minor issues as new parameter inconsistencies between the schema file and the New modifications into the schema were added as well:
All this new additions can be seen and reviewed in this commit As a new requirement it was necessary to add a new field for the test module. This new field is similar to the actual |
qactl
tool receives a config file that contains all data parameters for deployment, provisioning, testing...It is necessary that before launching all these processes, the content and structure for this config file are validated.
It is requested to add a new initial stage in
qactl
that validates all input user parameters and their structure.Tasks
In order to achieve this new initial stage, several tasks need to be done:
jsonschema
documentationThe text was updated successfully, but these errors were encountered: