<HTML><BODY><div>In my opinion it is not correct. So the remote party sends me 400 Bad Content-lenth in response to my outgoing INVITE. That's why I'm asking this question. How to make this header only one. And why does opensips do this?<br>
<br>
 
<blockquote style="border-left:1px solid #0857A6; margin:10px; padding:0 0 0 10px;">Пятница, 8 ноября 2019, 11:13 +03:00 от Alain Bieuzent <alain.bieuzent@free.fr>:<br>
 
<div id="">
<div class="js-helper js-readmsg-msg">
<style type="text/css">
</style>
<div>
<div id="style_15732008281462436001_BODY">
<div class="class_1573210871">
<div class="WordSection1_mailru_css_attribute_postfix">
<p class="MsoNormal_mailru_css_attribute_postfix"><span lang="EN-US" style="mso-fareast-language:EN-US">Hi Oleg,</span></p>

<p class="MsoNormal_mailru_css_attribute_postfix"><span lang="EN-US" style="mso-fareast-language:EN-US"> </span></p>

<p class="MsoNormal_mailru_css_attribute_postfix"><span lang="EN-US" style="mso-fareast-language:EN-US">Is it normal your outgoing INVITE have twice « </span><span lang="EN-US" style="color:black">Content-Length: 205 » ?</span></p>

<p class="MsoNormal_mailru_css_attribute_postfix"><span lang="EN-US" style="color:black"> </span></p>

<p class="MsoNormal_mailru_css_attribute_postfix"><span lang="EN-US" style="color:black">Regards</span></p>

<p class="MsoNormal_mailru_css_attribute_postfix"><span style="mso-fareast-language:EN-US"> </span></p>

<div class="mail-quote-collapse">
<div data-quote-id="1689221041678983201" data-type="body">
<div style="border-top:solid #b5c4df 1.0pt; border:none; padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal_mailru_css_attribute_postfix"><b><span style="font-size:12.0pt;color:black">De : </span></b><span style="font-size:12.0pt;color:black">Users <<a href="/compose?To=users%2dbounces@lists.opensips.org">users-bounces@lists.opensips.org</a>> au nom de Oleg Podguyko via Users <<a href="/compose?To=users@lists.opensips.org">users@lists.opensips.org</a>><br>
<b>Répondre à : </b>Oleg Podguyko <<a href="/compose?To=podguiko@mail.ru">podguiko@mail.ru</a>>, OpenSIPS users mailling list <<a href="/compose?To=users@lists.opensips.org">users@lists.opensips.org</a>><br>
<b>Date : </b>jeudi 7 novembre 2019 à 19:16<br>
<b>À : </b><<a href="/compose?To=users@lists.opensips.org">users@lists.opensips.org</a>><br>
<b>Objet : </b>[OpenSIPS-Users] Opensips generate two Content-lenth headers</span></p>
</div>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix"> </p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix">I’m using opensips as proxy. I got INVITE from one side, do some logics ,remove ISUP body and send INVITE to destination via dispatcher module.</p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix">And I see that outgoing INVITE has two content-lenth headers. Remote side after received such INVITE sends 400 </p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix">Bad Contenth-lenth header.</p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix"> </p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix"> </p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix"> </p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix">Incoming INVITE:</p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix"> </p>
</div>

<div>
<div>
<p class="MsoNormal_mailru_css_attribute_postfix">INVITE sip:9222992040@10.66.107.169;transport=sctp;user=phone SIP/2.0<br>
Via: SIP/2.0/SCTP 10.111.18.3:7010;branch=z9hG4bKiz5cvz9x5v5zi4bg84g4vx4zs;X-DispMsg=1408<br>
Route: <sip:10.66.107.169:5060;transport=sctp;lr><br>
Call-ID: <a href="/compose?To=i44czbcvax4gabcdst4iavdbaisji94s@10.18.5.64">i44czbcvax4gabcdst4iavdbaisji94s@10.18.5.64</a><br>
From: "9269918424"<sip:9269918424@10.111.18.3;transport=sctp;user=phone>;tag=i4z5545v-CC-1027-TRC-613805-OFC-14<br>
To: "9222992040"<sip:9222992040@10.66.107.169;transport=sctp;user=phone><br>
CSeq: 1 INVITE<br>
P-Access-Network-Info: GEN-ACCESS;"area-number=<span class="js-phone-number">+79262000601</span>"<br>
Max-Forwards: 70<br>
Contact: <sip:10.111.18.3:7010><br>
Allow: INVITE,ACK,OPTIONS,BYE,CANCEL,INFO,PRACK,NOTIFY,MESSAGE,REFER,UPDATE<br>
P-Asserted-Identity: <tel:9269918424><br>
History-Info: <sip:9254462587@anonymous.invalid?reason=SIP%3Bcause%3D503%3Btext%3D%22Subscriber%20Not%20Reachable%22&Privacy=history>;index=1<br>
History-Info: <sip:9222992040@10.66.107.169:5060;transport=sctp>;index=1.1<br>
P-Early-Media: supported<br>
Supported: 100rel,timer,histinfo<br>
Min-SE: 90<br>
Session-Expires: 1800;refresher=uac<br>
Content-Length: 477<br>
Content-Type: multipart/mixed;boundary=ssboundary</p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix">--ssboundary<br>
Content-Length: 205<br>
Content-Type: application/sdp</p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix">v=0<br>
o=xyz 1154444372 1154444373 IN IP4 10.111.18.3<br>
s=SipCall<br>
c=IN IP4 10.249.66.133<br>
t=0 0<br>
m=audio 28644 RTP/AVP 8 116<br>
a=rtpmap:8 PCMA/8000<br>
a=rtpmap:116 telephone-event/8000<br>
a=ptime:20</p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix">--ssboundary<br>
Content-Length: 100<br>
Content-Type: application/isup;version=itu-t92+</p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix"> </p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix">)"<br>
)HB()EdRx1Z<br>
)EdRxa4}à§=?bñ£9<br>
1À4À?ÀoÀuÀ<br>
--ssboundary--</p>
</div>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix"> </p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix"> </p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix">Outgoing INVITE</p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix"> </p>
</div>

<div>
<div>
<p class="MsoNormal_mailru_css_attribute_postfix">INVITE sip:9222992040@10.66.107.169;transport=sctp;user=phone SIP/2.0<br>
Record-Route: <sip:192.168.9.84;r2=on;lr;did=876.0b9c196><br>
Record-Route: <sip:10.66.107.169;transport=sctp;r2=on;lr;did=876.0b9c196><br>
Via: SIP/2.0/UDP 192.168.9.84:5060;branch=z9hG4bKfa6a.b4f80a51.0<br>
Via: SIP/2.0/SCTP 10.111.18.3:7010;branch=z9hG4bKiz5cvz9x5v5zi4bg84g4vx4zs;X-DispMsg=1408<br>
Call-ID: <a href="/compose?To=i44czbcvax4gabcdst4iavdbaisji94s@10.18.5.64">i44czbcvax4gabcdst4iavdbaisji94s@10.18.5.64</a><br>
From: "9269918424"<sip:9269918424@10.111.18.3;transport=sctp;user=phone>;tag=i4z5545v-CC-1027-TRC-613805-OFC-14<br>
To: "9222992040"<sip:9222992040@10.66.107.169;transport=sctp;user=phone><br>
CSeq: 1 INVITE<br>
P-Access-Network-Info: GEN-ACCESS;"area-number=<span class="js-phone-number">+79262000601</span>"<br>
Max-Forwards: 69<br>
Contact: <sip:10.111.18.3:7010><br>
Allow: INVITE,ACK,OPTIONS,BYE,CANCEL,INFO,PRACK,NOTIFY,MESSAGE,REFER,UPDATE<br>
P-Asserted-Identity: <tel:9269918424><br>
History-Info: <sip:9254462587@anonymous.invalid?reason=SIP%3Bcause%3D503%3Btext%3D%22Subscriber%20Not%20Reachable%22&Privacy=history>;index=1<br>
History-Info: <sip:9222992040@10.66.107.169:5060;transport=sctp>;index=1.1<br>
P-Early-Media: supported<br>
Supported: 100rel,timer,histinfo<br>
Min-SE: 90<br>
Session-Expires: 1800;refresher=uac<br>
Content-Length: 205<br>
Content-Length: 205<br>
Content-Type: application/sdp<br>
v=0<br>
o=xyz 1154444372 1154444373 IN IP4 10.111.18.3<br>
s=SipCall<br>
c=IN IP4 10.249.66.133<br>
t=0 0<br>
m=audio 28644 RTP/AVP 8 116<br>
a=rtpmap:8 PCMA/8000<br>
a=rtpmap:116 telephone-event/8000<br>
a=ptime:20<br>
 </p>
</div>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix"> </p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix"> </p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix"> </p>
</div>

<div>
<p class="MsoNormal_mailru_css_attribute_postfix"> </p>
</div>

<div>
<div>
<div>
<p class="MsoNormal_mailru_css_attribute_postfix">--<br>
Oleg Podguyko</p>
</div>
</div>
</div>

<p class="MsoNormal_mailru_css_attribute_postfix">_______________________________________________ Users mailing list <a href="/compose?To=Users@lists.opensips.org">Users@lists.opensips.org</a> <a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a></p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</blockquote>
 

<div> </div>

<div data-signature-widget="container">
<div data-signature-widget="content">
<div>--<br>
Олег Подгуйко</div>
</div>
</div>

<div> </div>
</div>
</BODY></HTML>