Module: sip-router
Branch: master
Commit: e040485765e1d456c14d45de2d2c85bfd5bc5903
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=e040485…
Author: Andrei Pelinescu-Onciul <andrei(a)iptel.org>
Committer: Andrei Pelinescu-Onciul <andrei(a)iptel.org>
Date: Tue Mar 2 17:41:37 2010 +0100
core: added missing parsed flags & minor get_hdr optimization
- parsed flags were not set for some headers (ACCEPTCONTACT,
ALLOWEVENTS, CONTENTENCODING, REFERREDBY, REJECTCONTACT,
REQUESTDISPOSITION, WWW_AUTHENTICATE, PROXY_AUTHENTICATE,
RETRY_AFTER).
- get_hdr() now checks first if the required header type was
parsed using the parsed flags. If it was not, it exists
immediately (it does not try to search through all the headers
anymore).
---
parser/msg_parser.c | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/parser/msg_parser.c b/parser/msg_parser.c
index 97378c7..a2a834e 100644
--- a/parser/msg_parser.c
+++ b/parser/msg_parser.c
@@ -364,7 +364,8 @@ int parse_headers(struct sip_msg* msg, hdr_flags_t flags, int next)
case HDR_WWW_AUTHENTICATE_T:
case HDR_PROXY_AUTHENTICATE_T:
case HDR_RETRY_AFTER_T:
- case HDR_OTHER_T: /*do nothing*/
+ case HDR_OTHER_T: /* mark the type as found/parsed*/
+ msg->parsed_flag|=HDR_T2F(hf->type);
break;
case HDR_CALLID_T:
if (msg->callid==0) msg->callid=hf;
@@ -830,9 +831,10 @@ struct hdr_field* get_hdr(struct sip_msg *msg, enum _hdr_types_t ht)
{
struct hdr_field *hdr;
- for(hdr = msg->headers; hdr; hdr = hdr->next) {
- if(hdr->type == ht) return hdr;
- }
+ if (msg->parsed_flag & HDR_T2F(ht))
+ for(hdr = msg->headers; hdr; hdr = hdr->next) {
+ if(hdr->type == ht) return hdr;
+ }
return NULL;
}
Module: sip-router
Branch: andrei/cancel_reason
Commit: 70d5b1b4c1bf4deb1dfed13679e9a76f15e9b923
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=70d5b1b…
Author: Andrei Pelinescu-Onciul <andrei(a)iptel.org>
Committer: Andrei Pelinescu-Onciul <andrei(a)iptel.org>
Date: Mon Mar 1 18:40:19 2010 +0100
tm: Reason header generation for local CANCELs
When cancel-ing branches due to final reply, 2xx or 6xx, add a
Reason header (according to RFC3326).
E.g.: Reason: SIP;cause=200
Internal implementation notes: the branch_bm_t/cancel_bitmap
parameter of many of the reply and cancel functions was replaced
with a bigger structure that contains all the information
associated with the cancel: the cancel branch bitmap, the reason
and reason text (optional) or the received cancel message (if
any).
Note that the current commit does not implement copying Reason
headers from a received CANCEL, it deals only with CANCEL
generated locally because of a final reply, 2xx or 6xx.
---
modules/tm/t_cancel.c | 47 +++++++++++--------
modules/tm/t_cancel.h | 7 ++-
modules/tm/t_fwd.c | 3 +-
modules/tm/t_msgbuilder.c | 113 ++++++++++++++++++++++++++++++++++++++++----
modules/tm/t_msgbuilder.h | 6 ++-
modules/tm/t_reply.c | 78 +++++++++++++++++--------------
modules/tm/t_reply.h | 37 ++++++++++++++-
modules/tm/timer.c | 8 ++--
8 files changed, 221 insertions(+), 78 deletions(-)
Diff: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commitdiff;h=70d…
Patches item #2826542, was opened at 2009-07-24 14:27
Message generated for change (Comment added) made by axlh
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=2826542&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: modules
Group: ver 1.5.x
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Alex Hermann (axlh)
Assigned to: Nobody/Anonymous (nobody)
Summary: Add id parameter to pua_mi's send_publish
Initial Comment:
When using presence with dialog-info, one needs to be able to specify an id, otherwise presentity from different calls for the same presentity-uri will overwrite each other. This patch makes it possible to specify an 'id' in the MI interface for send_publish. Unfortunately it breaks backward compatibility but it's the only way to use dialog-info with MI without having to manually store a the state of the ETag in the proxy.
----------------------------------------------------------------------
>Comment By: Alex Hermann (axlh)
Date: 2010-03-02 11:05
Message:
I don't think changing the API in a stable release is appropriate. So, no,
I didn't commit it to 1.5. It might apply to git master too, but I haven't
had time to use/evaluate SR yet and I don't feel comfortable with
committing without testing.
----------------------------------------------------------------------
Comment By: Daniel-Constantin Mierla (miconda)
Date: 2010-03-01 20:02
Message:
Just saw this one again. Alex, did you commit it?
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=2826542&group_…
Patches item #2961414, was opened at 2010-03-01 19:20
Message generated for change (Comment added) made by marcushunger
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=2961414&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: modules
Group: ver 1.5.x
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Nobody/Anonymous (nobody)
Assigned to: Nobody/Anonymous (nobody)
Summary: fix for crash when Content-length too big - ID: 281827
Initial Comment:
are there any valid use cases for a content-length being bigger than the rest of of the packet?
i have not tested the issue with kamailio 3.0.
----------------------------------------------------------------------
Comment By: Marcus Hunger (marcushunger)
Date: 2010-03-02 10:51
Message:
i retried this with vanilla-kamailio 1.5.4 downloaded from kamailio.org and
it crashs.
----------------------------------------------------------------------
Comment By: Marcus Hunger (marcushunger)
Date: 2010-03-01 20:11
Message:
so there's already a fix? i tried this on 1.5.4, and it crashed. maybe i
made a mistake merging it to my branch. i am going to check this tomorrow.
----------------------------------------------------------------------
Comment By: Daniel-Constantin Mierla (miconda)
Date: 2010-03-01 19:51
Message:
This should not happen, as both pairs (msg_buf,msg_len) and (body,body_len)
are set internally. The issue with the nathelper was because the len was
taken from content-lenght header, which can be wrong. The discussion ended
in whether to auto-correct the content-lenght value or return 400 bad
message. In 1.5 the fix to avoid crash was to return error to script, 400
can be sent by using sanity module.
----------------------------------------------------------------------
Comment By: Marcus Hunger (marcushunger)
Date: 2010-03-01 19:22
Message:
sorry, i was not logged in while posting.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=2961414&group_…
Patches item #2961414, was opened at 2010-03-01 19:20
Message generated for change (Comment added) made by marcushunger
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=2961414&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: modules
Group: ver 1.5.x
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Nobody/Anonymous (nobody)
Assigned to: Nobody/Anonymous (nobody)
Summary: fix for crash when Content-length too big - ID: 281827
Initial Comment:
are there any valid use cases for a content-length being bigger than the rest of of the packet?
i have not tested the issue with kamailio 3.0.
----------------------------------------------------------------------
Comment By: Marcus Hunger (marcushunger)
Date: 2010-03-01 20:11
Message:
so there's already a fix? i tried this on 1.5.4, and it crashed. maybe i
made a mistake merging it to my branch. i am going to check this tomorrow.
----------------------------------------------------------------------
Comment By: Daniel-Constantin Mierla (miconda)
Date: 2010-03-01 19:51
Message:
This should not happen, as both pairs (msg_buf,msg_len) and (body,body_len)
are set internally. The issue with the nathelper was because the len was
taken from content-lenght header, which can be wrong. The discussion ended
in whether to auto-correct the content-lenght value or return 400 bad
message. In 1.5 the fix to avoid crash was to return error to script, 400
can be sent by using sanity module.
----------------------------------------------------------------------
Comment By: Marcus Hunger (marcushunger)
Date: 2010-03-01 19:22
Message:
sorry, i was not logged in while posting.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=2961414&group_…
Patches item #2826542, was opened at 2009-07-24 15:27
Message generated for change (Comment added) made by miconda
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=2826542&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: modules
Group: ver 1.5.x
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Alex Hermann (axlh)
Assigned to: Nobody/Anonymous (nobody)
Summary: Add id parameter to pua_mi's send_publish
Initial Comment:
When using presence with dialog-info, one needs to be able to specify an id, otherwise presentity from different calls for the same presentity-uri will overwrite each other. This patch makes it possible to specify an 'id' in the MI interface for send_publish. Unfortunately it breaks backward compatibility but it's the only way to use dialog-info with MI without having to manually store a the state of the ETag in the proxy.
----------------------------------------------------------------------
>Comment By: Daniel-Constantin Mierla (miconda)
Date: 2010-03-01 21:02
Message:
Just saw this one again. Alex, did you commit it?
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=2826542&group_…
Hi All,
I have taken the ideas from sip-router/ser/kamailio-3.0.0 regarding the
XMLRPC management interface. I have used the ideas and incorporated them
into kamailio 1.5 and I was wondering how useful this would be giving back
to the community? If there is interest, what is the preferred way to
distribute (there are a few minor changes to the core - msg_translator and
receive)? I suppose a diff against the 1.5 svn would be the best?
The advantages over the existing XMLRPC interface:
1. multiple processes to serve xmlrpc requests. Effectively, we use the tcp
receive threads to process the xmlrpc calls.
2. no dependence on the Abyss server (this is a big plus for me) therefore,
better performance and smaller footprint.
ps. my motivation for this is that I had noticed performance issues and
memory leaks in the existing mi_xmlrpc module in Kamailio.
Cheers
Jason
Patches item #2961414, was opened at 2010-03-01 20:20
Message generated for change (Comment added) made by miconda
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=2961414&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: modules
Group: ver 1.5.x
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Nobody/Anonymous (nobody)
Assigned to: Nobody/Anonymous (nobody)
Summary: fix for crash when Content-length too big - ID: 281827
Initial Comment:
are there any valid use cases for a content-length being bigger than the rest of of the packet?
i have not tested the issue with kamailio 3.0.
----------------------------------------------------------------------
>Comment By: Daniel-Constantin Mierla (miconda)
Date: 2010-03-01 20:51
Message:
This should not happen, as both pairs (msg_buf,msg_len) and (body,body_len)
are set internally. The issue with the nathelper was because the len was
taken from content-lenght header, which can be wrong. The discussion ended
in whether to auto-correct the content-lenght value or return 400 bad
message. In 1.5 the fix to avoid crash was to return error to script, 400
can be sent by using sanity module.
----------------------------------------------------------------------
Comment By: Marcus Hunger (marcushunger)
Date: 2010-03-01 20:22
Message:
sorry, i was not logged in while posting.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=2961414&group_…
Patches item #2961414, was opened at 2010-03-01 19:20
Message generated for change (Comment added) made by marcushunger
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=2961414&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: modules
Group: ver 1.5.x
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Nobody/Anonymous (nobody)
Assigned to: Nobody/Anonymous (nobody)
Summary: fix for crash when Content-length too big - ID: 281827
Initial Comment:
are there any valid use cases for a content-length being bigger than the rest of of the packet?
i have not tested the issue with kamailio 3.0.
----------------------------------------------------------------------
Comment By: Marcus Hunger (marcushunger)
Date: 2010-03-01 19:22
Message:
sorry, i was not logged in while posting.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=2961414&group_…
Patches item #2961414, was opened at 2010-03-01 18:20
Message generated for change (Tracker Item Submitted) made by nobody
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=2961414&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: modules
Group: ver 1.5.x
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Nobody/Anonymous (nobody)
Assigned to: Nobody/Anonymous (nobody)
Summary: fix for crash when Content-length too big - ID: 281827
Initial Comment:
are there any valid use cases for a content-length being bigger than the rest of of the packet?
i have not tested the issue with kamailio 3.0.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=2961414&group_…