Cisco 6941 IP Phone Services fail on 302

Version 1
    This document was generated from CDN thread

    Created by: Richard Siebels on 12-11-2010 07:51:13 PM
    I have an app that has been running successfully on 79XX phones. We recently added 6941 phones running firware 9.0(2) and wireshark shows that when the app tells the phone to redirect (after login) the phone just sits there with "Requesting". The app flow is:
    prompt user for login credentials
    submit to url
    server validates login then redirects to welcome page if successful, if not successful redirects to login page
     
    Are there any known bugs with this on these phones? Any help is greatly appreciated.

    Subject: RE: Cisco 6941 IP Phone Services fail on 302
    Replied by: David Staudt on 12-11-2010 08:36:24 PM
    Now aware of any issues...can you post a network packet capture (Wireshark) from the phone's PC swtich port covering the transaction?

    Subject: RE: Cisco 6941 IP Phone Services fail on 302
    Replied by: Richard Siebels on 12-11-2010 10:06:14 PM
    Now aware of any issues...can you post a network packet capture (Wireshark) from the phone's PC swtich port covering the transaction?


    Thanks for the quick reply. Here is a wireshark. If you dig into it you can see the 7940 which is successful and the 6941 which is not. The only difference in the data streams is the user info since the owners of the phones are different.

    Subject: RE: Cisco 6941 IP Phone Services fail on 302
    Replied by: Richard Siebels on 13-11-2010 01:47:41 PM
    I filtered te file to the http requests only and not the typical phone traffic. I captured the information via the switch by spanning the ports (phone and PC). If needed I can enable span port to PC in CUCM and connect to the phone directly if it makes a difference.
     
    When we deployed the phones they were on 9.0(2) I upgraded this phone to 9.0(3b) as a first step in troubleshooting. The traces are from the upgraded version.
     
    Thanks for the help, let me know what else I can do to assist.
     
     

    Subject: RE: Cisco 6941 IP Phone Services fail on 302
    Replied by: Richard Siebels on 13-11-2010 09:12:31 PM
    Here are two files. There is a lot of other traffic in these as I did not filter when saving. The 6941login file shows the requests froth 6941 and the 7940login shows the proper handling of the 302. Hopefully these will provide more detail.

    On the 6941login the Frame numbers associated are 75,78,94,97
    75 is initial invocation of service
    78 is response from server providing the login page xml contains CiscoIPPhoneInput
    94 is phone submitting credentials to server
    97 is response from server after successful authentication redirecting the phone to the welcome page


    On the 7940 login the Frame numbers associated are 34, 39, 150, 153, 160, 164, 267, 270, 277, and 280
    34 is initial invocation of service
    39 is response from server providing the login page xml contains CiscoIPPhoneInput
    150 is submission without PIN
    153 is response from server with 302 notice the location takes it back to the login page with session data
    160 is phone successfully redirecting
    164 is server providing xml with prompt of invalid login and the login form
    267 is phone submitting request with username and PIN
    270 is response from server after successful authentication redirecting the phone to the welcome page
    277 is phone successfully redirecting to welcome page
    280 is server responding with xml for display of welcome page

    I hope this detail will help isolate issue.

    Thanks again for your continued assistance.

    Subject: RE: Cisco 6941 IP Phone Services fail on 302
    Replied by: David Staudt on 12-11-2010 11:46:25 PM
    There seem to be some missing packets or other strangeness in the pcap..?  Was this taken from the phone's switch port with proper speed/duplex settings?
     
    Have you tried using the latest firmware version available on Cisco.com?

    Subject: RE: Cisco 6941 IP Phone Services fail on 302
    Replied by: David Staudt on 13-11-2010 04:58:51 PM
    Yeah please try connecting to the phone directly...it appears many packets - including the redirect, etc. - are missing.

    Subject: RE: Cisco 6941 IP Phone Services fail on 302
    Replied by: Richard Siebels on 16-11-2010 03:25:46 PM
    Just following up to see if any additional thoughts or information came out of the last traces.
     
    I really need to get this resolved. Thanks in advance.

    Subject: RE: Cisco 6941 IP Phone Services fail on 302
    Replied by: David Staudt on 16-11-2010 03:28:59 PM
    Thanks for the pcaps, looks like it clearly shows the problem.  Two things:
     
    - Each 302 packet has an HTTP body composed of a bunch of white space characters: CR, LF, tabs.  Any reason for this?  Perhaps the 6941 phone is finding this invalid and ignoring the packet.  Any chance you can avoid sending this stuff?
    - If after correcting the above, problem still remains, please go ahead and grab the phone console logs (and fresh pcaps.)  These should be available by browsing to the phone's IP address

    Subject: RE: Cisco 6941 IP Phone Services fail on 302
    Replied by: Richard Siebels on 16-11-2010 04:00:37 PM
    This is a result of the code that is validating the login. I can suppress the output of the script to remove the whitespace and chr10 chr13.
     
    I will let you know if this resolves it.
     
    Thanks!

    Subject: RE: Cisco 6941 IP Phone Services fail on 302
    Replied by: David Staudt on 06-12-2010 06:28:36 PM
    The only other item I can spot is that the 'Location:' header on the http 302 packet starts with a lowercase L:
     

    HTTP/1.1 302 Moved Temporarily
    Connection: close
    Date: Mon, 06 Dec 2010 15:48:43 GMT
    Server: Microsoft-IIS/6.0
    X-Powered-By: ASP.NET
    Set-Cookie: CFID=355376;path=/
    Set-Cookie: CFTOKEN=92333000;path=/
    location: http://10.0.0.235/TimeClock/webservices/welcome.cfm?CFID=355376&CFTOKEN=92333000
    Content-Type: text/html; charset=UTF-8

     
    Not sure if that would cause the phone to ignore it as unrecognized.

    Subject: RE: Cisco 6941 IP Phone Services fail on 302
    Replied by: Richard Siebels on 06-12-2010 08:52:34 PM
    Thank you very much!!! I cannot believe that was the issue. I forced the header value to uppercase "Location" and hte 6941 followed the redirect.
     
    All the other phones we have (79XX, 89XX, 99XX) worked with the lowercase "l". I guess the 69XX is a little less forgiving.
     
    Thanks for the help working through this.I wish there was a way I could repay you for your help.
     
    Have a wonderful holiday.

    Subject: RE: Cisco 6941 IP Phone Services fail on 302
    Replied by: Richard Siebels on 06-12-2010 04:01:50 PM
    Sorry for the long delay. I tried doing other research and trila and error. I thought that maybe it was a HTTP1.1 issue and I tried to use 303 and 307 redirects rather than 302. That gave me weird results and the phone returned "Unknown Error" then reverted to the prior page.
     
    Anyways, here is the updata pcap with whitespace removed (it did not fix the issue) and the console logs. I thought the below was interesting from the console logs and tried searching for similar info on it but found nothing.
     
    xml_service_convert_cardcontent(4504) HTTP 302
    parse_get_xml_tag 1044:tagName do
    parse_get_xml_tag 1045:error
    xmlDocPtr
     
     
    windmlui_interval_check_new 440: partp is null.
    xml_http_callback(6690) http redirect http://10.0.0.235/TimeClock/webservices/welcome.cfm
    CFID=355376&CFTOKEN=92333000
     
    Hopefully we can find the root cause and get this resolved.