code: def handle_other(self, response):
          
  
          log.debug("handle_other(): Handling: %d" % response.status_code)
  
          if self.mutual_authentication in (REQUIRED, OPTIONAL) and not self.auth_done:
  
              is_http_error = response.status_code >= 400
  
              if _negotiate_value(response) is not None:
                  log.debug("handle_other(): Authenticating the server")
                  if not self.authenticate_server(response):
                      # Mutual authentication failure when mutual auth is wanted,
                      # raise an exception so the user doesn't use an untrusted
                      # response.
                      log.error("handle_other(): Mutual authentication failed")
                      raise MutualAuthenticationError("Unable to authenticate "
                                                      "{0}".format(response))
  
                  # Authentication successful
                  log.debug("handle_other(): returning {0}".format(response))
                  self.auth_done = True
                  return response
  
              elif is_http_error or self.mutual_authentication == OPTIONAL:
                  if not response.ok:
                      log.error("handle_other(): Mutual authentication unavailable "
                                "on {0} response".format(response.status_code))
  
                  if(self.mutual_authentication == REQUIRED and
                         self.sanitize_mutual_error_response):
                      return SanitizedResponse(response)
                  else:
                      return response
              else:
                  # Unable to attempt mutual authentication when mutual auth is
                  # required, raise an exception so the user doesn't use an
                  # untrusted response.
                  log.error("handle_other(): Mutual authentication failed")
                  raise MutualAuthenticationError("Unable to authenticate "
                                                  "{0}".format(response))
          else:
              log.debug("handle_other(): returning {0}".format(response))
              return response
docs: Handles all responses with the exception of 401s.
  
          This is necessary so that we can authenticate responses if requested