Solving nat for requests

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jan 13, 2009 at 1:55 AM, mayamatakeshi <mayamatakeshi at gmail.com>wrote:

> Hello, I'm testing my app written with pjsip/pjmedia and everything is
> working fine if NAT is not involved. In case of symmetrical NAT, I can see
> pjsip sends responses properly to the originating address. But after the
> call is answered, if I use pjsip_inv_send_msg to terminate the call, the BYE
> is sent to the address in the header Contact. How can I instruct pjsip to
> send the request (BYE, REINVITE etc) to the originating address of the call?
>
> I've tried to modify the dst fields from tdata.tp_info but it didn't work.


Hello, I partially solved this by changing the Contact header with the value
of the originating address/port in the on_rx_request:rdata before calling
pjsip_dlg_create_uas. This solved the problem in case a subsequent request
in the dialog is a BYE. But if the caller issues a reinvite for session
refresh/hold/unhold before pjsip sends the BYE message, then the remote
contact will be updated with the local address of the caller and the message
will be sent to that invalid address.
I think I can intercept the reinvite and change the Contact header again,
but this is becoming a little convoluted. Is there a simpler way to solve
this?

regards,
mayama
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20090113/359ac0e0/attachment.html>


[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux