'Analyze a 401 response and report it.
:return: None'

def _analyze_401(self, response):

    realm = self._get_realm(response)
    if (realm is None):
        self._report_no_realm(response)
        return
    insecure = (response.get_url().get_protocol() == 'http')
    vuln_severity = (severity.HIGH if insecure else severity.LOW)
    desc = 'The    resource:    "%s"    requires    HTTP    authentication'
    if insecure:
        desc += '    over    a    non-encrypted    channel,    which    allows    potential    intruders    to    sniff    traffic    and    capture    valid    credentials.'
    else:
        desc += '.'
    desc += '    The    received    authentication    realm    is:    "%s".'
    desc = (desc % (response.get_url(), realm))
    if ('ntlm' in realm.lower()):
        v = Vuln('NTLM    authentication', desc, vuln_severity, response.id, self.get_name())
    else:
        v = Vuln('HTTP    Basic    authentication', desc, vuln_severity, response.id, self.get_name())
    v.set_url(response.get_url())
    v['message'] = realm
    v.add_to_highlight(realm)
    kb.kb.append(self, 'auth', v)
    om.out.information(v.get_desc())
