Anyone? I will try to describe my problem once more. I have default FS install. I enabled "renegotiate-codec-on-hold", "renegotiate-codec-on-reinvite" and "enable-3pcc" in internal profile. My dialplan is:

<include>
  <context name="default">

    <extension name="echo">
      <condition field="destination_number" expression="^.*$">
        <action application="answer"/>
        <action application="echo"/>
      </condition>
    </extension>

  </context>
</include>


I use the following sipp scenario https://pastebin.freeswitch.org/24629 with the following command:
sipp <ip>:<port>  -sf sipp_scenario.xml -m 1

And getting the following siptrace https://pastebin.freeswitch.org/24630

My question is: Is it possible to setup FS in such a way, that in the second "200 OK" it would send "a=sendrecv" instead of "a=recvonly"?

Thanks.

On Wed, Apr 6, 2016 at 6:16 PM, Станислав Запольский <stszap@gmail.com> wrote:
Hello. We are facing the following problem with our FS setup:

1. provider sends us INVITE with "a=sendonly" in SDP
2. FS picks up the call, playing ivr and replying with 200 and "a=recvonly" in SDP
3. provider sends Re-INVITE without SDP
4. FS replying 200 with already negotiated SDP (single codec and "a=recvonly")

Provider wants renegotiation of sdp on step 4, or a least "a=sendrecv" parameter. Is there a way to achieve this without source modification? We tried setting following profile parameters:
renegotiate-codec-on-hold=true
renegotiate-codec-on-reinvite=true
enable-3pcc=true
but no luck. The only solution we found was modifing sofia.c like this:
line 7374 - replace switch_core_media_gen_local_sdp(session, SDP_TYPE_RESPONSE, NULL, 0, NULL, 0); with switch_core_media_gen_local_sdp(session, SDP_TYPE_RESPONSE, NULL, 0, "sendrecv", 0);
line 7376 - replace nua_respond(tech_pvt->nh, SIP_200_OK, TAG_END()); with nua_respond(tech_pvt->nh, SIP_200_OK, SOATAG_USER_SDP_STR(tech_pvt->mparams.local_sdp_str), TAG_END());

Thanks.