<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=utf-8">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    Hi all, <br>
    <br>
    Im struggling with incoming calls to webrtc clients.<br>
    I am trying to change INVITE's SDP using rtpengine from RTP/AVP or
    RTP/SAVP to RTP/SAVPF towards my webrtc clients. This works well. <br>
    <br>
    But if I send INVITE with SDP that includes RTP/AVP and RTP/SAVP as
    well, rtpengine creates incorrect SDP. It includes twice m=audio
    RTP/SAVPF and my WebRTC client does not like this INVITE and
    forbiddeds it by 488 Not Acceptable Here.  <br>
    <br>
    Example of my incorrect INVITE :<br>
    <br>
    Content-Type: application/sdp<br>
    Content-Disposition: session<br>
    Content-Length: 1393<br>
    v=0<br>
    o=SBC 1464238673 1464238674 IN IP4 <MyPublicIP><br>
    s=SBC<br>
    c=IN IP4 <MyPublicIP><br>
    t=0 0<br>
    m=audio 30454 RTP/SAVPF 102 9 8 0 3 18<br>
    a=rtpmap:102 SILK/8000<br>
    a=fmtp:102 useinbandfec=1; usedtx=0<br>
    a=rtpmap:9 G722/8000<br>
    a=rtpmap:8 PCMA/8000<br>
    a=rtpmap:0 PCMU/8000<br>
    a=rtpmap:3 GSM/8000<br>
    a=rtpmap:18 G729/8000<br>
    a=ptime:20<br>
    a=sendrecv<br>
    a=rtcp:30455<br>
    a=crypto:1 AES_CM_128_HMAC_SHA1_80
    inline:5X2wgU83bIwrwkHSymjnw48SiMGa1n+eIl50yr99<br>
    a=setup:actpass<br>
    a=fingerprint:sha-1
    11:76:2D:2A:F7:0D:5A:23:9D:F6:0C:E7:4C:DF:1E:CB:BF:5D:76:88<br>
    a=ice-ufrag:iglHZqry<br>
    a=ice-pwd:eyVXbFNoviYYlu5uuRZlnixFwQ<br>
    a=candidate:cE0FGbXWIfwj6OGD 1 UDP 2130706431 <MyPublicIP>
    30454 typ host<br>
    a=candidate:cE0FGbXWIfwj6OGD 2 UDP 2130706430 <MyPublicIP>
    30455 typ host<br>
    m=audio 30484 RTP/SAVPF 102 9 8 0 3 18<br>
    a=rtpmap:102 SILK/8000<br>
    a=fmtp:102 useinbandfec=1; usedtx=0<br>
    a=rtpmap:9 G722/8000<br>
    a=rtpmap:8 PCMA/8000<br>
    a=rtpmap:0 PCMU/8000<br>
    a=rtpmap:3 GSM/8000<br>
    a=rtpmap:18 G729/8000<br>
    a=ptime:20<br>
    a=sendrecv<br>
    a=rtcp:30485<br>
    a=crypto:1 AES_CM_128_HMAC_SHA1_80
    inline:ozDJ3G/wmaYedQbcTafbhaTIt6raIJa6ugrLUC99<br>
    a=setup:actpass<br>
    a=fingerprint:sha-1
    11:76:2D:2A:F7:0D:5A:23:9D:F6:0C:E7:4C:DF:1E:CB:BF:5D:76:88<br>
    a=ice-ufrag:gM1viWqu<br>
    a=ice-pwd:zdS4tP1Mj4hLTe6huBWYrhtI1s<br>
    a=candidate:cE0FGbXWIfwj6OGD 1 UDP 2130706431 <MyPublicIP>
    30484 typ host<br>
    a=candidate:cE0FGbXWIfwj6OGD 2 UDP 2130706430 <MyPublicIP>
    30485 typ host<br>
    <br>
    <br>
    My setup  : <br>
    incoming call -> MediaServer (freeswitch) -> SIP &
    Websocket proxy (Kamailio + Rtpengine) -> webRTC clients<br>
    <br>
    <br>
    Is there anybody who could help me with this issue or explain me how
    to remove the second line of m=audio RTP/SAVPF ? <br>
    <br>
    <br>
    <div class="moz-signature">-- <br>
      <font style="font-family:'Tahoma', sans-serif; font-size: 9pt;
        color:#333;">
        Jan<font style="color:#999999; font-size:10pt;"><br>
        </font></font></div>
  </body>
</html>