Cisco 7960 / Cisco 7961 not registering

This week i changed from Trixbox to FreePBX Distro because of the asterisk 1.8 support. I have tried to migrate all settings to the FreePBX installation and much of it is working.

However i cannot get the Cisco 7960/7961 phones to register. I have copied the tftpboot files from Trixbox to FreePBX so the should have worked but the phone wil nog register. After this i have tried to make new configurations using PBX End Point Manager 2.9.1.2 by Andrew Nagy but the problem still occurs

When i make a tcpdump i get the following information

tcpdump -i eth1 -n -s 0 port 5060 -v and host 192.168.110.118

16:25:00.508166 IP (tos 0x60, ttl  62, id 37873, offset 0, flags [none], proto: UDP (17), length: 726) 192.168.110.118.50700 > 192.168.120.222.sip: SIP, length: 698
	REGISTER sip:192.168.120.222 SIP/2.0
	Via: SIP/2.0/UDP 192.168.110.118:5060;branch=z9hG4bK51a07556
	From: <sip:[email protected]>;tag=001ebe9059fc003252f4157d-5b8238a0
	To: <sip:[email protected]>
	Call-ID: [email protected]
	Max-Forwards: 70
	Date: Thu, 17 Dec 2009 11:22:30 GMT
	CSeq: 149 REGISTER
	User-Agent: Cisco-CP7961G/8.5.3
	Contact: <sip:[email protected]:5060;transport=udp>;+sip.instance="<urn:uuid:00000000-0000-0000-0000-001ebe9059fc>";+u.sip!model.ccm.cisco.com="30018"
	Supported: (null),X-cisco-xsi-7.0.1
	Content-Length: 0
	Reason: SIP;cause=200;text="cisco-alarm:20 Name=SEP001EBE9059FC Load=SIP41.8-5-4S Last=phone-keypad"
	Expires: 3600
	
	
16:25:00.508491 IP (tos 0x60, ttl  64, id 24300, offset 0, flags [none], proto: UDP (17), length: 478) 192.168.120.222.sip > 192.168.110.118.50700: SIP, length: 450
	SIP/2.0 100 Trying
	Via: SIP/2.0/UDP 192.168.120.222:5060;branch=z9hG4bK51a07556;received=192.168.110.118
	From: <sip:[email protected]>;tag=001ebe9059fc003252f4157d-5b8238a0
	To: <sip:[email protected]>
	Call-ID: [email protected]
	CSeq: 149 REGISTER
	Server: FPBX-2.9.0(1.8.6.0)
	Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
	Supported: replaces, timer
	Content-Length: 0
	
	
16:25:00.508643 IP (tos 0x60, ttl  64, id 24301, offset 0, flags [none], proto: UDP (17), length: 575) 192.168.120.222.sip > 192.168.110.118.50700: SIP, length: 547
	SIP/2.0 401 Unauthorized
	Via: SIP/2.0/UDP 192.168.120.222:5060;branch=z9hG4bK51a07556;received=192.168.110.118
	From: <sip:[email protected]>;tag=001ebe9059fc003252f4157d-5b8238a0
	To: <sip:[email protected]>;tag=as05cf9a01
	Call-ID: [email protected]
	CSeq: 149 REGISTER
	Server: FPBX-2.9.0(1.8.6.0)
	Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
	Supported: replaces, timer
	WWW-Authenticate: Digest algorithm=MD5, realm="asterisk", nonce="1a31d0d9"
	Content-Length: 0
	

sip_additional.conf


[89]
deny=0.0.0.0/0.0.0.0
secret=45fgsdaas
dtmfmode=rfc2833
canreinvite=no
context=from-internal
host=dynamic
trustrpid=yes
sendrpid=no
type=friend
nat=never
port=5060
qualify=yes
qualifyfreq=60
transport=udp
encryption=no
callgroup=
pickupgroup=
dial=SIP/89
mailbox=89@device
permit=0.0.0.0/0.0.0.0
callerid=device <89>
callcounter=yes
faxdetect=no
cc_monitor_policy=generic

/tftpboot/SEP


<device>

  <deviceProtocol>SIP</deviceProtocol>

  <sshUserId>admin</sshUserId>
  <sshPassword>cisco</sshPassword>

  <devicePool>
        <dateTimeSetting>
                <dateTemplate>M/D/Ya</dateTemplate>
                <timeZone>Central Standard/Daylight Time</timeZone>
                <ntps>
                        <ntp>
                                <name>0.pool.ntp.org</name>
                                <ntpMode>Unicast</ntpMode>
                        </ntp>
                </ntps>
        </dateTimeSetting>

     <callManagerGroup>
        <members>
           <member priority="0">
              <callManager>
                 <ports>
                    <ethernetPhonePort>2000</ethernetPhonePort>
                    <sipPort>5060</sipPort>
                    <securedSipPort>5061</securedSipPort>
                 </ports>
                 <processNodeName>192.168.120.222</processNodeName>
              </callManager>
           </member>
        </members>
     </callManagerGroup>
  </devicePool>

  <commonProfile>
     <phonePassword></phonePassword>
     <backgroundImageAccess>true</backgroundImageAccess>
     <callLogBlfEnabled>2</callLogBlfEnabled>
  </commonProfile>

  <loadInformation>SIP41.8-5-4S</loadInformation>

  <vendorConfig>
     <disableSpeaker>false</disableSpeaker>
     <disableSpeakerAndHeadset>false</disableSpeakerAndHeadset>
     <pcPort>0</pcPort>
     <settingsAccess>1</settingsAccess>
     <garp>0</garp>
     <voiceVlanAccess>0</voiceVlanAccess>
     <videoCapability>0</videoCapability>
     <autoSelectLineEnable>0</autoSelectLineEnable>

     <webAccess>1</webAccess>
     <spanToPCPort>1</spanToPCPort>
     <loggingDisplay>1</loggingDisplay>
     <loadServer></loadServer>
  </vendorConfig>

  <networkLocale>United_States</networkLocale>

        <networkLocaleInfo>
                <name>United_States</name>
                <uid>64</uid>
                <version>1.0.0.0-1</version>
        </networkLocaleInfo>

  <deviceSecurityMode>0</deviceSecurityMode>
  <authenticationURL></authenticationURL>
  <directoryURL></directoryURL>
  <idleURL></idleURL>
  <informationURL></informationURL>

  <messagesURL></messagesURL>
  <proxyServerURL></proxyServerURL>
  <servicesURL></servicesURL>
  <dscpForSCCPPhoneConfig>96</dscpForSCCPPhoneConfig>
  <dscpForSCCPPhoneServices>0</dscpForSCCPPhoneServices>
  <dscpForCm2Dvce>96</dscpForCm2Dvce>

  <transportLayerProtocol>4</transportLayerProtocol>

  <capfAuthMode>0</capfAuthMode>
  <capfList>
     <capf>
        <phonePort>3804</phonePort>
     </capf>
  </capfList>

  <certHash></certHash>
  <encrConfig>false</encrConfig>

   <sipProfile>
     <sipProxies>
        <backupProxy></backupProxy>
        <backupProxyPort></backupProxyPort>
        <emergencyProxy></emergencyProxy>
        <emergencyProxyPort></emergencyProxyPort>
        <outboundProxy></outboundProxy>
        <outboundProxyPort></outboundProxyPort>
        <registerWithProxy>true</registerWithProxy>
     </sipProxies>

     <sipCallFeatures>
        <cnfJoinEnabled>true</cnfJoinEnabled>
        <callForwardURI>x--serviceuri-cfwdall</callForwardURI>
        <callPickupURI>x-cisco-serviceuri-pickup</callPickupURI>
        <callPickupListURI>x-cisco-serviceuri-opickup</callPickupListURI>
        <callPickupGroupURI>x-cisco-serviceuri-gpickup</callPickupGroupURI>
        <meetMeServiceURI>x-cisco-serviceuri-meetme</meetMeServiceURI>
        <abbreviatedDialURI>x-cisco-serviceuri-abbrdial</abbreviatedDialURI>
        <rfc2543Hold>true</rfc2543Hold>
        <callHoldRingback>2</callHoldRingback>
        <localCfwdEnable>true</localCfwdEnable>
        <semiAttendedTransfer>true</semiAttendedTransfer>
        <anonymousCallBlock>2</anonymousCallBlock>
        <callerIdBlocking>2</callerIdBlocking>
        <dndControl>0</dndControl>
        <remoteCcEnable>true</remoteCcEnable>
     </sipCallFeatures>

     <sipStack>
        <sipInviteRetx>6</sipInviteRetx>
        <sipRetx>10</sipRetx>
        <timerInviteExpires>180</timerInviteExpires>
        <timerRegisterExpires>3600</timerRegisterExpires>
        <timerRegisterDelta>5</timerRegisterDelta>
        <timerKeepAliveExpires>120</timerKeepAliveExpires>
        <timerSubscribeExpires>120</timerSubscribeExpires>
        <timerSubscribeDelta>5</timerSubscribeDelta>
        <timerT1>500</timerT1>
        <timerT2>4000</timerT2>
        <maxRedirects>70</maxRedirects>
        <remotePartyID>false</remotePartyID>
        <userInfo>None</userInfo>
     </sipStack>

     <autoAnswerTimer>1</autoAnswerTimer>
     <autoAnswerAltBehavior>false</autoAnswerAltBehavior>
     <autoAnswerOverride>true</autoAnswerOverride>
     <transferOnhookEnabled>false</transferOnhookEnabled>
     <enableVad>false</enableVad>
     <preferredCodec>none</preferredCodec>
     <dtmfAvtPayload>101</dtmfAvtPayload>
     <dtmfDbLevel>3</dtmfDbLevel>
     <dtmfOutofBand>avt</dtmfOutofBand>
     <alwaysUsePrimeLine>false</alwaysUsePrimeLine>
     <alwaysUsePrimeLineVoiceMail>false</alwaysUsePrimeLineVoiceMail>
     <kpml>3</kpml>

     <natEnabled>false</natEnabled>
     <natAddress></natAddress>


     <stutterMsgWaiting>0</stutterMsgWaiting>

     <callStats>false</callStats>
     <silentPeriodBetweenCallWaitingBursts>10</silentPeriodBetweenCallWaitingBursts>
     <disableLocalSpeedDialConfig>false</disableLocalSpeedDialConfig>


     <startMediaPort>16384</startMediaPort>
     <stopMediaPort>32766</stopMediaPort>

         <voipControlPort>5060</voipControlPort>
     <dscpForAudio>184</dscpForAudio>
     <ringSettingBusyStationPolicy>0</ringSettingBusyStationPolicy>
     <dialTemplate>dialplan.xml</dialTemplate>

         <phoneLabel>x89</phoneLabel>
     <sipLines>

        <line button="1">
           <featureID>9</featureID>
           <featureLabel>89</featureLabel>
                   <name>89</name>
                   <displayName>Cisco7961</displayName>
                   <contact>89</contact>

           <proxy>192.168.120.222</proxy>
           <port>5060</port>
           <autoAnswer>
              <autoAnswerEnabled>2</autoAnswerEnabled>
           </autoAnswer>
           <callWaiting>3</callWaiting>

           <authName>89</authName>
           <authPassword>45fgsdaas</authPassword>

           <sharedLine>false</sharedLine>
           <messageWaitingLampPolicy>1</messageWaitingLampPolicy>
           <messagesNumber>*97</messagesNumber>
           <ringSettingIdle>4</ringSettingIdle>
           <ringSettingActive>5</ringSettingActive>

           <forwardCallInfoDisplay>
              <callerName>true</callerName>
              <callerNumber>false</callerNumber>
              <redirectedNumber>false</redirectedNumber>
              <dialedNumber>true</dialedNumber>
           </forwardCallInfoDisplay>
        </line>

     </sipLines>
  </sipProfile>
</device>

Just try the SEP files in this link.

I would use the endpoint manager for your config.

Also make sure that NAT is set to NO in the extension.

I already used the endpoint manager for my config and the config looks fine. Also the config on the phone looks fine but still no succesful register

I think it has something to do with Asterisk 1.8 in conjunction with the cisco phones.

This is one dump of a working Speedtouch 780


04:48:21.923762 IP (tos 0x90, ttl  62, id 296, offset 0, flags [none], proto: UDP (17), length: 762) 192.168.110.242.sip > 192.168.120.222.sip: SIP, length: 734
	REGISTER sip:192.168.120.222:5060;transport=UDP SIP/2.0
	From: <sip:[email protected]:5060>;tag=80ad3e08-c0a86ef2-13c4-26-47ffe5d6-26
	To: <sip:[email protected]:5060>
	Call-ID: 80f4f964-c0a86ef2-13c4-26-3b4dd1aa-26
	CSeq: 2 REGISTER
	Via: SIP/2.0/UDP 192.168.110.242:5060;branch=z9hG4bK-26-961e-73c33a2d
	Max-Forwards: 70
	Supported: replaces,100rel
	User-Agent: SpeedTouch 780
	X-Serialnumber: CP0649JT0J2
	Accept: application/dtmf-relay, x-application/dtmf-relay, application/sdp
	Contact: <sip:[email protected]:5060>
	Expires: 60
	Authorization: Digest username="83",realm="asterisk",nonce="584f27ba",uri="sip:192.168.120.222:5060;transport=UDP",response="896d48c364dab89a256513c6be028780",algorithm=MD5
	Content-Length: 0
	


04:48:21.924090 IP (tos 0x60, ttl  64, id 46533, offset 0, flags [none], proto: UDP (17), length: 485) 192.168.120.222.sip > 192.168.110.242.sip: SIP, length: 457
	SIP/2.0 100 Trying
	Via: SIP/2.0/UDP 192.168.120.222:5060;branch=z9hG4bK-26-961e-73c33a2d;received=192.168.110.242
	From: <sip:[email protected]:5060>;tag=80ad3e08-c0a86ef2-13c4-26-47ffe5d6-26
	To: <sip:[email protected]:5060>
	Call-ID: 80f4f964-c0a86ef2-13c4-26-3b4dd1aa-26
	CSeq: 2 REGISTER
	Server: FPBX-2.9.0(1.8.6.0)
	Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
	Supported: replaces, timer
	Content-Length: 0
	


04:48:21.924672 IP (tos 0x60, ttl  64, id 46535, offset 0, flags [none], proto: UDP (17), length: 597) 192.168.120.222.sip > 192.168.110.242.sip: SIP, length: 569
	SIP/2.0 200 OK
	Via: SIP/2.0/UDP 192.168.120.222:5060;branch=z9hG4bK-26-961e-73c33a2d;received=192.168.110.242
	From: <sip:[email protected]:5060>;tag=80ad3e08-c0a86ef2-13c4-26-47ffe5d6-26
	To: <sip:[email protected]:5060>;tag=as237557aa
	Call-ID: 80f4f964-c0a86ef2-13c4-26-3b4dd1aa-26
	CSeq: 2 REGISTER
	Server: FPBX-2.9.0(1.8.6.0)
	Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
	Supported: replaces, timer
	Expires: 60
	Contact: <sip:[email protected]:5060>;expires=60
	Date: Fri, 23 Sep 2011 08:48:21 GMT
	Content-Length: 0


In the Asterisk extensions, via FreePBX make sure NAT is set to no for the extension. It will then work fine.

Yesterday i found a fix for the registration problem. It also solved the issue of oneway voice wich was there. But i did not notice because the problem only occured on inbound connections.

The problem is created by SIP NAT however the asterisk machine just has an public ip on wan and a private ip on lan. The same setup is working fine on my older trixbox machine. But now i have installed the same version of shorewall the issue occurs.

So i disabled SIP NAT and conntrack

vim /etc/shorewall/start

rmmod ip_nat_sip &> /dev/null
rmmod ip_conntrack_sip &> /dev/null 

return 0

Hello,

I’ve found out about this thread on a google search and I wanted to share a fix which resolved my problem.

Setup is the same as raymonvdm; asterisk is on public ip, cisco 7970G is behind NAT. Phone doesn’t register with “SIP/2.0 401 Unauthorized” error.

The problem lies behind the following tag:

false

You have to have this in your SEPmac.cnf.xml

In my tests with 7960, this tag is working as it should (quick google search will tell you what natReceivedProcessing is), but in 7970 firmwares before 9.x it’s giving the dreaded “Supported: (null),X-cisco-xsi-7.0.1” in reg request which causes 401 error. I’ve tried every firmware and I’ve found the working firmware: cmterm-7970_7971-sip.9-3-1SR1-1

Quick google search will find you cmterm-7970_7971-sip.9-3-1SR1-1.zip (for those doesn’t have cisco license) but you’ll find that the file is corrupted and I heard that it is corrupted on the cisco website too. So we’ll do a little hack.

Download cmterm-7970_7971-sip.9-3-1SR1-1.cop.sgn (you’ll also easily find this) and modify the hex values according to the following website:

http://www.ipcommute.co.uk/technical-articles/19--how-to-extract-the-contents-cisco-cop-files.html

Now that you have the firmware, upload it to your phone and edit the sepmac.cnf.xml file to include this:

true
router WAN ip
false

this should make your 7970G work. good luck!

sorry, messed up the code.
the part that says “false” only should be as follows:
false

also “true
router WAN ip
false” should be:

true
wan ip
false

wow, I totally missed that this thread is about 7960. :slight_smile:

anyway, at least natReceivedProcessing should be false for 7960 too :slight_smile: