#224 Field 'From' corrupted on HOLD

1.5.x
closed-invalid
modules (454)
2
2010-07-15
2009-11-27
No

1. On first invite we use uac_replace_from in SIP config
2. On reinvite (hold) we have corrupt outgoing message like this (look to 'From' field):
NVITE sip:tstsipusr1@10.2.60.226:55748;rinstance=538c1ccfc0cc50ca SIP/2.0.
Via: SIP/2.0/UDP 10.2.176.238:5161;branch=z9hG4bK3077.feabda46.0.
Via: SIP/2.0/UDP 10.2.176.238;branch=z9hG4bK3077.b001a9f7.0.
Via: SIP/2.0/UDP 10.2.60.226:31290;received=10.2.60.226;branch=z9hG4bK-d8754z-351d13144e767d31-1---d8754z-;rport=31290.
Max-Forwards: 68.
Route: <sip:10.2.176.238;lr;ftag=322a7b31>.
Contact: <sip:2174626949@10.2.60.226:31290>.
To: "tstsipusr1"<sip:tstsipusr1@yota.ru>;tag=69525808.
From: "2174626949"<sip:thedeath@yota.rusip:thedeath@yota.ru>;tag=322a7b31.
Call-ID: YzEyOTUzMjE4ZGJjMTkzYzgwZGE4OTkxMDA5YmNmNmU..
CSeq: 2 INVITE.
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE, SUBSCRIBE, INFO.
Content-Type: application/sdp.
User-Agent: eyeBeam release 1102q stamp 51814.
Content-Length: 281.
.
v=0.
o=- 6 3 IN IP4 10.2.176.238.
s=CounterPath eyeBeam 1.5.
c=IN IP4 10.2.176.238.
t=0 0.
m=audio 21704 RTP/AVP 107 0 8 18 101.
a=fmtp:18 annexb=yes.
a=fmtp:101 0-15.
a=rtpmap:107 BV32/16000.
a=rtpmap:18 G729/8000.
a=rtpmap:101 telephone-event/8000.
a=sendonly.
a=nortpproxy:yes.

function restore_from (uac module) was called twice:

#0 restore_from (msg=0x7df840, is_from=0x7fff1814d2bc) at from.c:423
#1 0x00002b1f969d9279 in rr_checker (msg=0x7df840, r_param=<value optimized out>, cb_param=0x0) at from.c:543
#2 0x00002b1f931f2f15 in run_rr_callbacks (req=0x7df840, rr_params=0x2b1f933f5ad0) at rr_cb.c:89
#3 0x00002b1f931ed212 in after_loose (_m=0x7df840, preloaded=0) at loose.c:874
#4 0x00002b1f931f0088 in loose_route (_m=0x7df840, _s1=<value optimized out>, _s2=<value optimized out>) at loose.c:910
#5 0x000000000040ddfc in do_action (a=0x774f10, msg=0x7df840) at action.c:962
#6 0x000000000041089e in run_action_list (a=<value optimized out>, msg=0x7df840) at action.c:139
#7 0x000000000045ed02 in eval_expr (e=0x774fe0, msg=0x7df840, val=0x0) at route.c:1189
#8 0x000000000045e725 in eval_expr (e=0x775028, msg=0x7df840, val=0x0) at route.c:1507
#9 0x000000000040cdef in do_action (a=0x7765a8, msg=0x7df840) at action.c:689
#10 0x000000000041089e in run_action_list (a=<value optimized out>, msg=0x7df840) at action.c:139
#11 0x0000000000410bf9 in run_top_route (a=0x773c90, msg=0x7df840) at action.c:119
#12 0x000000000044f56f in receive_msg (
buf=0x7420c0 "INVITE sip:andrey11@10.2.44.153:56867;rinstance=b7437acf90db9db6 SIP/2.0\r\nVia: SIP/2.0/UDP 10.2.176.223;branch=z9hG4bK97f5.58d94591.0\r\nVia: SIP/2.0/UDP 10.2.44.153:27905;received=10.2.44.153;branch=z9"..., len=1011, rcv_info=0x7fff1814e300) at receive.c:164
#13 0x000000000048f05e in udp_rcv_loop () at udp_server.c:449
#14 0x00000000004279be in main (argc=5, argv=0x7fff1814e508) at main.c:692

#0 restore_from (msg=0x7df840, is_from=0x7fff1814c31c) at from.c:423
#1 0x00002b1f969d9279 in rr_checker (msg=0x7df840, r_param=<value optimized out>, cb_param=0x0) at from.c:543
#2 0x00002b1f931f2f15 in run_rr_callbacks (req=0x7df840, rr_params=0x2b1f933f5ad0) at rr_cb.c:89
#3 0x00002b1f931ed212 in after_loose (_m=0x7df840, preloaded=0) at loose.c:874
#4 0x00002b1f931f0088 in loose_route (_m=0x7df840, _s1=<value optimized out>, _s2=<value optimized out>) at loose.c:910
#5 0x000000000040ddfc in do_action (a=0x790e98, msg=0x7df840) at action.c:962
#6 0x000000000041089e in run_action_list (a=<value optimized out>, msg=0x7df840) at action.c:139
#7 0x000000000045ed02 in eval_expr (e=0x790f68, msg=0x7df840, val=0x0) at route.c:1189
#8 0x000000000045e797 in eval_expr (e=0x791158, msg=0x7df840, val=0x0) at route.c:1490
#9 0x000000000045e797 in eval_expr (e=0x7913d8, msg=0x7df840, val=0x0) at route.c:1490
#10 0x000000000045e725 in eval_expr (e=0x791420, msg=0x7df840, val=0x0) at route.c:1507
#11 0x000000000040cdef in do_action (a=0x796380, msg=0x7df840) at action.c:689
#12 0x000000000041089e in run_action_list (a=<value optimized out>, msg=0x7df840) at action.c:139
#13 0x000000000040ec40 in do_action (a=0x796450, msg=0x7df840) at action.c:706
#14 0x000000000041089e in run_action_list (a=<value optimized out>, msg=0x7df840) at action.c:139
#15 0x000000000040ebac in do_action (a=0x7764d8, msg=0x7df840) at action.c:119
#16 0x000000000041089e in run_action_list (a=<value optimized out>, msg=0x7df840) at action.c:139
#17 0x000000000040ec40 in do_action (a=0x7765a8, msg=0x7df840) at action.c:706
#18 0x000000000041089e in run_action_list (a=<value optimized out>, msg=0x7df840) at action.c:139
#19 0x0000000000410bf9 in run_top_route (a=0x773c90, msg=0x7df840) at action.c:119
#20 0x000000000044f56f in receive_msg (
buf=0x7420c0 "INVITE sip:andrey11@10.2.44.153:56867;rinstance=b7437acf90db9db6 SIP/2.0\r\nVia: SIP/2.0/UDP 10.2.176.223;branch=z9hG4bK97f5.58d94591.0\r\nVia: SIP/2.0/UDP 10.2.44.153:27905;received=10.2.44.153;branch=z9"..., len=1011, rcv_info=0x7fff1814e300) at receive.c:164
#21 0x000000000048f05e in udp_rcv_loop () at udp_server.c:449
#22 0x00000000004279be in main (argc=5, argv=0x7fff1814e508) at main.c:692

I have a question:
1. How I can understand why?
2. Is it wrong configuration file or bug in source code?

Discussion

  • This situation reproduces when we have two loose_route() calls in SIP configuration. I think it is bug, because I can corrupt data just with using config.

     
    • assigned_to: nobody --> bogdan_iancu
    • status: open --> open-invalid
     
  • Hi Vladimir,

    First of all, you should call the restore function twice!!! this is the why you get the broken FROM. If you fix this (calling restore function only once) and you still get a broken INVITE, please post both the incoming and outgoing re-INVITE.

    Regards,
    Bogdan

     
  • Hi Vladimir,

    any update on this ? removing the double loose_route() fixed the problem ?

    Regards,
    bogdan

     
    • priority: 5 --> 2
     
    • status: open-invalid --> closed-invalid