different ip in from as initial invite

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

different ip in from as initial invite

OpenSIPS - Users mailing list
Hi

first call flow.
1. Invite with FROM [hidden email]
2. 200 ok with FROM [hidden email]
3. ACK, FROM is like in initial invite
[hidden email]

Costumer is saying that he expects from like it was send in 200ok (not in inital invite, tag and CALLERID stays always the same) and we should confirm with ACK that has from same as in 200 ok from them.

Problem is that in my case opensips adds FROM from initial invite (ip 1.2.3.4, it should be 1.2.3.5). IN onreply route a can not use uac_change_from.


Can this be change and how?

thank you
miha

_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: different ip in from as initial invite

Liviu Chircu
On 28.01.2020 14:43, Miha via Users wrote:
Costumer is saying that he expects from like it was send in 200ok (not in inital invite, tag and CALLERID stays always the same) and we should confirm with ACK that has from same as in 200 ok from them.

Hi miha,

That is complete nonsense, RFC 3261 is on your side, section § 8.2.6.2:

   The From field of the response MUST equal the From header field of
   the request.  The Call-ID header field of the response MUST equal the
   Call-ID header field of the request.  The CSeq header field of the
   response MUST equal the CSeq field of the request.  The Via header
   field values in the response MUST equal the Via header field values
   in the request and MUST maintain the same ordering.

However, if you are really keen to help them out... maybe you could store their
200 OK From header in a $dlg_val, then fix the ACK's From header to use this val.

But how will you handle the From header for other sequential requests?  And if these
requests are initiated by the downstream side, you will have to change the To instead
of the From, as the UAC must swap them!  We are basically opening Pandora's Box by
doing down this route.  It's not impossible to get right, but it will take some work.

Regards,

-- 
Liviu Chircu
www.twitter.com/liviuchircu | www.opensips-solutions.com

OpenSIPS Summit, Amsterdam, May 2020
  www.opensips.org/events
OpenSIPS Bootcamp, Miami, March 2020
  www.opensips.org/training

_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: different ip in from as initial invite

OpenSIPS - Users mailing list
Liviu

thank you very much for your quick answer! I will try then to stick as it is as it is the right way. If there will be no other choise that maybe i try this.

thank you again!
miha

Liviu Chircu je 1/28/2020 ob 1:52 PM napisal:
On 28.01.2020 14:43, Miha via Users wrote:
Costumer is saying that he expects from like it was send in 200ok (not in inital invite, tag and CALLERID stays always the same) and we should confirm with ACK that has from same as in 200 ok from them.

Hi miha,

That is complete nonsense, RFC 3261 is on your side, section § 8.2.6.2:

   The From field of the response MUST equal the From header field of
   the request.  The Call-ID header field of the response MUST equal the
   Call-ID header field of the request.  The CSeq header field of the
   response MUST equal the CSeq field of the request.  The Via header
   field values in the response MUST equal the Via header field values
   in the request and MUST maintain the same ordering.

However, if you are really keen to help them out... maybe you could store their
200 OK From header in a $dlg_val, then fix the ACK's From header to use this val.

But how will you handle the From header for other sequential requests?  And if these
requests are initiated by the downstream side, you will have to change the To instead
of the From, as the UAC must swap them!  We are basically opening Pandora's Box by
doing down this route.  It's not impossible to get right, but it will take some work.

Regards,

-- 
Liviu Chircu
www.twitter.com/liviuchircu | www.opensips-solutions.com

OpenSIPS Summit, Amsterdam, May 2020
  www.opensips.org/events
OpenSIPS Bootcamp, Miami, March 2020
  www.opensips.org/training


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users