D OCUMENTO DE C ONSENTIMIENTO
15. I like to work individually
3.2 Valeria’s Interview Entrevista número
The venerable old C7960 is now a part of VoIP history. One of the first SIP telephones that could actually be taken seriously, the only real complaint one can have about this phone is the price: they are the Cadillac of SIP phones (meaning that they have all the bells and whistles but are tough to justify at the price, and are a little out of date sometimes).
If you can get one of these, you are getting an excellent SIP telephone. If you buy one new, be prepared to pay.
One of the ways this phone is out of date is the lack of remote provisioning from any- thing other than TFTP. TFTP has lost favor with networking professionals due to the lack of authentication and encryption, but since it is the only method of remotely pro- visioning the phone, we are going to have to use the tftp-server daemon. We can install tftp-server with the following command:
# yum install -y tftp-server
Once installed, we need to enable the server by modifying the /etc/xinetd.d/tftp file. To enable the TFTP server, change the disable=yes line to disable=no.
service tftp { socket_type = dgram protocol = udp wait = yes user = root server = /usr/sbin/in.tftpd server_args = -s /tftpboot disable = no per_source = 11 cps = 100 2 flags = IPv4 }
Then start the TFTP server by running:
# service xinetd restart
We can verify the server is running with the following command:
# chkconfig --list | grep tftp
tftp: on
As long as tftp: on was returned, the server is up and running. Gotchas.
Cisco phones by default are loaded with their own communication pro- tocol known as SCCP (or Skinny). We will be showing you how to configure the phone, but due to the proprietary nature of Cisco and its phones, you will need to obtain the SIP firmware from your distributor. Also, there are both chan_sccp and chan_skinny modules for Asterisk, but they are beyond the scope of this book.
We will be registering our Cisco phone to the SIP friend we configured in “Zaptel Hardware Configuration.” The following configuration file should be saved into a file taking the format of SIP<mac>.cnf, where <mac> represents the MAC address of the telephone device you are configuring. Place this file into the /tftpboot/ directory on your server:
# Line 1 Configuration line1_name: "1000" line1_authname: "1000"
line1_shortname: "Jimmy Carter" line1_password: ""
line1_displayname: ""
# The phone label, displayed in the upper-righthand corner of the phone phone_label: "aristotle" ; Has no effect on SIP messaging
# Phone password used for console or telnet access, limited to 31 characters phone_password: "cisco"
Then configure the address to register in the SIPDefault.cnf file, also placed in the /tftpboot/ directory of your server. proxy1_address will contain the IP address of your Asterisk server of where the phone should register for line 1. The image_version contains the version of the .loads and .sb2 files the phone will load into memory.
image_version: P0S3-08-4-00 proxy1_address: 192.168.1.100
We need one additional file called OS79XX.TXT. This file contains only a single line―the .bin and .sbn file version to load into memory:
P003-08-4-00
In order for our Cisco 7960 to use these files, we need to tell the phone where to pull its configuration from. If using the DHCP server from your Linux server, you can modify the /etc/dhcpd.conf file in order to tell the phone where to pull its configuration from by adding the line:
option tftp-server-name "192.168.1.100";
which contains the IP address of the server hosting the TFTP server (assuming of course the TFTP server is configured at that address. This is the address we’ve been using for our Asterisk server, and we again assume you’ve installed the TFTP server on the same box as Asterisk). See “DHCP server” for more information about configuring the DHCP server:
ddns-update-style interim; ignore client-updates; subnet 192.168.1.0 netmask 255.255.255.0 { option routers 192.168.1.1; option subnet-mask 255.255.255.0; option domain-name-servers 192.168.1.1; option tftp-server-name "192.168.1.100";
option ntp-servers pool.ntp.org; option time-offset -18000;
range dynamic-bootp 192.168.1.128 192.168.1.254; default-lease-time 21600;
max-lease-time 43200; }
Alternatively, you can configure from the phone itself to manually use an alternative TFTP server than that given by the DHCP server. To do so, press the settings button, (on the G version of the Cisco phones, this looks like a square with a check mark inside of it; G means Global). You will then need to unlock the settings by pressing the 9 key. The default password is cisco. Once the phone is unlocked, press the 3 key on the dialpad to enter the Network Configuration. Scroll down to option 32 and set the Alternate TFTP to YES. Then scroll up to option 7 and enter the IP address of the TFTP server you wish to boot from. Accept the settings and back out of the menu until the phone reboots itself. You can also use the *-6-settings three finger salute to reboot your phone at any time.
You can watch the phone pull its configuration from the TFTP server by using tshark (yum install ethereal). Filter on port 69 using the following command:
# tshark port 69
You should then be able to watch the network traffic from the phone requesting data from your TFTP server.
If all goes well, then you should see your phone registered to Asterisk!