Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request from GHSA-5rjf-prwh-pp7q
* api/v1/traces: validate inputs when enabling traces. validate the array of inputs when enabling multiple traces that they are strings. this patch also refactors out the allocation of said input name. Signed-off-by: Phillip Adair Stewart Whelan <[email protected]> * api/v1/traces: disable traces api when tracing is disabled. Signed-off-by: Phillip Adair Stewart Whelan <[email protected]> * api/v1/trace: use macros for strings and lengths in responses. avoid strlen when creating http response, especially in loops, by predefining them via macros. Signed-off-by: Phillip Whelan <[email protected]> * api/v1/trace: use sizeof for string length macros. Signed-off-by: Phillip Whelan <[email protected]> * api/v1/trace: use signed lenghts for strings. this avoid potential integer overflows when using them as specifiers for format strings. Signed-off-by: Phillip Whelan <[email protected]> * api/v1/traces: use macro for inputs string. Signed-off-by: Phillip Whelan <[email protected]> * api/v1/traces: use sizeof when comparing against base path. Signed-off-by: Phillip Whelan <[email protected]> * api/v1/traces: replace strlen with flb_sds_len when using flb_sds_t. Signed-off-by: Phillip Whelan <[email protected]> --------- Signed-off-by: Phillip Adair Stewart Whelan <[email protected]> Signed-off-by: Phillip Whelan <[email protected]>
- Loading branch information