[OpenSIPS-Users] Beginner Needs Clarification: Destination URI always NULL?
Iñaki Baz Castillo
ibc at aliax.net
Sat Mar 28 12:51:44 CET 2009
El Viernes 27 Marzo 2009, Alan Frisch escribió:
> While I get the general concept of URI's, I am trying to discern exactly
> what a Destination URI is within the OpenSIPS world. This debug line has
> me a little confused:
A request has a Request-Line URI, and can also contain a Route header.
According to RFC 3261, ifa proxy routes a request it must inspect first the
Route header:
If the Route header points to the proxy itself, it's removed and the next
Route header is inspected. If there is a Route no pointing to the proxy
itself, then the request must be sent to that Route URI.
If there is no Route (after removing Route pointintg to the proxy), the the
request must be sent to the Request-Line URI.
But, of course, a proxy could decide to send the request to any other
destination, regardless of the Route(s) and RURI content.
If you set $du in OpenSIPS, you are *forcing* the destination of the request
(Route and RURI doesn't matter now).
But there are other cases in which $du is automatically sent by OpenSIPS:
- A user is registered behind NAT so when routing a request to him, OpenSIPS
sets the RURI according to the private address in the REGISTER contact from
this user, and sets the $du with the value of the *real* source address of the
REGISTER.
- There are also other cases in which $du is automatically added.
Hope it helps.
PD: Note that setting $du doesn't change the RURI. This is, OpenSIPS could
send a request with RURI:
sip:1234 at 1.2.3.4
to the address 1.2.3.5.
--
Iñaki Baz Castillo <ibc at aliax.net>
More information about the Users
mailing list