Contacts on Cisco CP79xx


I’m trying to get my contactsmanager contacts onto some cisco phones. They work just fine on the Sangoma phones using DPMA. The ciscos are being provisioned with TFTP which works fine, the basefile shows this config: provisionAddress/cisco/xmlservices/PhoneDirectory.php for directory_url. However within the tftpboot directory there is no folder for cisco… was this supposed to be auto generated or is the .php file something I have to create myself?

There is no working phone book for Cisco phones on a freePBX system. You have to built it yourself or search the www. The 79xx phones are 20 years old, aren’t they? And they do not support the SIP-standard very well. To get the BLF-buttons to work you have to patch Asterisk.

Charles, thank you for the info… I have an XML now. I place it in /var/www/html and it adds the “External directory” but when opening this on the phone it says 403 forbidden cmxml error… tried making this xml and php but may be doing something incorrectly here.

I was curious if you either know how this should be formatted if I send what I have or if there is a log in freepbx that may show what’s happening. I used “core set debug 10” and “core set verbose 10” but I’m not seeing anything useful as far as the directory issue.


Again…configuring a Cisco 79xx as a SIP-phone, which perfectly works with Asterisk/freePBX will take many days…even weeks!!!
Here is some info for you…

I believe the files written correct per -

I’m just getting an error 403 forbidden which I’m assuming means the phone doesn’t have access to open this file. Is there any documentation on what permissions files need set? I ran fwconsole chown and also tried chown +x but this didn’t make a difference.

In /var/log/gttpd/error_log the phone keeps receving AH01630: client denied by server configuration: /invalid when reaching out to the .xml in /var/www/html.
I have run fwconsole chown as well as chown asterisk:asterisk directory.xml
Sangoma phones can provision just fine through HTTPS, I have provisioning protocols set to BOTH. Tried None and this didn’t change anything…

If anyone has insight to what may be causing this that would help alot!

Did you read it?

I did however this is talking about setting up the cisco callmanager app in asterisk… I wanted to avoid doing this if possible as it involves “patching” asterisk and creating more headaches rather than being able to just use an xml file.

The xml-phonebook does not need a patched asterisk, but the Cisco needs a proper authentication…

If defined, the phone will make requests to this URL containing the username and password that was included in the Authorization header in the request to http://x.x.x.x/CGI/Execute. See CGI Execute for more information.

The script handling the request must respond exactly with AUTHORIZED (with no newline character at end) otherwise the request will be denied. Example below provides this on /authentication.

The phone is registering via the PJSIP registration (using the SIP Secret)… just making sure is the authenticationURL seperate from this? If so where in asterisk/freepbx would you configure this username/password so it matches what’s entered in the authenticationURL Script?

Yes, it has nothing to do with SIP/PJSIP…it’s a http request to a remote web server…

Well that… somewhat makes sense, not sure what I’m doing wrong as I’m still getting the exact same error.

I copied their authorizationURL script to a .xml file with just that and filled in the username and password…

Then I copied the CiscoIPPhoneExecute command into a SEPMAC.cnf.xml file along with a parameter to look at the authentication file like this:

<?xml version="1.0" encoding="utf-8"?>
<loadInformation model="IP Phone 7960">P0S3-08-8-00</loadInformation> 
<ExecuteItem URL="http://pbxFQDN/directory.xml" Priority="0" />

Do I need the rest of the script from: CGI Execute
If so are you able to tell me where/how this needs formatted to execute? Also would the logs for this just go to /var/log/full when Core set debug on is set or is there somewhere else I need to check for the error logs?

I appreciate the help!

Sorry, I cannot help you further…
I actually have a dozen Cisco 8961s, which work with a freePBX 16 (patched Asterisk) system. The Ciscos use adapted xmlservices files (original files from a Trixbox machine) to access a local LDAP-phonebook-server.
Unfortunately, I did this years ago…it was very, very complicated…and I cannot remember the whole procedure anymore. There are user credentials in my scripts…somewhere…therefore I cannot share them.

Here is some more Info…

Charles, thanks for looking into this more.

I have a “working solution” for now. The XML I have actually works (though it’s static and I’ll need to manually modify any additions or removals. But this is just to get contacts working and the hope is swapping these to Digium/Sangoma phones as they fail or funds open up…

The one issue I’m having now is to fix the “403 forbidden” error this was being caused by the Let’s Encrypt port being bound in “Port management”. I needed to remove this and in /etc/httpd/conf.d/schmoozecom.conf/ manually add “Listen 80” on it’s own so it doesn’t redirect to Admin GUI/UCP, etc.
The issue here is any changes to ports will override this, I’m also afraid any updates may change this as well… if you or anyone else know of a more permanent fix for this port issue it would be appreciated!

You can manage and assign ports under Admin → System Admin → Port Management. Disable Let’s encrypt there and change the default Admin HTTP port to something else.

This is just for static XML’s, not the actual admin page. If I do this it will redirect to the admin GUI instead of loading the directory.xml file.

Actually just added a new .conf file that just contains the “Listen 80” command so it doesn’t get overwritten by the “Port management” menu.

If anyone has the same issue and wants to do what I did: (works with CP7960 and CP7940)
Create a .xml file with the following info:

                <Name>Lastname, Firstname</Name>
                <Name>Lastname, Firstname</Name>

Repeat the Directory entries for each contact you need to add, save this to /var/www/html as “directory.xml” (whatever you wanna name it).

In /etc/httpd/conf.d/ create a new file (I made Port80.conf) enter

Listen 80

Save this file.

In EPM modify the basefile for the phone you’re adding this to, in the “directoryURL” add http://servername or IP/directory.xml and then it should load this on the phone as “External directory” and show the contacts you created. Hope this helps someone!

As far as I remember, the Cisco 79xx phones can only display 25 entries or so per page. Therefore I created a menu, which let you choose between 3-letter pages (ABC, DEF, etc), which point to single letter XML lists for every letter in the alphabet.

That’s true I forgot they’re limited to 32 entries. Are you able to share the code that creates this?