On 07.01.2014 16:54, Brian Davis wrote:
The other interesting issue in this case is that the 192.xx.xxx.xxx
address is not an RFC1918 address, but it is also not reachable from

I should have known that if it is an RFC1918 address, you would not have to mask it.

kamailio.   That is why I hoped kamailio would trigger NAT traversal
logic solely on the fact that the source and contact address are different.

Here is my very pragmatic approach for NAT traversal: Forget about nat_uac_test(). Just always force NAT traversal [1], as it does not harm if the users are not behind NAT. It may increase traffic on your media relay but reduces support calls from customers.

Probaly the elegant solutions would be to apply NAT traversal only for SIP and use SIP client with ICE support (and provide a turn relay).

regards
Klaus




[1] use add_contact_alias(), handle_ruri_alias() and fix_nated_register(). Do not use fix_nated_contact(). Further, apply NAT traversal only if the clients are directly "connected" to your proxy (not if there are other devices inbetween).



On Tue, Jan 7, 2014 at 5:01 AM, Klaus Darilion
<klaus.mailingli...@pernau.at <mailto:klaus.mailingli...@pernau.at>> wrote:


    On 03.01.2014 16:59, Brian Davis wrote:
    REGISTER sip:test1.test.com:5060 <http://test1.test.com:5060> SIP/2.0
    Via: SIP/2.0/UDP
    
96.xxx.xxx.xxx:33745;rport;branch=z9hG4bKf5s1p`n3TRv5TZx5RXy.RVv+JPz8Nat*UX!8KRx4SRx

    Via: SIP/2.0/UDP
    
192.xx.xxx.xxx:33745;branch=z9hG4bKeb263246c44095f072d8167dd0c7987a343134;rport

    Contact: "Joe" <sip:xxxyyyz...@192.xx.xxx.xxx:33745;transport=udp>

    Dec 30 03:33:45 sip-01 kamailio[20489]: INFO: <script>:
    3b0400ca43e28f78f3e6dc945a084...@192.xx.xxx.xxx
    <mailto:3b0400ca43e28f78f3e6dc945a084...@192.xx.xxx.xxx>|log|source 
96.xxx.xxx.xxx:33745

    Actually the source IP seem to be identical to the topmost Via address.

    But it should detect the private IP address in the contact header.

    Maybe you have an exception, that NAT traversal is not triggered, if
    there is more than 1 Via header.

    Klaus

    _______________________________________________
    SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
    sr-users@lists.sip-router.org <mailto:sr-users@lists.sip-router.org>
    http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users




_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

Reply via email to