[sr-dev] presentity active_watchers and uri parameters

Jasmin Schnatterbeck js at data-cmr.net
Wed Jan 7 18:46:59 CET 2015


Hi,

IMHO there is a bug in the active_watchers storage regarding the To and
From uri:

According to rfc3261 the from-uri and to-uri have to be identical (but
may swapped) for subsequent in-dialog-requests. [1],[2]
uri-parameters are part of uris. [3]

But uri-parameters are not stored in the active_watchers table when a
SUBSCRIBE request is processed - as a result, the uri parameters of
subsequent in-dialog NOTIFY-requests generated by presentity are
missing.

This does not only violate rfc3261, it also has severe consequences -
e.g. regarding the uac_replace_from() and uac_replace_to() functions,
which are used in a kamailio-node in front of the presentity-node.
In order to reconstruct the "old" uris of in-dialog requests, those
functions need the correct new uris - otherwise the reconstruction of
the old uris is messed up.

So I suggest to store to uri and from uri in active_watchers using one
column for the whole uri (including uri parameters). Or is there another
reason for the current situation (storing userpart and domain
separately)?

Cheers
Jasmin


[1] rfc3261 Section 12.1.1 [last sentence]

   The remote URI MUST be set to the URI in the From field, and the
   local URI MUST be set to the URI in the To field.


[2]  rfc3261 Section 12.2.1.1 

   The From URI of the
   request MUST be set to the local URI from the dialog state

[3] rfc3261

   SIP-URI          =  "sip:" [ userinfo ] hostport
                       uri-parameters [ headers ]

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 6769 bytes
Desc: not available
URL: <http://lists.sip-router.org/pipermail/sr-dev/attachments/20150107/8c59364e/attachment-0001.bin>


More information about the sr-dev mailing list