diff --git a/debian/patches/series b/debian/patches/series index 7cce1699e..adf5472ba 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -59,6 +59,12 @@ upstream/limit_the_execution_of_dialplan_reload.patch upstream/tm-execute-TMCB_REQUEST_FWDED-cb-as-BRANCH_ROUTE-whe.patch upstream/cfgt-don-t-try-to-create-dir-if-it-already-exists.patch upstream/cfgt-fix-detection-of-jump-to-previous-previous-rout.patch +## backport from kamailio trunk (5.4) +upstream/cfgt-group-RPC-commands-using-module-name.patch +upstream/cfgt-add-docs-for-missing-RPC-commands.patch +upstream/cfgt-doc-add-missing-section.patch +upstream/cfgt-remove-dbg-from-RPC-commands.patch +upstream/cfgt-add-RPC-commands-cfgt.list-and-cfgt.clean.patch ### relevant for upstream sipwise/fix_error_in_cfgt_module.patch # diff --git a/debian/patches/sipwise/fix_error_in_cfgt_module.patch b/debian/patches/sipwise/fix_error_in_cfgt_module.patch index 48ce19e9a..9ae2900c7 100644 --- a/debian/patches/sipwise/fix_error_in_cfgt_module.patch +++ b/debian/patches/sipwise/fix_error_in_cfgt_module.patch @@ -4,14 +4,14 @@ Subject: fix_error_in_cfgt_module Change-Id: I5deab153a0c17117be1d2f4de8ca84f9134a5d00 --- - src/modules/cfgt/cfgt_int.c | 101 ++++++++++++++++++++++++++++++++++++++++---- - 1 file changed, 93 insertions(+), 8 deletions(-) + src/modules/cfgt/cfgt_int.c | 103 ++++++++++++++++++++++++++++++++++++++++---- + 1 file changed, 95 insertions(+), 8 deletions(-) diff --git a/src/modules/cfgt/cfgt_int.c b/src/modules/cfgt/cfgt_int.c -index 0e3bfec..971222f 100644 +index ec7107e..aa4f0dc 100644 --- a/src/modules/cfgt/cfgt_int.c +++ b/src/modules/cfgt/cfgt_int.c -@@ -29,6 +29,11 @@ +@@ -30,6 +30,11 @@ #include "../../core/pvar.h" #include "../../core/rpc.h" #include "../../core/rpc_lookup.h" @@ -23,15 +23,15 @@ index 0e3bfec..971222f 100644 #include "cfgt_int.h" #include "cfgt_json.h" -@@ -40,6 +45,7 @@ cfgt_hash_p _cfgt_uuid = NULL; +@@ -41,6 +46,7 @@ cfgt_hash_p _cfgt_uuid = NULL; str cfgt_hdr_prefix = {"NGCP%", 5}; str cfgt_basedir = {"/tmp", 4}; int cfgt_mask = CFGT_DP_ALL; +int not_sip = 0; - static int shm_str_hash_alloc(struct str_hash_table *ht, int size) - { -@@ -187,7 +193,7 @@ int _cfgt_get_hdr_helper(struct sip_msg *msg, str *res, int mode) + int _cfgt_get_filename(int msgid, str uuid, str *dest, int *dir); + +@@ -259,7 +265,7 @@ int _cfgt_get_hdr_helper(struct sip_msg *msg, str *res, int mode) return STR_EQ(tmp, *res); } } @@ -40,7 +40,7 @@ index 0e3bfec..971222f 100644 } int _cfgt_get_hdr(struct sip_msg *msg, str *res) -@@ -394,15 +400,21 @@ int _cfgt_set_dump(struct sip_msg *msg, cfgt_node_p node, str *flow) +@@ -466,15 +472,21 @@ int _cfgt_set_dump(struct sip_msg *msg, cfgt_node_p node, str *flow) if(node == NULL || flow == NULL) return -1; @@ -62,13 +62,13 @@ index 0e3bfec..971222f 100644 f = srjson_CreateObject(&node->jdoc); if(f == NULL) { LM_ERR("cannot create json object\n"); -@@ -531,6 +543,31 @@ int _cfgt_node_get_flowname(cfgt_str_list_p route, int *indx, str *dest) +@@ -620,6 +632,31 @@ int _cfgt_node_get_flowname(cfgt_str_list_p route, int *indx, str *dest) return 0; } +int _cfgt_parse_msg(sip_msg_t *msg) +{ -+ if (parse_msg(msg->buf, msg->len, msg) != 0) { ++ if(parse_msg(msg->buf, msg->len, msg) != 0) { + LM_ERR("outbuf buffer parsing failed!"); + return 1; + } @@ -94,7 +94,7 @@ index 0e3bfec..971222f 100644 int cfgt_process_route(struct sip_msg *msg, struct action *a) { str routename; -@@ -546,6 +583,10 @@ int cfgt_process_route(struct sip_msg *msg, struct action *a) +@@ -635,6 +672,10 @@ int cfgt_process_route(struct sip_msg *msg, struct action *a) return 0; } LM_DBG("route from action:[%s]\n", a->rname); @@ -105,7 +105,7 @@ index 0e3bfec..971222f 100644 routename.s = a->rname; routename.len = strlen(a->rname); switch(_cfgt_add_routename(_cfgt_node, a, &routename)) { -@@ -591,22 +632,35 @@ int cfgt_process_route(struct sip_msg *msg, struct action *a) +@@ -680,22 +721,35 @@ int cfgt_process_route(struct sip_msg *msg, struct action *a) /* TODO: @@ -143,7 +143,7 @@ index 0e3bfec..971222f 100644 _cfgt_node = cfgt_create_node(NULL); if(_cfgt_node) { jobj = srjson_CreateStr(&_cfgt_node->jdoc, buf->s, buf->len); -@@ -624,14 +678,23 @@ int cfgt_msgin(sr_event_param_t *evp) +@@ -713,14 +767,23 @@ int cfgt_msgin(sr_event_param_t *evp) int cfgt_pre(struct sip_msg *msg, unsigned int flags, void *bar) { str unknown = {"unknown", 7}; @@ -160,7 +160,7 @@ index 0e3bfec..971222f 100644 + if(get_hdr_result != 0 || _cfgt_node->uuid.len == 0) { + if(not_sip) { + LM_DBG("not_sip flag set, not a SIP message." -+ " Using 'unknown' uuid\n"); ++ " Using 'unknown' uuid\n"); + } else if(get_hdr_result == 2) { + LM_DBG("message not related to the cfgtest scenario." + " Using 'unknown' uuid\n"); @@ -171,18 +171,20 @@ index 0e3bfec..971222f 100644 pkg_str_dup(&_cfgt_node->uuid, &unknown); } return _cfgt_get_uuid_id(_cfgt_node); -@@ -661,7 +724,9 @@ int cfgt_post(struct sip_msg *msg, unsigned int flags, void *bar) +@@ -750,7 +813,11 @@ int cfgt_post(struct sip_msg *msg, unsigned int flags, void *bar) if(_cfgt_node) { LM_DBG("dump last flow\n"); - if(_cfgt_node_get_flowname(_cfgt_node->route, 0, &flowname) < 0) -+ if(_cfgt_node->route == NULL && strncmp(_cfgt_node->uuid.s, "unknown", 7) == 0) -+ LM_DBG("route is NULL and message doesn't belong to cfgtest scenario\n"); ++ if(_cfgt_node->route == NULL ++ && strncmp(_cfgt_node->uuid.s, "unknown", 7) == 0) ++ LM_DBG("route is NULL and message doesn't belong to cfgtest " ++ "scenario\n"); + else if(_cfgt_node_get_flowname(_cfgt_node->route, 0, &flowname) < 0) LM_ERR("cannot create flowname\n"); else _cfgt_set_dump(msg, _cfgt_node, &flowname); -@@ -675,11 +740,24 @@ int cfgt_post(struct sip_msg *msg, unsigned int flags, void *bar) +@@ -764,11 +831,24 @@ int cfgt_post(struct sip_msg *msg, unsigned int flags, void *bar) int cfgt_msgout(sr_event_param_t *evp) { srjson_t *jobj; @@ -207,7 +209,7 @@ index 0e3bfec..971222f 100644 if(_cfgt_node) { jobj = srjson_CreateStr(&_cfgt_node->jdoc, buf->s, buf->len); if(jobj == NULL) { -@@ -689,6 +767,13 @@ int cfgt_msgout(sr_event_param_t *evp) +@@ -778,6 +858,13 @@ int cfgt_msgout(sr_event_param_t *evp) srjson_AddItemToArray(&_cfgt_node->jdoc, _cfgt_node->out, jobj); return 0; } @@ -217,7 +219,7 @@ index 0e3bfec..971222f 100644 + LM_DBG("OPTIONS message internally generated, skip it\n"); + return 0; + } -+ ++ LM_ERR("node empty\n"); return -1; } diff --git a/debian/patches/upstream/cfgt-add-RPC-commands-cfgt.list-and-cfgt.clean.patch b/debian/patches/upstream/cfgt-add-RPC-commands-cfgt.list-and-cfgt.clean.patch new file mode 100644 index 000000000..b442cc320 --- /dev/null +++ b/debian/patches/upstream/cfgt-add-RPC-commands-cfgt.list-and-cfgt.clean.patch @@ -0,0 +1,306 @@ +From 9c478f04481ddab001eda8c7723ee12564b2f778 Mon Sep 17 00:00:00 2001 +From: Victor Seva +Date: Wed, 4 Dec 2019 11:46:00 +0100 +Subject: [PATCH] cfgt: add RPC commands 'cfgt.list' and 'cfgt.clean' + +fixes #574 +--- + src/modules/cfgt/cfgt_int.c | 148 +++++++++++++++++++++++++++- + src/modules/cfgt/doc/cfgt_admin.xml | 57 +++++++++++ + 2 files changed, 200 insertions(+), 5 deletions(-) + +diff --git a/src/modules/cfgt/cfgt_int.c b/src/modules/cfgt/cfgt_int.c +index 4e92938ae..7582bec61 100644 +--- a/src/modules/cfgt/cfgt_int.c ++++ b/src/modules/cfgt/cfgt_int.c +@@ -21,6 +21,7 @@ + */ + #include + #include ++#include + #include + #include + +@@ -41,6 +42,8 @@ str cfgt_hdr_prefix = {"NGCP%", 5}; + str cfgt_basedir = {"/tmp", 4}; + int cfgt_mask = CFGT_DP_ALL; + ++int _cfgt_get_filename(int msgid, str uuid, str *dest, int *dir); ++ + static int shm_str_hash_alloc(struct str_hash_table *ht, int size) + { + ht->table = shm_malloc(sizeof(struct str_hash_head) * size); +@@ -75,24 +78,89 @@ int _cfgt_pv_parse(str *param, pv_elem_p *elem) + return 0; + } + +-void _cfgt_remove_uuid(const str *uuid) ++void _cfgt_remove_report(const str *scen) ++{ ++ str dest = STR_NULL; ++ str filepath = STR_NULL; ++ int dir = 0; ++ int len; ++ struct stat sb; ++ DIR *folder = NULL; ++ struct dirent *next_file = NULL; ++ ++ if(_cfgt_get_filename(0, *scen, &dest, &dir) < 0) { ++ LM_ERR("can't build filename for uuid: %.*s\n", scen->len, scen->s); ++ return; ++ } ++ dest.s[dir] = '\0'; ++ ++ if(stat(dest.s, &sb) == 0 && S_ISDIR(sb.st_mode)) { ++ filepath.s = (char *)pkg_malloc(sizeof(char) * dest.len + 1); ++ if(filepath.s == NULL) { ++ PKG_MEM_ERROR; ++ goto end; ++ } ++ if((folder = opendir(dest.s)) == NULL) { ++ LM_ERR("can't open dir: %s", strerror(errno)); ++ goto end; ++ } ++ while((next_file = readdir(folder)) != NULL) { ++ len = strlen(next_file->d_name); ++ if(len <= 2) { ++ if(strncmp(next_file->d_name, "..", 2) == 0 ++ || strncmp(next_file->d_name, ".", 1) == 0) { ++ continue; ++ } ++ } ++ sprintf(filepath.s, "%s/%s", dest.s, next_file->d_name); ++ if(remove(filepath.s) < 0) { ++ LM_ERR("failed removing file: %s\n", strerror(errno)); ++ } else { ++ LM_DBG("removed report file: %s\n", filepath.s); ++ } ++ } ++ if(closedir(folder) < 0) { ++ LM_ERR("can't close dir: %s", strerror(errno)); ++ } ++ if(remove(dest.s) < 0) { ++ LM_ERR("failed removing dir: %s\n", strerror(errno)); ++ } else { ++ LM_DBG("removed report dir: %s\n", dest.s); ++ } ++ } else { ++ LM_DBG("dir %s not found\n", dest.s); ++ } ++ ++end: ++ if(filepath.s) ++ pkg_free(filepath.s); ++ if(dest.s) ++ pkg_free(dest.s); ++} ++ ++int _cfgt_remove_uuid(const str *uuid, int remove_report) + { + struct str_hash_head *head; + struct str_hash_entry *entry, *back; + int i; ++ int res = -1; + + if(_cfgt_uuid == NULL) +- return; ++ return res; + if(uuid) { + lock_get(&_cfgt_uuid->lock); + entry = str_hash_get(&_cfgt_uuid->hash, uuid->s, uuid->len); + if(entry) { + str_hash_del(entry); ++ if(remove_report) ++ _cfgt_remove_report(&entry->key); + shm_free(entry->key.s); + shm_free(entry); + LM_DBG("uuid[%.*s] removed from hash\n", uuid->len, uuid->s); +- } else ++ res = 0; ++ } else { + LM_DBG("uuid[%.*s] not found in hash\n", uuid->len, uuid->s); ++ } + lock_release(&_cfgt_uuid->lock); + } else { + lock_get(&_cfgt_uuid->lock); +@@ -100,16 +168,20 @@ void _cfgt_remove_uuid(const str *uuid) + head = _cfgt_uuid->hash.table + i; + clist_foreach_safe(head, entry, back, next) + { ++ str_hash_del(entry); ++ if(remove_report) ++ _cfgt_remove_report(&entry->key); + LM_DBG("uuid[%.*s] removed from hash\n", entry->key.len, + entry->key.s); +- str_hash_del(entry); + shm_free(entry->key.s); + shm_free(entry); + } +- lock_release(&_cfgt_uuid->lock); + } ++ lock_release(&_cfgt_uuid->lock); ++ res = 0; + LM_DBG("remove all uuids. done\n"); + } ++ return res; + } + + int _cfgt_get_uuid_id(cfgt_node_p node) +@@ -708,10 +780,53 @@ int cfgt_msgout(sr_event_param_t *evp) + return -1; + } + ++int _cfgt_clean(str *scen) ++{ ++ if(strncmp(scen->s, "all", 3) == 0) { ++ return _cfgt_remove_uuid(NULL, 1); ++ } ++ return _cfgt_remove_uuid(scen, 1); ++} ++ ++int _cfgt_list_uuids(rpc_t *rpc, void *ctx) ++{ ++ void *vh; ++ struct str_hash_head *head; ++ struct str_hash_entry *entry, *back; ++ int i; ++ ++ if(_cfgt_uuid == NULL) { ++ LM_DBG("no _cfgt_uuid\n"); ++ rpc->fault(ctx, 500, "Server error"); ++ return -1; ++ } ++ ++ ++ lock_get(&_cfgt_uuid->lock); ++ for(i = 0; i < CFGT_HASH_SIZE; i++) { ++ head = _cfgt_uuid->hash.table + i; ++ clist_foreach_safe(head, entry, back, next) ++ { ++ if(rpc->add(ctx, "{", &vh) < 0) { ++ rpc->fault(ctx, 500, "Server error"); ++ return -1; ++ } ++ rpc->struct_add(vh, "Sd", "uuid", &entry->key, "msgid", entry->u.n); ++ } ++ } ++ lock_release(&_cfgt_uuid->lock); ++ return 0; ++} ++ + /** + * + */ + static const char *cfgt_rpc_mask_doc[2] = {"Specify module mask", 0}; ++static const char *cfgt_rpc_list_doc[2] = { ++ "List scenarios currently in memory", 0}; ++static const char *cfgt_rpc_clean_doc[2] = { ++ "Clean scenario, 'all' to clean all scenarios in memory", 0}; ++ + + static void cfgt_rpc_mask(rpc_t *rpc, void *ctx) + { +@@ -725,9 +840,32 @@ static void cfgt_rpc_mask(rpc_t *rpc, void *ctx) + rpc->add(ctx, "s", "200 ok"); + } + ++static void cfgt_rpc_list(rpc_t *rpc, void *ctx) ++{ ++ if(_cfgt_list_uuids(rpc, ctx) >= 0) ++ rpc->add(ctx, "s", "200 ok"); ++} ++ ++static void cfgt_rpc_clean(rpc_t *rpc, void *ctx) ++{ ++ str scen = STR_NULL; ++ ++ if(rpc->scan(ctx, "S", &scen) != 1) { ++ rpc->fault(ctx, 500, "invalid parameters"); ++ return; ++ } ++ if(_cfgt_clean(&scen) != 0) { ++ rpc->fault(ctx, 500, "error in clean"); ++ return; ++ } ++ rpc->add(ctx, "s", "200 ok"); ++} ++ + /* clang-format off */ + rpc_export_t cfgt_rpc[] = { + {"cfgt.mask", cfgt_rpc_mask, cfgt_rpc_mask_doc, 0}, ++ {"cfgt.list", cfgt_rpc_list, cfgt_rpc_list_doc, 0}, ++ {"cfgt.clean", cfgt_rpc_clean, cfgt_rpc_clean_doc, 0}, + {0, 0, 0, 0} + }; + /* clang-format on */ +diff --git a/src/modules/cfgt/doc/cfgt_admin.xml b/src/modules/cfgt/doc/cfgt_admin.xml +index d96515d3d..2a2b158e5 100644 +--- a/src/modules/cfgt/doc/cfgt_admin.xml ++++ b/src/modules/cfgt/doc/cfgt_admin.xml +@@ -172,6 +172,63 @@ modparam("cfgt", "callid_prefix", "TEST-ID%") + ... + &sercmd; cfgt.mask 32 + ... ++ ++ ++ ++
++ ++ <function moreinfo="none">cfgt.list</function> ++ ++ ++ Lists reports info in memory. ++ ++ ++ Name: cfgt.list ++ ++ ++ Example: ++ ++ ++... ++&sercmd; cfgt.list ++{ ++ uuid: unknown ++ msgid: 2 ++} ++{ ++ uuid: whatever ++ msgid: 1 ++} ++200 ok ++... ++ ++
++ ++
++ ++ <function moreinfo="none">cfgt.clean</function> ++ ++ ++ Removes reports from disk and cleans info in memory. ++ ++ ++ Name: cfgt.clean ++ ++ Parameters: ++ ++ report : string value ++ use 'all' to clean any report ++ ++ ++ ++ Example: ++ ++ ++... ++&sercmd; cfgt.clean unknown ++... ++&sercmd; cfgt.clean all ++... + +
+ +-- +2.20.1 + diff --git a/debian/patches/upstream/cfgt-add-docs-for-missing-RPC-commands.patch b/debian/patches/upstream/cfgt-add-docs-for-missing-RPC-commands.patch new file mode 100644 index 000000000..d3429e556 --- /dev/null +++ b/debian/patches/upstream/cfgt-add-docs-for-missing-RPC-commands.patch @@ -0,0 +1,50 @@ +From 3b2225ba762291b825dd7dead92a4aaee676b637 Mon Sep 17 00:00:00 2001 +From: Victor Seva +Date: Tue, 3 Dec 2019 12:07:04 +0100 +Subject: [PATCH] cfgt: add docs for missing RPC commands + +--- + src/modules/cfgt/doc/cfgt_admin.xml | 27 +++++++++++++++++++++++++++ + 1 file changed, 27 insertions(+) + +diff --git a/src/modules/cfgt/doc/cfgt_admin.xml b/src/modules/cfgt/doc/cfgt_admin.xml +index 76fb76750..186055dbe 100644 +--- a/src/modules/cfgt/doc/cfgt_admin.xml ++++ b/src/modules/cfgt/doc/cfgt_admin.xml +@@ -147,6 +147,33 @@ modparam("cfgt", "callid_prefix", "TEST-ID%") + + + ++
++ RPC Commands ++
++ ++ <function moreinfo="none">dbg.cfgt.mask</function> ++ ++ ++ Sets mask module parameter. ++ ++ ++ Name: dbg.cfgt.mask ++ ++ Parameters: ++ ++ mask : int value ++ ++ ++ ++ Example: ++ ++ ++... ++# prototype: &sercmd; dbg.cfgt.mask 32 ++... ++ ++
++ +
+
+ Usage +-- +2.20.1 + diff --git a/debian/patches/upstream/cfgt-doc-add-missing-section.patch b/debian/patches/upstream/cfgt-doc-add-missing-section.patch new file mode 100644 index 000000000..3a54c7d9e --- /dev/null +++ b/debian/patches/upstream/cfgt-doc-add-missing-section.patch @@ -0,0 +1,33 @@ +From 14729d390ea42cbadeda707d9207e9fdfe4512d7 Mon Sep 17 00:00:00 2001 +From: Victor Seva +Date: Tue, 3 Dec 2019 12:46:44 +0100 +Subject: [PATCH] cfgt: [doc] add missing
+ +--- + src/modules/cfgt/doc/cfgt_admin.xml | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/src/modules/cfgt/doc/cfgt_admin.xml b/src/modules/cfgt/doc/cfgt_admin.xml +index 186055dbe..13c878c54 100644 +--- a/src/modules/cfgt/doc/cfgt_admin.xml ++++ b/src/modules/cfgt/doc/cfgt_admin.xml +@@ -147,6 +147,7 @@ modparam("cfgt", "callid_prefix", "TEST-ID%") + + + ++ +
+ RPC Commands +
+@@ -169,7 +170,7 @@ modparam("cfgt", "callid_prefix", "TEST-ID%") + + + ... +-# prototype: &sercmd; dbg.cfgt.mask 32 ++&sercmd; dbg.cfgt.mask 32 + ... + +
+-- +2.20.1 + diff --git a/debian/patches/upstream/cfgt-group-RPC-commands-using-module-name.patch b/debian/patches/upstream/cfgt-group-RPC-commands-using-module-name.patch new file mode 100644 index 000000000..d5108d560 --- /dev/null +++ b/debian/patches/upstream/cfgt-group-RPC-commands-using-module-name.patch @@ -0,0 +1,39 @@ +From 2cb4ca9c436f1e6e21a21b100f7a79a25e023865 Mon Sep 17 00:00:00 2001 +From: Victor Seva +Date: Tue, 3 Dec 2019 10:38:54 +0100 +Subject: [PATCH] cfgt: group RPC commands using module name + +--- + src/modules/cfgt/cfgt_int.c | 8 ++++++-- + 1 file changed, 6 insertions(+), 2 deletions(-) + +diff --git a/src/modules/cfgt/cfgt_int.c b/src/modules/cfgt/cfgt_int.c +index b8a6456fc..5d29fdb87 100644 +--- a/src/modules/cfgt/cfgt_int.c ++++ b/src/modules/cfgt/cfgt_int.c +@@ -328,7 +328,7 @@ void cfgt_save_node(cfgt_node_p node) + dest.s[dir] = '\0'; + LM_DBG("dir [%s]\n", dest.s); + if(stat(dest.s, &sb) == 0 && S_ISDIR(sb.st_mode)) { +- LM_DBG("dir [%s] already existing\n", dest.s); ++ LM_DBG("dir [%s] already exists\n", dest.s); + } else if(mkdir(dest.s, S_IRWXO | S_IXGRP | S_IRWXU) < 0) { + LM_ERR("failed to make directory: %s\n", strerror(errno)); + return; +@@ -725,8 +725,12 @@ static void cfgt_rpc_mask(rpc_t *rpc, void *ctx) + rpc->add(ctx, "s", "200 ok"); + } + ++/* clang-format off */ + rpc_export_t cfgt_rpc[] = { +- {"dbg.mask", cfgt_rpc_mask, cfgt_rpc_mask_doc, 0}, {0, 0, 0, 0}}; ++ {"dbg.cfgt.mask", cfgt_rpc_mask, cfgt_rpc_mask_doc, 0}, ++ {0, 0, 0, 0} ++}; ++/* clang-format on */ + + int cfgt_init(void) + { +-- +2.20.1 + diff --git a/debian/patches/upstream/cfgt-remove-dbg-from-RPC-commands.patch b/debian/patches/upstream/cfgt-remove-dbg-from-RPC-commands.patch new file mode 100644 index 000000000..d56389d48 --- /dev/null +++ b/debian/patches/upstream/cfgt-remove-dbg-from-RPC-commands.patch @@ -0,0 +1,55 @@ +From 93030e5ce1bf7d64f2cacd1a1ca1d3c20e901f44 Mon Sep 17 00:00:00 2001 +From: Victor Seva +Date: Tue, 3 Dec 2019 13:40:14 +0100 +Subject: [PATCH] cfgt: remove dbg from RPC commands + +--- + src/modules/cfgt/cfgt_int.c | 2 +- + src/modules/cfgt/doc/cfgt_admin.xml | 6 +++--- + 2 files changed, 4 insertions(+), 4 deletions(-) + +diff --git a/src/modules/cfgt/cfgt_int.c b/src/modules/cfgt/cfgt_int.c +index 5d29fdb87..4e92938ae 100644 +--- a/src/modules/cfgt/cfgt_int.c ++++ b/src/modules/cfgt/cfgt_int.c +@@ -727,7 +727,7 @@ static void cfgt_rpc_mask(rpc_t *rpc, void *ctx) + + /* clang-format off */ + rpc_export_t cfgt_rpc[] = { +- {"dbg.cfgt.mask", cfgt_rpc_mask, cfgt_rpc_mask_doc, 0}, ++ {"cfgt.mask", cfgt_rpc_mask, cfgt_rpc_mask_doc, 0}, + {0, 0, 0, 0} + }; + /* clang-format on */ +diff --git a/src/modules/cfgt/doc/cfgt_admin.xml b/src/modules/cfgt/doc/cfgt_admin.xml +index 13c878c54..d96515d3d 100644 +--- a/src/modules/cfgt/doc/cfgt_admin.xml ++++ b/src/modules/cfgt/doc/cfgt_admin.xml +@@ -152,13 +152,13 @@ modparam("cfgt", "callid_prefix", "TEST-ID%") + RPC Commands +
+ +- <function moreinfo="none">dbg.cfgt.mask</function> ++ <function moreinfo="none">cfgt.mask</function> + + + Sets mask module parameter. + + +- Name: dbg.cfgt.mask ++ Name: cfgt.mask + + Parameters: + +@@ -170,7 +170,7 @@ modparam("cfgt", "callid_prefix", "TEST-ID%") + + + ... +-&sercmd; dbg.cfgt.mask 32 ++&sercmd; cfgt.mask 32 + ... + +
+-- +2.20.1 +