'Parse the netntlm server challenge
https://code.google.com/p/python-ntlm/source/browse/trunk/python26/ntlm/ntlm.py'

def parse_netntlm_chal(self, headers, chal_header, ack):

    try:
        header_val2 = headers[chal_header]
    except KeyError:
        return
    header_val2 = header_val2.split('    ', 1)
    if ((header_val2[0] == 'NTLM') or (header_val2[0] == 'Negotiate')):
        msg2 = header_val2[1]
        msg2 = base64.decodestring(msg2)
        self.parse_ntlm_chal(ack, msg2)
