1

Я установил простую Ubuntu 14.04, просто устанавливая Asterisk (apt-get update && apt-get upgrade && apt-get install asterisk).

Когда я пытаюсь войти с моего клиента (Телефон для OS X), я получаю на сервере следующее:

[Dec 16 14:39:32] NOTICE[1415]: chan_sip.c:28104 handle_request_register: Registration from '"100" <sip:100@10.0.83.14>' failed for '10.0.83.202:51966' - Wrong password

Это с включенной отладкой (sip set debug on):

ubuntu*CLI> sip set debug on
SIP Debugging enabled

<--- SIP read from UDP:10.0.83.202:51966 --->
REGISTER sip:10.0.83.14 SIP/2.0
Via: SIP/2.0/UDP 10.0.83.202:51966;rport;branch=z9hG4bKPjBI0jx0tvcvCCI8OdXBS23CsjJZIZ44RY
Max-Forwards: 70
From: "100" <sip:100@10.0.83.14>;tag=plvX4lQlJaBENJG7pPpRFmUh.iTUjbEt
To: "100" <sip:100@10.0.83.14>
Call-ID: 8sl0kRj5umaTXWoaxmnoRelE-6OCi2sP
CSeq: 62639 REGISTER
User-Agent: Telephone 1.1.4
Contact: "100" <sip:100@10.0.83.202:51966;ob>
Expires: 300
Allow: PRACK, INVITE, ACK, BYE, CANCEL, UPDATE, INFO, SUBSCRIBE, NOTIFY, REFER, MESSAGE, OPTIONS
Content-Length: 0

<------------->
--- (12 headers 0 lines) ---
Sending to 10.0.83.202:51966 (no NAT)
Sending to 10.0.83.202:51966 (no NAT)

<--- Transmitting (no NAT) to 10.0.83.202:51966 --->
SIP/2.0 401 Unauthorized
Via: SIP/2.0/UDP 10.0.83.202:51966;branch=z9hG4bKPjBI0jx0tvcvCCI8OdXBS23CsjJZIZ44RY;received=10.0.83.202;rport=51966
From: "100" <sip:100@10.0.83.14>;tag=plvX4lQlJaBENJG7pPpRFmUh.iTUjbEt
To: "100" <sip:100@10.0.83.14>;tag=as0d554a0f
Call-ID: 8sl0kRj5umaTXWoaxmnoRelE-6OCi2sP
CSeq: 62639 REGISTER
Server: Asterisk PBX 11.15.0
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
WWW-Authenticate: Digest algorithm=MD5, realm="asterisk", nonce="48750583"
Content-Length: 0


<------------>
Scheduling destruction of SIP dialog '8sl0kRj5umaTXWoaxmnoRelE-6OCi2sP' in 32000 ms (Method: REGISTER)

<--- SIP read from UDP:10.0.83.202:51966 --->
REGISTER sip:10.0.83.14 SIP/2.0
Via: SIP/2.0/UDP 10.0.83.202:51966;rport;branch=z9hG4bKPjWqjrVV68nMtX5cETs0hqsgp2t7uoyDOk
Max-Forwards: 70
From: "100" <sip:100@10.0.83.14>;tag=plvX4lQlJaBENJG7pPpRFmUh.iTUjbEt
To: "100" <sip:100@10.0.83.14>
Call-ID: 8sl0kRj5umaTXWoaxmnoRelE-6OCi2sP
CSeq: 62640 REGISTER
User-Agent: Telephone 1.1.4
Contact: "100" <sip:100@10.0.83.202:51966;ob>
Expires: 300
Allow: PRACK, INVITE, ACK, BYE, CANCEL, UPDATE, INFO, SUBSCRIBE, NOTIFY, REFER, MESSAGE, OPTIONS
Authorization: Digest username="100", realm="asterisk", nonce="48750583", uri="sip:10.0.83.14", response="14db540cd5f6dc5da883947cb9cac334", algorithm=MD5
Content-Length: 0

<------------->
--- (13 headers 0 lines) ---
Sending to 10.0.83.202:51966 (no NAT)

<--- Transmitting (no NAT) to 10.0.83.202:51966 --->
SIP/2.0 403 Forbidden
Via: SIP/2.0/UDP 10.0.83.202:51966;branch=z9hG4bKPjWqjrVV68nMtX5cETs0hqsgp2t7uoyDOk;received=10.0.83.202;rport=51966
From: "100" <sip:100@10.0.83.14>;tag=plvX4lQlJaBENJG7pPpRFmUh.iTUjbEt
To: "100" <sip:100@10.0.83.14>;tag=as0d554a0f
Call-ID: 8sl0kRj5umaTXWoaxmnoRelE-6OCi2sP
CSeq: 62640 REGISTER
Server: Asterisk PBX 11.15.0
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
Content-Length: 0


<------------>
[Dec 16 14:42:42] NOTICE[1415]: chan_sip.c:28104 handle_request_register: Registration from '"100" <sip:100@10.0.83.14>' failed for '10.0.83.202:51966' - Wrong password
Scheduling destruction of SIP dialog '8sl0kRj5umaTXWoaxmnoRelE-6OCi2sP' in 32000 ms (Method: REGISTER)

Мой клиент на 10.0.83.202, мой сервер на 10.0.83.14, все находятся в локальной сети. В настоящее время я не собираюсь использовать SIP-сервер из внешней сети.

Я переустанавливал Asterisk три раза без каких-либо улучшений. Всегда неверный пароль, и я уверен, что я ввожу его правильно.

deadlock@ubuntu:~$ cat /etc/asterisk/sip.conf
[general]
udpbindaddr=10.0.83.14          ; IP address to bind UDP listen socket to (0.0.0.0 binds to all)
transport=udp                   ; Set the default transports.  The order determines the primary default transport.
localnet=10.0.83.0/24
domain=10.0.83.14               ; Add IP address as local domain
externip=10.0.83.14

[100]
type=friend
host=dynamic
secret=MyPass123
context=internal
mailbox=100@default
callgroup=1
pickupgroup=1
dtmfmode=rfc2833
canreinvite=no

[200]
type=friend
host=dynamic
secret=MyPass123
context=internal
callgroup=1
pickupgroup=1
dtmfmode=rfc2833
canreinvite=no


deadlock@ubuntu:~$ cat /etc/asterisk/extensions.conf
[internal]
; Calls between employees (between extensions)
exten => _XXX,1,Dial(SIP/${EXTEN})

exten => 100,1,Dial(SIP/100,20)
exten => 100,n,VoiceMail(100,u)
exten => 100,n,Hangup

exten => 200,1,Dial(SIP/100,20)
exten => 200,n,Hangup

Что я сделал не так? Это ошибка?

0