[solved] Force all auto traffic and rtp through pbx w/ HA

This will allow an HA heartbeat shared IP dual server settup to work in the strictest, funkiest nat network possible, with bandwidth.com

Like a charm

MAIN - SIP.CONF

[general]
bindaddr=internal_floating_IP
externip=external_nated_floating_ip
localnet=internal_static_IP/255.255.255.0

PEER - SIP.CONF

[346576]
qualify=yes
port=5060
nat=yes
allow=ulaw
call-limit=10
directmedia=nonat
directrtpsetup=no

MODIFIED BANDWIDTH.COM

[bandwidth.com_inbound]

host=216.82.224.202
port=5060
type=peer
allow=ulaw
dtmfmode=rfc2833
reinvite=yes
canreinvite=no
context=from-pstn
nat=yes
insecure=invite,port


Hello,

Is is possible to send all traffic, including SIP and RTP, from a phone through asterisk then out to the sip provider?

In other words, prevent a direct RTP or SIP transfer from the phone out the router to the provider.

Any ideas…

directmedia=no

Thanks for the advise, I had read over the voip-wiki documents earlier but was unsure of what directmedia did.

Bandwidth.com is claiming that the sip trace shows asterisk is “requesting the rtp back to a private Ip in the 200ok message”.

I just did a round of testing but it still produces one way audio.

attempts:

directmedia=nonat
directrtpsetup=no
nat=yes

and

directmedia=no
directrtpsetup=no

and

directmedia=no

still one way audio…

Your problem is with miss-configured Asterisk that is behind NAT router. You already posted this question in another topic.