T
T
torr20092014-12-17 11:39:56
Asterisk
torr2009, 2014-12-17 11:39:56

Asterisk ignores the port=XXXX directive. How to force Asterisk to address the necessary ports?

The provider provides a SIP connection without authorization on a non-standard port. Asterisk in this case acts as a SIP client.
Asterisk accesses the standard port 5060, although a different port is explicitly specified in the peer settings.
How to correctly specify the correct port? (port=16071)
Below is the log of a test pair of Asterisks (version 1.8).
sip show peers
Name/username Host Dyn Forcerport ACL Port Status

test/244                  192.168.1.20                                 N             5060     OK (1 ms)

sip.conf
[general]
disallow=all
allow=alaw
allow=ulaw
localnet=192.168.0.0/255.255.0.0
nat=yes


subscribecontext=public
context=public                  ; Default context for incoming calls. Defaults to 'default'


[test]
   
host=192.168.1.20
port=16071 
type=friend    
insecure=invite 
callbackextension=777
canreinvite=no 
qualify=yes 
username = 244

The chan_sip driver is used.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
C
catHD, 2014-12-17
@catHD

Do you need registration for this port?

A
Armenian Radio, 2014-12-17
@gbg

That's right, sip.conf specifies which port asterisk will listen on. And which port the phone or softphone listens to is already configured in it.

V
Vladimir, 2014-12-17
@rostel

type=peer
insecure=port,invite
remove callbackextension

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question