Hello,
I’m in the learning stages of working with Asterisk and I have a question about ports and incoming calls from DIDs.
I have a DID number that is forwarding calls its calls to an extension on an Asterisk server which is behind a router with a firewall. I have opened port 5060 on the router and have set up port forwarding to the port and IP of the machine running Asterisk. Incoming calls are getting answered and the caller can hear the voice of a receiver on an internal phone. The voice of the caller however is not heard by the receiver.
I’ve been reading that media (and sound I presume) is passed via RTP ports which are selected at random by Asterisk and that the default range is 10000-20000. I have not (and may not even be able to) set up port forwarding for a range of ports on the router, it seems that that function has been disabled by the carrier. I can only forward individual ports.
Here, I’m confused as to why the receiver’s voice can even be heard by the caller since the only open and forwarded port is 5060. How is this so?
The router’s firewall does allow me to open a range of ports and define an internal IP as well as the external one of the DID service.
Can anyone please offer suggestions?
I’ll paste the sip.conf entry for the DID below, which requires 2 trunks.
Thank you,
[carrymy-1]
host=xx.xx.xx.xx
dtmfmode=rfc2833
dtmf=rfc2833
type=peer
context=from_carrymy
;insecure=very
insecure=port,invite
nat=never
allow=all
[carrymy-2]
host=xx.xx.xx.xx
dtmfmode=rfc2833
dtmf=rfc2833
type=peer
context=from_carrymy
;insecure=very
insecure=port,invite
nat=never
allow=all