Let’s assume that we have an issue where one has setup LDAP synchronization and authentication on a Cisco Unified Communications Manager (CUCM) cluster but is having an issue with authenticating against LDAP over SSL.
For our example, the LDAP server in question is ad1.mycompany.priv (10.3.2.21). The server is a Microsoft AD server and we are using the default TCP port allocation for LDAP over SSL (which is 636 for Microsoft).
We have decided that we would like to see a sniffer trace (sorry, protocol trace) of the conversation between the CUCM publisher and the LDAP server.
Step 1: Connect to the CUCM Host
Using an SSH client like putty/secureCRT/copSSH connect to the CUCM publisher.
$ ssh email@example.com
Last login: Sat Mar 21 12:51:00 2009 from 192.168.1.4
Welcome to the Platform Command Line Interface
Step 2: Prepare a Capture Trace File
From the admin: prompt, you will use the capture network utility to setup a protocol trace. You can do this live and watch it on the screen if you are simply trying to determine that a conversation is happening or you can capture the output to a file. We are going to do the latter.
admin: utils network capture file mycap count 100000 size all host all 10.3.2.21
Executing command with options:
size=all count=100000 interface=eth0
src= dest= port=
The trace continues until you press Ctrl-C.
Step 3: Download the Trace File
OK, so now you have a file somewhere on the system with the data that you would really like to view. You have to download it to your machine. You will need a running SFTP server on the target machine. You can use openSSH on linux/unix, freeFTPd, copSSH, or something similar.
admin:file get activelog platform/cli/mycap.cap
The size of the file and other information is sent to the output screen. You are prompted for the host name: use DNS or IP address of SFTP server
You are prompted for the port: Defaults to 22 (SSH)
The CUCM checks its local keys and then asks for your user ID and password on the SFTP server.
Step 4: View Trace
After the file has been downloaded, you can view it in whatever protocol analyzer you prefer as long as it support the tcpdump/libpcap format (.cap usual file extension). A good tool is WireShark.
As previously noted you can look at packets live on the CUCM console screen. You can also specify port, source address, destination address, and protocol filters. Enter the command “utils network capture ?” for a list of all options.