def _parse_response(self, response):
<EOL>response = response.split(b'<STR_LIT:\x00>')[<NUM_LIT:0>]<EOL>if self.realm:<EOL><INDENT>realm = self.realm.encode("<STR_LIT:utf-8>")<EOL>realm = _quote(realm)<EOL><DEDENT>else:<EOL><INDENT>realm = None<EOL><DEDENT>username = None<EOL>cnonce = None<EOL>digest_uri = None<EOL>response_val = None<EOL>authzid = None<EOL>nonce_count = None<EOL>while response:<EOL><INDENT>match = PARAM_RE.match(response)<EOL>if not match:<EOL><INDENT>logger.debug("<STR_LIT>".format(response))<EOL>return Failure("<STR_LIT>")<EOL><DEDENT>response = match.group("<STR_LIT>")<EOL>var = match.group("<STR_LIT>")<EOL>val = match.group("<STR_LIT>")<EOL>logger.debug("<STR_LIT>".format(var, val))<EOL>if var == b"<STR_LIT>":<EOL><INDENT>realm = val[<NUM_LIT:1>:-<NUM_LIT:1>]<EOL><DEDENT>elif var == b"<STR_LIT>":<EOL><INDENT>if cnonce:<EOL><INDENT>logger.debug("<STR_LIT>")<EOL>return Failure("<STR_LIT>")<EOL><DEDENT>cnonce = val[<NUM_LIT:1>:-<NUM_LIT:1>]<EOL><DEDENT>elif var == b"<STR_LIT>":<EOL><INDENT>if val != b'<STR_LIT>':<EOL><INDENT>logger.debug("<STR_LIT>")<EOL>return Failure("<STR_LIT>")<EOL><DEDENT><DEDENT>elif var == b"<STR_LIT>":<EOL><INDENT>digest_uri = val[<NUM_LIT:1>:-<NUM_LIT:1>]<EOL><DEDENT>elif var == b"<STR_LIT>":<EOL><INDENT>authzid = val[<NUM_LIT:1>:-<NUM_LIT:1>]<EOL><DEDENT>elif var == b"<STR_LIT:username>":<EOL><INDENT>username = val[<NUM_LIT:1>:-<NUM_LIT:1>]<EOL><DEDENT>elif var == b"<STR_LIT>":<EOL><INDENT>response_val = val<EOL><DEDENT>elif var == b"<STR_LIT>":<EOL><INDENT>nonce_count = val<EOL>self.last_nonce_count += <NUM_LIT:1><EOL>if int(nonce_count) != self.last_nonce_count:<EOL><INDENT>logger.debug("<STR_LIT>"<EOL>.format(nonce_count, self.last_nonce_count))<EOL>return Failure("<STR_LIT>")<EOL><DEDENT><DEDENT><DEDENT>return self._check_params(username, realm, cnonce, digest_uri,<EOL>response_val, authzid, nonce_count)<EOL>
Parse a client reponse and pass to further processing.

        :Parameters:
            - `response`: the response from the client.
        :Types:
            - `response`: `bytes`

        :return: a challenge, a success indicator or a failure indicator.
        :returntype: `sasl.Challenge`, `sasl.Success` or `sasl.Failure`