Hello all,
I am a newbie here. I have configured to asterisk Boxes A and B SIP registered with each other. All the calls made from B
should go to A and routed from there. Because some extensions on B may move between the two sites ( A and B).
So I created the dial plan to check all the time with A if the extension is there, if not route it back to B. So sometimes
the call is created at B and comes back to B from A. When it happens, the INVITE from A results in a “Proxy authentication failure” and the re INVITE leads to “Forbidden” from B. Any views on how to solve it…
Here are the sip traces
Reliably Transmitting (NAT) to 192.1.1.2:5060:
INVITE sip:1000@192.1.1.2SIP/2.0
Via: SIP/2.0/UDP 192.1.1.2:5060;branch=z9hG4bK1d472b32;rport
Max-Forwards: 70
From: “1001” sip:1001@192.1.1.2;tag=as70ff7e8d
To: sip:1000@192.1.1.2
Contact: sip:1001@192.1.1.1:5060
Call-ID: 1b9fde044c89309b386749b2521a2f30@192.1.1.1:5060
CSeq: 103 INVITE
User-Agent: Asterisk PBX 1.8.11.1
Proxy-Authorization: Digest username=“A”, realm=“asterisk”, algorithm=MD5, uri="sip:1000@192.1.1.2", nonce=“362440b8”, response="482347d418cd2c9fb4705b3256086cdc"
Date: Fri, 11 May 2012 12:11:26 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
Content-Type: application/sdp
Content-Length: 260
<— SIP read from UDP:192.1.1.2:5060 —>
SIP/2.0 403 Forbidden
Via: SIP/2.0/UDP 192.1.1.1:5060;branch=z9hG4bK1d472b32;received=192.1.1.1;rport=5060
From: “1001” sip:1001@192.1.1.1;tag=as70ff7e8d
To: sip:1000@192.1.1.2;tag=as0e19dc27
Call-ID: 1b9fde044c89309b386749b2521a2f30@192.1.1.1:5060
CSeq: 103 INVITE
User-Agent: Asterisk PBX
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY
Content-Length: 0
Configuration of A
sip.conf
[general]
register => A:1234@192.1.1.2/B ;ip of server B
port = 5060
bindaddr = 0.0.0.0
context = server
[B]
type = friend
secret = 1234
host=dynamic
context = phones
disallow = all
allow = ulaw
;insecure = invite
Configuration of B
sip.conf
[general]
register =>B:1234@192.1.1.1/A ; IP of server A is 192.1.1.1
port = 5060
bindaddr = 0.0.0.0
context = client2
;dynamic ip
[server]
type = friend
secret = 1234
host = dynamic
context = server_incoming
disallow = all
allow = ulaw
;insecure = invite
;definition of local phones
[1000]
username = 1000
type = friend
context = phones
secret = 1234
;insecure = invite
host = dynamic
[1001]
username = 1001
type = friend
context = phones
secret = 1234
host = dynamic