To update. here is the logfile
I have intentionally replaced some IP addresses with .x.x.x
The extension is extension 711
It still can not register with the SIP phone.
Sep 3 17:31:15 VERBOSE[3158] logger.c: Transmitting (NAT) to 71.x.x.x:51745:
SIP/2.0 403 Forbidden (Bad auth)
Via: SIP/2.0/UDP 71.x.x.x:5060;branch=z9hG4bK8efbc11a3;received=71.x.x.x
From: 711 ;tag=5f9c8d5e707a967
To: 711 ;tag=as6d0ae6d9
Call-ID: 56a4acd85fa339664c7d5c108cc05b9b@71.x.x.x
CSeq: 1840537048 REGISTER
User-Agent: Asterisk PBX
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY
Content-Length: 0
Sep 3 17:31:15 NOTICE[3158] chan_sip.c: Registration from ‘711 ’ failed for ‘71.x.x.x’ - Wrong password
Sep 3 17:31:15 VERBOSE[3158] logger.c: Scheduling destruction of call '56a4acd85fa339664c7d5c108cc05b9b@71.x.x.x’ in 15000 ms
Sep 3 17:31:15 DEBUG[3158] chan_sip.c: SIP message could not be handled, bad request: 56a4acd85fa339664c7d5c108cc05b9b@71.x.x.x
Sep 3 17:31:30 DEBUG[3158] chan_sip.c: Auto destroying call '56a4acd85fa339664c7d5c108cc05b9b@71.x.x.x’
Sep 3 17:31:30 VERBOSE[3158] logger.c: Destroying call '56a4acd85fa339664c7d5c108cc05b9b@71.x.x.x’
Sep 3 17:32:12 DEBUG[3207] manager.c: Manager received command 'Command’
Sep 3 18:00:12 DEBUG[3207] manager.c: Manager received command 'Command’
Sep 3 18:01:15 VERBOSE[3158] logger.c:
<-- SIP read from 71.x.x.x:51745:
REGISTER sip:192.168.1.140:5060 SIP/2.0
Via: SIP/2.0/UDP 71.x.x.x:5060;branch=z9hG4bKc8272c596
Max-Forwards: 70
Content-Length: 0
To: 711
From: 711 ;tag=5f9c8d5e707a967
Call-ID: 56a4acd85fa339664c7d5c108cc05b9b@71.x.x.x
CSeq: 1840537049 REGISTER
Contact: 711 ;expires=300
Allow-Events: talk,hold,conference
Allow:NOTIFY,REFER,OPTIONS,INVITE,ACK,CANCEL,BYE,INFO
Expires: 300
Authorization:Digest response=“3e2d5749ef435f6359f8cb67fa8116f6”,username=“711”,realm=“asterisk”,nonce=“050766c0”,algorithm=MD5,uri="sip:192.168.1.140:5060"
User-Agent: Aastra 9133i/1.4.2.3000 Brcm Callctrl/1.5.1.0 MxSF/v3.2.8.45
Sep 3 18:01:15 VERBOSE[3158] logger.c: — (14 headers 0 lines) —
Sep 3 18:01:15 DEBUG[3158] acl.c: ##### Testing 71.x.x.x with 192.168.1.0
Sep 3 18:01:15 DEBUG[3158] chan_sip.c: Target address 71.x.x.x is not local, substituting externip
Sep 3 18:01:15 VERBOSE[3158] logger.c: Using latest REGISTER request as basis request
Sep 3 18:01:15 VERBOSE[3158] logger.c: Sending to 71.x.x.x : 5060 (NAT)
Sep 3 18:01:15 VERBOSE[3158] logger.c: Transmitting (NAT) to 71.x.x.x:51745:
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 71.x.x.x:5060;branch=z9hG4bKc8272c596;received=71.x.x.x
From: 711 ;tag=5f9c8d5e707a967
To: 711
Call-ID: 56a4acd85fa339664c7d5c108cc05b9b@71.x.x.x
CSeq: 1840537049 REGISTER
User-Agent: Asterisk PBX
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY
Contact:
Content-Length: 0
Sep 3 18:01:15 VERBOSE[3158] logger.c: Transmitting (NAT) to 71.x.x.x:51745:
SIP/2.0 401 Unauthorized
Via: SIP/2.0/UDP 71.x.x.x:5060;branch=z9hG4bKc8272c596;received=71.x.x.x
From: 711 ;tag=5f9c8d5e707a967
To: 711 ;tag=as00d21192
Call-ID: 56a4acd85fa339664c7d5c108cc05b9b@71.x.x.x
CSeq: 1840537049 REGISTER
User-Agent: Asterisk PBX
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY
WWW-Authenticate: Digest algorithm=MD5, realm=“asterisk”, nonce="5761e4b4"
Content-Length: 0
Sep 3 18:01:15 VERBOSE[3158] logger.c: Scheduling destruction of call '56a4acd85fa339664c7d5c108cc05b9b@71.x.x.x’ in 15000 ms
Sep 3 18:01:15 VERBOSE[3158] logger.c:
<-- SIP read from 71.x.x.x:51745:
REGISTER sip:192.168.1.140:5060 SIP/2.0
Via: SIP/2.0/UDP 71.x.x.x:5060;branch=z9hG4bK622be4119
Max-Forwards: 70
Content-Length: 0
To: 711
From: 711 ;tag=5f9c8d5e707a967
Call-ID: 56a4acd85fa339664c7d5c108cc05b9b@71.x.x.x
CSeq: 1840537050 REGISTER
Contact: 711 ;expires=300
Allow-Events: talk,hold,conference
Allow:NOTIFY,REFER,OPTIONS,INVITE,ACK,CANCEL,BYE,INFO
Expires: 300
Authorization:Digest response=“6adae960aabee814d4d4696e4aed9e7e”,username=“711”,realm=“asterisk”,nonce=“5761e4b4”,algorithm=MD5,uri="sip:192.168.1.140:5060"
User-Agent: Aastra 9133i/1.4.2.3000 Brcm Callctrl/1.5.1.0 MxSF/v3.2.8.45
Sep 3 18:01:15 VERBOSE[3158] logger.c: — (14 headers 0 lines) —
Sep 3 18:01:15 VERBOSE[3158] logger.c: Using latest REGISTER request as basis request
Sep 3 18:01:15 VERBOSE[3158] logger.c: Sending to 71.x.x.x : 5060 (NAT)
Sep 3 18:01:15 VERBOSE[3158] logger.c: Transmitting (NAT) to 71.x.x.x:51745:
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 71.x.x.x:5060;branch=z9hG4bK622be4119;received=71.x.x.x
From: 711 ;tag=5f9c8d5e707a967
To: 711
Call-ID: 56a4acd85fa339664c7d5c108cc05b9b@71.x.x.x
CSeq: 1840537050 REGISTER
User-Agent: Asterisk PBX
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY
Contact:
Content-Length: 0
Sep 3 18:01:15 VERBOSE[3158] logger.c: Transmitting (NAT) to 71.x.x.x:51745:
SIP/2.0 403 Forbidden (Bad auth)
Via: SIP/2.0/UDP 71.x.x.x:5060;branch=z9hG4bK622be4119;received=71.x.x.x
From: 711 ;tag=5f9c8d5e707a967
To: 711 ;tag=as00d21192
Call-ID: 56a4acd85fa339664c7d5c108cc05b9b@71.x.x.x
CSeq: 1840537050 REGISTER
User-Agent: Asterisk PBX
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY
Content-Length: 0
And for my sip_nat.conf file …
nat=yes
externip=219.x.x.x
externrefresh=5
localnet=192.168.1.0/255.255.255.0