#577 [dialog] Crash when receiving empry "Record-Route"

open
nobody
modules (357)
4
2009-05-28
2009-05-28
No

Kamailio 1.5 rev 5834.

I use 'dialog" module and "uac" module (this one to change From username).
Kamailio receives an INVITE, changes From (so addes a long "vsf" parameter to Record-Route) and forwards it to a gateway.
The gateway replies 183 and 200 containing a "Record-Route" with no value (empty).

Then Kamailio shows this error and crashes:

ERROR:core:print_rr_body: failed to parse RR
ERROR:dialog:populate_leg_info: failed to print route records
ERROR:dialog:dlg_onreply: could not add further info to the dialog
CRITICAL:core:receive_fd: EOF on 12
INFO:core:handle_sigs: child process 4505 exited by a signal 11
INFO:core:handle_sigs: core was not generated
INFO:core:handle_sigs: terminating due to SIGCHLD
INFO:core:sig_usr: signal 15 received

I attach the output of the coredump and also the SIP trace showing it.

Discussion

  • Coredump after response with empty Record-Route

     
  • SIP trace showin the issue and crash cause

     
  • Seems similar to what Alex Hermann reported in #2797928. I will check.

     
  • Note that the crash also occur with:
    modparam("dialog", "db_mode", 0)
    This is: without storing dialogs in database.

     
  • I did a fix for this particular case, can you test and see if is fine now? There is more code to review, though...

     
  • I'll try to check it ASAP. However, the system is in production so I must wait to soe night with no usage in order to test it.
    I'll comment here the result. Thanks a lot.