[Asterisk-Users] P2P RTP without SIP re-invites

Olle E. Johansson oej at edvina.net
Sat Jan 31 05:01:46 MST 2004


Brancaleoni Matteo wrote:

> Hi.
> 
> 
>>If both Alice and Bob are connected without NAT, have the same codec support and have canreinvite=yes
>>* Asterisk send (re-)INVITEs to both, trying to get the RTP stream transferred so it
>>   goes directly from Alice to Bob
>>Not all UAs support a re-INVITE and in public scenarios, a lot of UAs have broken NAT support so
>>the RTP media stream stays with Asterisk.
> 
> 
> a small correction: doesn't matter if Alice and Bob are nat'ed:
> if they're both nat'ed re-INVITEs are sent and RTP is transferred
> to go directly from Alice to Bob. Asterisk manages only the
> signalling on port 5060
> (I'm using that environment, so it works :) )
> 
> But if only Alice OR Bob are nat'ed, the RTP is handled by * itself.

I guess this would work if both Alice and Bob were NAT'ed on the inside of the same
NAT box. The problem is that if Alice and Bob both have NAT=yes and CANREINVITE=yes
and they're on separate NAT'ed networks, the call is broken. So it's a dangerous
configuration.

If someone made a solution that
* Compared the inside address AND the outside (NAT public IP)
* If they are similar (NAT from the same network and public IP equals),
   connect the RDP streams from inside NAT to inside NAT

However, with STUN, the calee or the caller might not present the inside IP address
and therefore this will not be possible at all...

Better to have an outbound SIP proxy that could make this happen.

Or?

/O




More information about the asterisk-users mailing list