On 12/18/09 12:27 PM, Andrei Pelinescu-Onciul wrote:
On Dec 17, 2009 at 15:52, Juha Heinanenjh@tutpro.com wrote:
even if i call fix_nated_contact() when sr receives 200 ok to locally generated invite, it is still trying to send the ack to local address of the ua. looks like modifications done in reply_route to 200 ok are not visible to sr when it generates the ack.
andrei, can you confirm this? are there any means to solve this problem?
Yes, onreply_route modifications are not taken into account by tm. In fact final responses are processed by tm _before_ executing the onreply_route. The onreply_route changes will only appear in the forwarded reply.
Right now the only way to solve this without code changes is to add another hop (e.g. route the message once through localhost or another proxy and fix the contact there).
With coding changes I see 2 possible workarounds:
- add a param. for using the local INVITE dst. when generating the ACK
(instead of obeying the rfc) (easy)
Isn't the RFC requiring to send cancel and negative ack to the same destination as INVITE?
Cheers, Daniel
- add a t_reply_fake_contact() command for changing the contact seen by
tm and maybe modifiying fix_nated_contact() to use it.
Andrei
sr-dev mailing list sr-dev@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev