Troubleshooting Outgoing Callcentric SIP calls [RESOLVED]

My system consists of an Linksy SPA2102 ATA with * on an ASUS RT-N16. I am having trouble with a Callcentric SIP-VOIP channel.

I started troubleshooting by determining by logging into the callcentric account and it indicates “your phone is registered”. This is further supported from the * CLI:

athomehost*CLI> sip show registry
Host dnsmgr Username Refresh State Reg.Time
callcentric.com:5060 N 1777XXXXXXX 45 Registered Tue, 06 Sep 2011 00:10:40 1 SIP registrations.

I am hoping that either I have setup the channel correctly or someone will advise that these diagnostics are not definitive to confirm that the channel is setup correctly and provide CLI diagnostic guidance.

I noticed that when I tried to place calls through the callcentric channel I received these messages at the CLI:

Is this a symptom of the problem: how does this map to the root cause of the problem?

athomehost*CLI> sip show peers
Name/username Host Dyn Forcerport ACL Port Status
101/101 192.168.8.110 D N 5060 OK (13 ms)
NokiaE71x/NokiaE71x (Unspecified) D N 0 UNKNOWN
callcentric/17772851530 204.11.192.36 5080 Unmonitored
3 sip peers [Monitored: 1 online, 1 offline Unmonitored: 1 online, 0 offline]

Actionable guidance is appreciated: thank you.

I have no idea what “actionable” guidance means.

The message means that the combination of information used by the remote system to authenticate your system was not what it expected. That could include having the wrong user or password, but could also include violating some other policy. I would have thought that bad user or password data were obvious “root causes”.

The message will be caused by a 401 response from the remote end. It might happen if there was no authentication information provided locally, but it is more likely to be because the remote system objected, so if you are seeking to trace the root cause, you need to find out why the remote system would give a 401 response.

The remote system here is the ATA.

@david55: Thank you for responding to the questions. I’m a litle puzzled because the ATA’s information page shows that the ATA is registered with Asterisk:

In addition, I have been using the ATA to make calls through the Gtalk channel with no problems. This had led me to believe that the ATA is properly connected to Asterisk. Maybe this is not true? BTW, in the error message: “SPA2102 L2” is actually the CallerID string that is configured in sip.conf:

[101]
type=friend
host=dynamic
nat=yes
qualify=yes
; context=to-callcentric TEST ONLY, uncomment next line
context=mario-default ; found in exension.conf
defaultuser=101
secret=XXXXXXXX
callerid=“SPA2102 L2” <101>
mailbox=101

athomehost*CLI> sip show channels
Peer User/ANR Call ID Format Hold Last Message Expiry Peer
204.11.192.39 1777XXXXXXX 66a1d7dc61d1ee9 0x0 (nothing) No
1 active SIP dialog

Actionable refers to specific enough information so that I would be able to take that information and do something constructive with it. There’s a good chance you know a lot more about this system then I do, so I hope you will bear this in mind when providing guidance. This definition is broad, so in the interest of progress, providing command line instructions and their context (* CLI vs Unix CLI) to diagnose a problem would be an excellent example of very actionable guidance. If there is common understanding between advisor and the student, then this information does not need to be provided in the guidance. In this case no common understanding should be assumed.

The ATA logon credentials are configured as such:

The Asterisk server’s LAN IP address is configured in the Proxy field. For giggles, I copied the server’s IP into the Outbound proxy field, but it made no differnce.

As I understand it, I am looking for a ‘401’ response: I am not sure what policy would be violated (example?). So I am guessing that I need to use one of these commands to diagnose the 401 problem:

athomehost*CLI> core show help sip
sip notify Send a notify packet to a SIP peer
sip prune realtime [peer|all] Prune cached Realtime users/peers
sip qualify peer Send an OPTIONS packet to a peer
sip reload Reload SIP configuration
sip set debug {on|off|ip|peer} Enable/Disable SIP debugging
sip set history {on|off} Enable/Disable SIP history
sip show {channels|subscriptio List active SIP channels or subscriptions
sip show channelstats List statistics for active SIP channels
sip show channel Show detailed SIP channel info
sip show domains List our local SIP domains
sip show history Show SIP dialog history
sip show inuse List all inuse/limits
sip show mwi Show MWI subscriptions
sip show objects List all SIP object allocations
sip show peers List defined SIP peers
sip show peer Show details on specific SIP peer
sip show registry List SIP registration status
sip show sched Present a report on the status of the scheduler queue
sip show settings Show SIP global settings
sip show tcp List TCP Connections
sip show users List defined SIP users
sip show user Show details on specific SIP user
sip unregister Unregister (force expiration) a SIP peer from the registry

Would ‘sip show history’ at the * CLI be the right place to start digging?

Update: Turned on >> sip set debug on and placed a call. Found the ‘401’ Unauthorized message. Not really sure how to analyze / use this information:

[code]Connected to Asterisk 1.8.4 currently running on athomehost (pid = 12392)
Really destroying SIP dialog ‘66a1d7dc61d1de9d3a2c443016366e6f@[c0a8:801:e83a:c37f::]’ Method: REGISTER

<— SIP read from UDP:192.168.8.110:5060 —>
INVITE sip:17771234567@192.168.8.1 SIP/2.0
Via: SIP/2.0/UDP 192.168.8.110:5060;branch=z9hG4bK-2a9fa1cd
From: 101 sip:101@192.168.8.1;tag=d352f52adaf070c5o1
To: sip:17771234567@192.168.8.1
Remote-Party-ID: 101 sip:101@192.168.8.1;screen=yes;party=calling
Call-ID: 1125b4ce-c7921571@192.168.8.110
CSeq: 101 INVITE
Max-Forwards: 70
Contact: 101 sip:101@192.168.8.110:5060
Expires: 240
User-Agent: Linksys/SPA2102-5.1.5(a)
Content-Length: 444
Allow: ACK, BYE, CANCEL, INFO, INVITE, NOTIFY, OPTIONS, REFER
Supported: x-sipura, replaces
Content-Type: application/sdp

v=0
o=- 180584 180584 IN IP4 192.168.8.110
s=-
c=IN IP4 192.168.8.110
t=0 0
m=audio 16416 RTP/AVP 18 0 2 4 8 96 97 98 100 101
a=rtpmap:18 G729a/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:2 G726-32/8000
a=rtpmap:4 G723/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:96 G726-40/8000
a=rtpmap:97 G726-24/8000
a=rtpmap:98 G726-16/8000
a=rtpmap:100 NSE/8000
a=fmtp:100 192-193
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=ptime:30
a=sendrecv
<------------->
— (15 headers 20 lines) —
Sending to 192.168.8.110:5060 (no NAT)
Using INVITE request as basis request - 1125b4ce-c7921571@192.168.8.110
Found peer ‘101’ for ‘101’ from 192.168.8.110:5060

<— Reliably Transmitting (NAT) to 192.168.8.110:5060 —>
SIP/2.0 401 Unauthorized
Via: SIP/2.0/UDP 192.168.8.110:5060;branch=z9hG4bK-2a9fa1cd;received=192.168.8.110;rport=5060
From: 101 sip:101@192.168.8.1;tag=d352f52adaf070c5o1
To: sip:17771234567@192.168.8.1;tag=as503fa8d1
Call-ID: 1125b4ce-c7921571@192.168.8.110
CSeq: 101 INVITE
Server: Asterisk PBX 1.8.4
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces
WWW-Authenticate: Digest algorithm=MD5, realm=“asterisk”, nonce=“7f948c47”
Content-Length: 0

<------------>
Scheduling destruction of SIP dialog ‘1125b4ce-c7921571@192.168.8.110’ in 6400 ms (Method: INVITE)

<— SIP read from UDP:192.168.8.110:5060 —>
ACK sip:17771234567@192.168.8.1 SIP/2.0
Via: SIP/2.0/UDP 192.168.8.110:5060;branch=z9hG4bK-2a9fa1cd
From: 101 sip:101@192.168.8.1;tag=d352f52adaf070c5o1
To: sip:17771234567@192.168.8.1;tag=as503fa8d1
Call-ID: 1125b4ce-c7921571@192.168.8.110
CSeq: 101 ACK
Max-Forwards: 70
Contact: 101 sip:101@192.168.8.110:5060
User-Agent: Linksys/SPA2102-5.1.5(a)
Content-Length: 0

<------------->
— (10 headers 0 lines) —

<— SIP read from UDP:192.168.8.110:5060 —>
INVITE sip:17771234567@192.168.8.1 SIP/2.0
Via: SIP/2.0/UDP 192.168.8.110:5060;branch=z9hG4bK-2450a15d
From: 101 sip:101@192.168.8.1;tag=d352f52adaf070c5o1
To: sip:17771234567@192.168.8.1
Remote-Party-ID: 101 sip:101@192.168.8.1;screen=yes;party=calling
Call-ID: 1125b4ce-c7921571@192.168.8.110
CSeq: 102 INVITE
Max-Forwards: 70
Authorization: Digest username=“101”,realm=“asterisk”,nonce=“7f948c47”,uri="sip:17771234567@192.168.8.1",algorithm=MD5,response=“8863a1eea9f694ce1fd804a9931e27e2”
Contact: 101 sip:101@192.168.8.110:5060
Expires: 240
User-Agent: Linksys/SPA2102-5.1.5(a)
Content-Length: 444
Allow: ACK, BYE, CANCEL, INFO, INVITE, NOTIFY, OPTIONS, REFER
Supported: x-sipura, replaces
Content-Type: application/sdp

v=0
o=- 180584 180584 IN IP4 192.168.8.110
s=-
c=IN IP4 192.168.8.110
t=0 0
m=audio 16416 RTP/AVP 18 0 2 4 8 96 97 98 100 101
a=rtpmap:18 G729a/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:2 G726-32/8000
a=rtpmap:4 G723/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:96 G726-40/8000
a=rtpmap:97 G726-24/8000
a=rtpmap:98 G726-16/8000
a=rtpmap:100 NSE/8000
a=fmtp:100 192-193
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=ptime:30
a=sendrecv
<------------->
— (16 headers 20 lines) —
Sending to 192.168.8.110:5060 (NAT)
Using INVITE request as basis request - 1125b4ce-c7921571@192.168.8.110
Found peer ‘101’ for ‘101’ from 192.168.8.110:5060
Found RTP audio format 18
Found RTP audio format 0
Found RTP audio format 2
Found RTP audio format 4
Found RTP audio format 8
Found RTP audio format 96
Found RTP audio format 97
Found RTP audio format 98
Found RTP audio format 100
Found RTP audio format 101
Found audio description format G729a for ID 18
Found audio description format PCMU for ID 0
Found audio description format G726-32 for ID 2
Found audio description format G723 for ID 4
Found audio description format PCMA for ID 8
Found audio description format G726-40 for ID 96
Found audio description format G726-24 for ID 97
Found audio description format G726-16 for ID 98
Found audio description format NSE for ID 100
Found audio description format telephone-event for ID 101
Capabilities: us - 0x80000008000e (gsm|ulaw|alaw|h263|testlaw), peer - audio=0x100d0d (g723|ulaw|alaw|g726|g729|ilbc|h263p)/video=0x0 (nothing)/text=0x0 (nothing), combined - 0xc (ulaw|alaw)
Non-codec capabilities (dtmf): us - 0x1 (telephone-event|), peer - 0x1 (telephone-event|), combined - 0x1 (telephone-event|)
Peer audio RTP is at port 192.168.8.110:16416
Looking for 17771234567 in mario-default (domain 192.168.8.1)
list_route: hop: sip:101@192.168.8.110:5060

<— Transmitting (NAT) to 192.168.8.110:5060 —>
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 192.168.8.110:5060;branch=z9hG4bK-2450a15d;received=192.168.8.110;rport=5060
From: 101 sip:101@192.168.8.1;tag=d352f52adaf070c5o1
To: sip:17771234567@192.168.8.1
Call-ID: 1125b4ce-c7921571@192.168.8.110
CSeq: 102 INVITE
Server: Asterisk PBX 1.8.4
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces
Contact: sip:17771234567@192.168.8.1:5060
Content-Length: 0

<------------>
Audio is at 5060
Adding codec 0x4 (ulaw) to SDP
Adding codec 0x2 (gsm) to SDP
Adding codec 0x800000000000 (testlaw) to SDP
Adding non-codec 0x1 (telephone-event) to SDP
Reliably Transmitting (no NAT) to 204.11.192.38:5080:
INVITE sip:17771234567@callcentric.com SIP/2.0
Via: SIP/2.0/UDP 98.71.209.73:5060;branch=z9hG4bK678f343f
Max-Forwards: 70
From: “RayChiu SPA2102 L2” sip:101@98.71.209.73;tag=as7dd9e98c
To: sip:17771234567@callcentric.com
Contact: sip:101@98.71.209.73:5060
Call-ID: 463f75bb6f0a81a24bc9247e1440ec08@98.71.209.73:5060
CSeq: 102 INVITE
User-Agent: Asterisk PBX 1.8.4
Date: Tue, 06 Sep 2011 03:40:48 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces
Content-Type: application/sdp
Content-Length: 282

v=0
o=root 919388685 919388685 IN IP4 98.71.209.73
s=Asterisk PBX 1.8.4
c=IN IP4 98.71.209.73
t=0 0
m=audio 12302 RTP/AVP 0 3 101
a=rtpmap:0 PCMU/8000
a=rtpmap:3 GSM/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=silenceSupp:off - - - -
a=ptime:20
a=sendrecv


<— SIP read from UDP:204.11.192.38:5080 —>
SIP/2.0 407 Proxy Authentication Required
v: SIP/2.0/UDP 98.71.209.73:5060;branch=z9hG4bK678f343f
f: " SPA2102 L2" sip:101@98.71.209.73;tag=as7dd9e98c
t: sip:17771234567@callcentric.com
i: 463f75bb6f0a81a24bc9247e1440ec08@98.71.209.73:5060
CSeq: 102 INVITE
Proxy-Authenticate: Digest realm=“98.71.209.73”, domain=“sip:98.71.209.73”, nonce=“8fa5e7471bd9d06eecccc3de25b4316c”, opaque="", stale=TRUE, algorithm=MD5
l: 0

<------------->
— (8 headers 0 lines) —
Transmitting (no NAT) to 204.11.192.38:5080:
ACK sip:17771234567@callcentric.com SIP/2.0
Via: SIP/2.0/UDP 98.71.209.73:5060;branch=z9hG4bK678f343f
Max-Forwards: 70
From: " SPA2102 L2" sip:101@98.71.209.73;tag=as7dd9e98c
To: sip:17771234567@callcentric.com
Contact: sip:101@98.71.209.73:5060
Call-ID: 463f75bb6f0a81a24bc9247e1440ec08@98.71.209.73:5060
CSeq: 102 ACK
User-Agent: Asterisk PBX 1.8.4
Content-Length: 0


[Sep 6 03:40:48] NOTICE[12408]: chan_sip.c:19294 handle_response_invite: Failed to authenticate on INVITE to ‘" SPA2102 L2" sip:101@98.71.209.73;tag=as7dd9e98c’

<— Reliably Transmitting (NAT) to 192.168.8.110:5060 —>
SIP/2.0 503 Service Unavailable
Via: SIP/2.0/UDP 192.168.8.110:5060;branch=z9hG4bK-2450a15d;received=192.168.8.110;rport=5060
From: 101 sip:101@192.168.8.1;tag=d352f52adaf070c5o1
To: sip:17771234567@192.168.8.1;tag=as355b8b93
Call-ID: 1125b4ce-c7921571@192.168.8.110
CSeq: 102 INVITE
Server: Asterisk PBX 1.8.4
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces
X-Asterisk-HangupCause: Call Rejected
X-Asterisk-HangupCauseCode: 21
Content-Length: 0

<------------>
Really destroying SIP dialog ‘463f75bb6f0a81a24bc9247e1440ec08@98.71.209.73:5060’ Method: INVITE

<— SIP read from UDP:192.168.8.110:5060 —>
ACK sip:17771234567@192.168.8.1 SIP/2.0
Via: SIP/2.0/UDP 192.168.8.110:5060;branch=z9hG4bK-2450a15d
From: 101 sip:101@192.168.8.1;tag=d352f52adaf070c5o1
To: sip:17771234567@192.168.8.1;tag=as355b8b93
Call-ID: 1125b4ce-c7921571@192.168.8.110
CSeq: 102 ACK
Max-Forwards: 70
Authorization: Digest username=“101”,realm=“asterisk”,nonce=“7f948c47”,uri="sip:17771234567@192.168.8.1",algorithm=MD5,response=“e0d7e9c84a032d1eda6c5d6e96775718”
Contact: 101 sip:101@192.168.8.110:5060
User-Agent: Linksys/SPA2102-5.1.5(a)
Content-Length: 0

<------------->
— (11 headers 0 lines) —
Really destroying SIP dialog ‘1125b4ce-c7921571@192.168.8.110’ Method: ACK
Reliably Transmitting (NAT) to 192.168.8.110:5060:
OPTIONS sip:101@192.168.8.110:5060 SIP/2.0
Via: SIP/2.0/UDP 192.168.8.1:5060;branch=z9hG4bK25de34ee;rport
Max-Forwards: 70
From: “asterisk” sip:asterisk@192.168.8.1;tag=as7961f39e
To: sip:101@192.168.8.110:5060
Contact: sip:asterisk@192.168.8.1:5060
Call-ID: 2aef4bbf19e5f2c240886bc364d4299e@192.168.8.1:5060
CSeq: 102 OPTIONS
User-Agent: Asterisk PBX 1.8.4
Date: Tue, 06 Sep 2011 03:40:54 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces
Content-Length: 0


<— SIP read from UDP:192.168.8.110:5060 —>
SIP/2.0 200 OK
To: sip:101@192.168.8.110:5060;tag=ff6424ab906ddf88i1
From: “asterisk” sip:asterisk@192.168.8.1;tag=as7961f39e
Call-ID: 2aef4bbf19e5f2c240886bc364d4299e@192.168.8.1:5060
CSeq: 102 OPTIONS
Via: SIP/2.0/UDP 192.168.8.1:5060;branch=z9hG4bK25de34ee
Server: Linksys/SPA2102-5.1.5(a)
Content-Length: 0
Allow: ACK, BYE, CANCEL, INFO, INVITE, NOTIFY, OPTIONS, REFER
Supported: x-sipura, replaces

<------------->
— (10 headers 0 lines) —
Really destroying SIP dialog ‘2aef4bbf19e5f2c240886bc364d4299e@192.168.8.1:5060’ Method: OPTIONS
[Sep 6 03:40:56] NOTICE[12408]: chan_sip.c:12365 sip_reregister: – Re-registration for 1777285XXXX@callcentric.com
REGISTER 11 headers, 0 lines
Reliably Transmitting (no NAT) to 204.11.192.34:5060:
REGISTER sip:callcentric.com SIP/2.0
Via: SIP/2.0/UDP 98.71.209.73:5060;branch=z9hG4bK7a534821
Max-Forwards: 70
From: sip:1777285XXXX@callcentric.com;tag=as73dd23fc
To: sip:1777285XXXX@callcentric.com
Call-ID: 66a1d7dc61d1de9d3a2c443016366e6f@[c0a8:801:e83a:c37f::]
CSeq: 362 REGISTER
User-Agent: Asterisk PBX 1.8.4
Authorization: Digest username=“1777285XXXX”, realm=“callcentric.com”, algorithm=MD5, uri=“sip:callcentric.com”, nonce=“98aea323dc30f5b56c3a0c5885cb272b”, response=“f9defd8e9d1bbc0796b346f7d05b2a87”
Expires: 120
Contact: sip:1777285XXXX@98.71.209.73:5060
Content-Length: 0


<— SIP read from UDP:204.11.192.34:5060 —>
SIP/2.0 407 Proxy Authentication Required
v: SIP/2.0/UDP 98.71.209.73:5060;branch=z9hG4bK7a534821
f: sip:1777285XXXX@callcentric.com;tag=as73dd23fc
t: sip:1777285XXXX@callcentric.com
i: 66a1d7dc61d1de9d3a2c443016366e6f@[c0a8:801:e83a:c37f::]
CSeq: 362 REGISTER
Proxy-Authenticate: Digest realm=“callcentric.com”, domain=“sip:callcentric.com”, nonce=“36d0e3641f7bb07dc0b52703c8e54057”, opaque="", stale=TRUE, algorithm=MD5
l: 0

<------------->
— (8 headers 0 lines) —
Responding to challenge, registration to domain/host name callcentric.com
REGISTER 11 headers, 0 lines
Reliably Transmitting (no NAT) to 204.11.192.34:5060:
REGISTER sip:callcentric.com SIP/2.0
Via: SIP/2.0/UDP 98.71.209.73:5060;branch=z9hG4bK7d7b790a
Max-Forwards: 70
From: sip:1777285XXXX@callcentric.com;tag=as2d764d7a
To: sip:1777285XXXX@callcentric.com
Call-ID: 66a1d7dc61d1de9d3a2c443016366e6f@[c0a8:801:e83a:c37f::]
CSeq: 363 REGISTER
User-Agent: Asterisk PBX 1.8.4
Proxy-Authorization: Digest username=“1777285XXXX”, realm=“callcentric.com”, algorithm=MD5, uri=“sip:callcentric.com”, nonce=“36d0e3641f7bb07dc0b52703c8e54057”, response=“f19823a5eb27f109e6d6240bf92b1f5e”
Expires: 120
Contact: sip:1777285XXXX@98.71.209.73:5060
Content-Length: 0


<— SIP read from UDP:204.11.192.34:5060 —>
NOTIFY sip:1777285XXXX@98.71.209.73:5060 SIP/2.0
v: SIP/2.0/UDP 204.11.192.34:5060;branch=z9hG4bK-8e8ce218397e3eecc5ed981d93ae9f5e
f: sip:1777285XXXX@callcentric.com:5062
t: sip:1777285XXXX@callcentric.com
i: 7c6dda277e1fe962b56a210eb50e8b13-b1431cd809fe419add5d2dfd7ee1c10a@callcentric.com
CSeq: 1 NOTIFY
Max-Forwards: 15
m: sip:8a9b79be9b1c32935a26f9b91f5f48a6@204.11.192.34:5060;transport=udp
Event: message-summary
c: application/simple-message-summary
l: 138

Messages-Waiting: no
Message-Account: sip:1777285XXXX@callcentric.com
Voice-Message: 0/0 (0/0)
Fax-Message: 0/0 (0/0)
None: 0/0 (0/0)
<------------->
— (11 headers 5 lines) —

<— SIP read from UDP:204.11.192.34:5060 —>
SIP/2.0 200 Ok
v: SIP/2.0/UDP 98.71.209.73:5060;branch=z9hG4bK7d7b790a
f: sip:1777285XXXX@callcentric.com;tag=as2d764d7a
t: sip:1777285XXXX@callcentric.com
i: 66a1d7dc61d1de9d3a2c443016366e6f@[c0a8:801:e83a:c37f::]
CSeq: 363 REGISTER
m: sip:1777285XXXX@98.71.209.73:5060;expires=60
l: 0

<------------->
— (8 headers 0 lines) —
Scheduling destruction of SIP dialog ‘66a1d7dc61d1de9d3a2c443016366e6f@[c0a8:801:e83a:c37f::]’ in 32000 ms (Method: REGISTER)
[Sep 6 03:40:56] NOTICE[12408]: chan_sip.c:19760 handle_response_register: Outbound Registration: Expiry for callcentric.com is 60 sec (Scheduling reregistration in 45 s)
athomehost*CLI> exit

[/code]

Looks like the message is misleading as to the direction. It is also 407, rather than 401, although I don’t think that makes a big difference. You probably need an [authentication] section in sip.conf.

The registration status is irrelevant for outgoing calls.
When acting as a SIP client, you need to specify the authentication credentials twice:

  1. In the registration string (for incoming)
  2. In the peer definition (for outgoing)

You are missing 2. in the callcentric peer definition.

I wish there were some docs you could be pointed to. You are user number 27981 this month looking at the same problem across all the asterisk forums I visit.

The reason that I suggested [authenticate] is that there can be a conflict between inbound and outbound secrets, at least up to Asterisk 1.6.x. However, if there is no inbound authentication, you may be to use an alternative way of specifying the registration information, that goes in the peer entry. You will probably have to use insecure=invite, in that case.

@david55: I looked up [authenticate] in the book Asterisk: The definitive Guide 3rd ed. for examples: nothing. Also tried Google: nada. Can you point me to a relevant example?

My Callcentric portion of sip.conf is taken from http://www.callcentric.com/support/device/asterisk/1_6:

[callcentric] type=peer context=from-callcentric ;defined in: extensions.conf host=callcentric.com defaultuser=1777285XXXX secret=supersecretpassword fromuser=1777285XXXX fromdomain=callcentric.com insecure=very

The insecure-setting is not correct (insecure=very is deprecated), it should be

instead, as recommended by callcentric.
You should change this and have a look at the sip-trace after the change.

insecure=port,invite means the same as insecure=very used to mean. The only reason for not using the latter is that current versions of Asterisk don’t recognize it.

However, insecure=port,invite is usually wrong (to insecure). Service providers recommend because they don’t want to think about the correct settings, and making a system more insecure means it is less likely that it won’t work because of the security settings.

In this case, I believe you need insecure=invite.

The book, as well as relating to Asterisk 1.4, is wrong; that section is even in Asterisk 1.4.1. In any case, most of the back half of the book is simply a combination of a prettied up versions of the comments in configs/*.sample, together with the output from core show application, core show function and manager show command, which are where you should go to for documentation on the details of configuring Asterisk.

You will probably be OK without it, as most service providers do not try to authenticate themselves to their customers.

Resolved… Problem was in the dialplan:

This is what it should be: exten => _1777ZXXXXXX,1,Dial(SIP/${EXTEN}@callcentric)

This is incorrect: exten => _1777ZXXXXXX,1,Dial(SIP/${EXTEN}@callcentric.com)

A BIG thank you to all those who responded!

This is the my sip.conf:

[code][general]
;Sept 6 2011
; [RMC] http://www.callcentric.com/support/device/asterisk/1_6
dtmfmode = rfc2833
context=from-callcentric
srvlookup=yes
register => 1777XXXXXX:MyPassword@callcentric.com/1777XXXXXX
session-timers=refuse
session-expires=180
session-minse=90
session-refresher=uas
; http://www.callcentric.com/support/device/asterisk/1_6

[callcentric]
type=peer
context=from-callcentric ;how incoming calls are handle: defined in: extensions.conf
host=callcentric.com
defaultuser=1777XXXXXX
secret=MyPassword
fromuser=1777XXXXXX
fromdomain=callcentric.com
;insecure=very ; deprecated
insecure=invite 9/6/11
;insecure=port,invite 9/6/11

[101]
; [RMC] http://supermario-world.blogspot.com/2010/11/asterisk-18-and-native-google-voice.html
type=friend
host=dynamic
nat=yes
qualify=yes
; context=to-callcentric TEST ONLY, uncomment next line
context=mario-default ; found in exension.conf
defaultuser=101
secret=MyPassword
callerid=“Gatorback SPA2102_L2” <101>
mailbox=101
; [RMC] http://supermario-world.blogspot.com/2010/11/asterisk-18-and-native-google-voice.html[/code]