You can check what @airsay suggested, and you can also go to Settings > Asterisk SIP Settings > Detect Network Settings and check if the External Address is the correct one.
Hello, we are facing a very similar issue. We are using a SIP trunk from the Brazilian provider Oi UC4X, which requires SRTP and TLS transport via PJSIP.
Even after correctly setting the external_media_address, external_signaling_address, and media_address parameters, and ensuring NAT is properly configured on FreePBX/Asterisk, we are still experiencing no audio during calls.
When analyzing SIP sessions with sngrep, we observed that the c= field in the SDP (responsible for indicating the media IP) is showing the server’s local IP or the extension’s internal IP, instead of the server’s public IP, which is the actual address used for communication with the provider.
This behavior breaks RTP/SRTP media exchange, preventing proper audio transmission.
Important: When the SIP account is registered on MicroSIP, within the same network, everything works perfectly — with two-way audio. The issue only occurs when using FreePBX/Asterisk with TLS and SRTP.
We would like to know if anyone has faced this situation and if there is a reliable way to force Asterisk to use the public IP address in the c= field of the SDP when making external calls using TLS and SRTP.
Yes, the network is properly configured. NAT is set to ‘yes’, I filled in the static IP field with the public IP and set the LAN network to ‘192.168.0.0/16’ as required in the Asterisk SIP settings. I also confirmed in the pjsip.transports.conf file that the external_media_address and external_signaling_address fields are correctly set with the public IP, and the local_net is set with the LAN subnet.
Although not going to be the problem here, nat=yes is a chan_sip thing and relates to cases where Asterisk is outside NAT relative to the endpoint, not to the case here.