Juha Heinanen schrieb:
IƱaki Baz Castillo writes:
> I would suggest to add a ";received=SOURCE_IP:SOURCE_PORT" to the
> Contact URI (not to the header). In this way the in-dialog requests
> from the caller/callee would look like:
>
> BYE
> sip:alice@PRIVATE_IP:PRIVATE_PORT;received=SOURCE_IP:SOURCE_PORT
> SIP/2.0
yes, thats better. RR solution would need double-RR to handle the situation.
inaki,
sound ok to me. if other people don't find any problems with this,
should we write a new version of fix_nated_contact that adds the param
to contact uri or just try to use existing scripting means (remove
contact hf, add a new modified one)?
There are already some related functions which maybe can be extended:
There is encode_contact and decode_contact. It has another use case- but
maybe could be extended (it would be good to have a function which can
do both, adding "received" and encoding, as having 2 functions mangling
contact will probably fail):
http://www.kamailio.org/docs/modules/1.5.x/siputils.html#id2511673
Regarding the RR solution. There is already half the work done in path
module:
http://www.kamailio.org/docs/modules/1.5.x/path#id2452987
regards
klaus
So SR could route based on this RURI parameter
and keep the original
Contact as RURI.
i haven't checked if it would be possible to do that in the script
(extract and remove received param from r-uri and set $du) or would a
new function need to be written for that too.
-- juha
_______________________________________________
sr-dev mailing list
sr-dev(a)lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev