Ticket #467 (closed defect: fixed)

Opened 9 years ago

Last modified 9 years ago

RTP/AVP vs RTP/SAVP negotiation

Reported by: bennylp Owned by: nanang
Priority: major Milestone: release-0.9.0
Component: pjmedia Version: trunk
Keywords: Cc:
Backport to 1.x milestone: Backported:

Description (last modified by nanang) (diff)

Issues:

  1. Currently, when pjsip sends offer with RTP/AVP with a=crypto attribute (SRTP mode optional), and when remote answers with RTP/SAVP, SDP negotiation will fail and media will not be created, but the call is not terminated.
  2. When pjsip sends offer with RTP/SAVP (SRTP mode mandatory), and remote answers with RTP/AVP, SDP negotiation will fail and media will not be created, but the call is not terminated.

Attachments

ticket467.patch (2.5 KB) - added by nanang 9 years ago.
ticket467.2.patch (16.3 KB) - added by nanang 9 years ago.
ticket467.3.patch (536 bytes) - added by nanang 9 years ago.
Fixed call_disconnect() in pjsua_call.c, put SDP only if message type is response.

Change History

comment:1 Changed 9 years ago by nanang

  • Description modified (diff)

Changed 9 years ago by nanang

comment:2 Changed 9 years ago by nanang

Attachment ticket467.patch:

  • bug fixed in transport_srtp.c: in optional mode, it doesn't need to check media transport type
  • changed sdp_neg.c and session.c : disable offer-answer transport comparison when SRTP enabled, the transport SRTP will do the validation

comment:3 Changed 9 years ago by bennylp

  • Priority changed from normal to major

Changed 9 years ago by nanang

comment:4 Changed 9 years ago by nanang

Attachment ticket467.2.patch:

  • transport:
    • introduced new option for media/SDP handling in transport
    • added option param on media_create (affecting transport interface & all transport implementations, and transport user)
  • transport_srtp.c:
    • bug fix: in optional mode, it doesn't need to check media transport type
  • sdp_neg.c & session.c:
    • perform less strict media transport comparison (from strict pj_stricmp to pjmedia_sdp_transport_cmp)
  • pjmedia_call.c:
    • uncomment disconnect_call if status!=PJ_SUCCES on update media

comment:5 Changed 9 years ago by nanang

  • Status changed from new to assigned

comment:6 Changed 9 years ago by bennylp

  • Status changed from assigned to closed
  • Resolution set to fixed

Committed ticket467.2.patch in r1810 with minor modifications:

  • changed type of option parameter in media_create() from pjmedia_tranport_media_option to unsigned int, to allow bit mask combinations in the future.
  • Added doxygen documentation for the new option parameter.

Thanks.

comment:7 Changed 9 years ago by bennylp

  • Status changed from closed to reopened
  • Resolution fixed deleted

New issues reported by Klaus Darilion:

The BYE is sent before the ACK (from INV-200). I think this is valid but IMO it would be nicer if BYE is sent after ACK.

Unfortunately this is not easy to fix as the "bad" SDP is detected (and BYE is sent) upon receipt of 200/OK. Also sending ACK first will cause the call to go to CONFIRMED state, which may not be desired.

The BYE contains a session description

Yes this is a but. Ticket is reopened.

Thanks for the report.

Changed 9 years ago by nanang

Fixed call_disconnect() in pjsua_call.c, put SDP only if message type is response.

comment:8 Changed 9 years ago by bennylp

  • Status changed from reopened to closed
  • Resolution set to fixed

Patch ticket467.3.patch committed (don't send SDP with BYE)

Note: See TracTickets for help on using tickets.