Module: sip-router
Branch: master
Commit: 94f18a957484f5e9eada7402f64c8626a6863fa6
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=94f18a9…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: Fri Sep 5 15:11:57 2014 +0200
dialog: add option to increment cseq upon local authentication to next hop
- feature has to be enabled via module parameter track_cseq_updates
- it does it only for downstream direction (requests from caller and
callee, as it is the typical use case of calling via a provider, after
authenticating the caller locally, provider asks for another 'trunk'
authentication)
- diff of cseq value is stored in dialog var named 'cseq_diff',
therefore be sure it is not overwritten from config
---
modules/dialog/dialog.c | 6 +
modules/dialog/dlg_cseq.c | 324 +++++++++++++++++++++++++++++++++++++++++
modules/dialog/dlg_cseq.h | 30 ++++
modules/dialog/dlg_handlers.c | 41 +++++-
modules/dialog/dlg_handlers.h | 6 +
modules/dialog/dlg_hash.c | 2 +-
modules/dialog/dlg_hash.h | 3 +-
7 files changed, 404 insertions(+), 8 deletions(-)
Diff: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commitdiff;h=94f…
i tried mt_match mi command that was introduced in master. for some
reason, it does not match properly. here is an example.
# sip-proxy_ctl mi mt_list lp_out
MT:: TNAME=lp_out TPREFIX=+3587234567 TVALUE=20010
MT:: TNAME=lp_out TPREFIX=+3587234568 TVALUE=20010
# sip-proxy_ctl mi mt_match lp_out \+3587234567 2
error: 404 - Not found tvalue
i then changed LM_DBG to LM_INFO and got to syslog:
Sep 5 11:51:55 siika /usr/bin/sip-proxy[29498]: INFO: mtree [mtree_mod.c:1346]: mt_mi_match(): no prefix found in [lp_out] for [18446744073001818887]
i also tried with "+3587234567", '+3587234567' and even with 3587234567
and got always the same result and syslog output.
any idea what goes wrong?
-- juha
mtree README does not mention about return value of mt_match
function. however, code has this:
if(mt_match_prefix(msg, tr, &tomatch, mval)<0)
{
LM_DBG("no prefix found in [%.*s] for [%.*s]\n",
tname.len, tname.s,
tomatch.len, tomatch.s);
goto error;
}
lock_get( mt_lock );
mt_tree_refcnt--;
lock_release( mt_lock );
return 1;
error:
lock_get( mt_lock );
mt_tree_refcnt--;
lock_release( mt_lock );
return -1;
so it looks like mt_match would return 1 if match succeeded and -1 if
it did not.
however, this does not work if mode param has value 2, because in that
case result of mt_add_tvalues is returned:
if ((it->type==MT_TREE_SVAL) || (it->type==MT_TREE_IVAL)) {
if (mode == 2)
return mt_add_tvalues(msg, it, tomatch);
mt_add_values, in turn, always returns 0 in case there is no error.
would it be ok if i make mt_add_tvalues to return -1 if no match is
found? i could then also document the return value.
-- juha
THIS IS AN AUTOMATED MESSAGE, DO NOT REPLY.
A new Flyspray task has been opened. Details are below.
User who did this - Alekzander Spiridonov (alekz)
Attached to Project - sip-router
Summary - To tag parsing bug
Task Type - Bug Report
Category - Core
Status - Unconfirmed
Assigned To -
Operating System - All
Severity - Medium
Priority - Normal
Reported Version - Development
Due in Version - Undecided
Due Date - Undecided
Details - There is a bug in kamailio message parser\translator:
In case UAC sends request with the following To tag:
<code>To: <sip:user@sip.domain.com:5060>;tag=\r\n
Call-ID: 8a5d2c4a6b5d3c3d</code>
When kamailio tries to generate local reply it damages Call-ID header:
<code>To: <sip:user@sip.domain.com:5060>;tag=\r\n
09e8021774bf4b1f614ecd1c00e1a565.860cCall-ID: 8a5d2c4a6b5d3c3d\r\n</code>
Attached is a proposed patch to fix the issue.
One or more files have been attached.
More information can be found at the following URL:
http://sip-router.org/tracker/index.php?do=details&task_id=465
You are receiving this message because you have requested it from the Flyspray bugtracking system. If you did not expect this message or don't want to receive mails in future, you can change your notification settings at the URL shown above.