Lines Matching refs:resp

218 static int eval_response1(struct dns_response_test *resp, bool unpack_answer)  in eval_response1()  argument
220 uint8_t *ptr = resp->res; in eval_response1()
224 if (resp->res_len < RESPONSE_MIN_SIZE) { in eval_response1()
229 if (dns_unpack_header_id(resp->res) != resp->tid) { in eval_response1()
235 if (dns_header_qr(resp->res) != DNS_RESPONSE) { in eval_response1()
241 if (dns_header_opcode(resp->res) != DNS_QUERY) { in eval_response1()
247 if (dns_header_aa(resp->res) != 0) { in eval_response1()
253 if (dns_header_tc(resp->res) != 0) { in eval_response1()
259 if (dns_header_rd(resp->res) != resp->rd) { in eval_response1()
265 if (dns_header_ra(resp->res) != resp->ra) { in eval_response1()
271 if (dns_header_z(resp->res) != 0) { in eval_response1()
277 if (dns_header_rcode(resp->res) != DNS_HEADER_NOERROR) { in eval_response1()
283 if (dns_header_qdcount(resp->res) != 1) { in eval_response1()
289 if (dns_header_ancount(resp->res) != resp->ancount) { in eval_response1()
295 if (dns_header_nscount(resp->res) != 0) { in eval_response1()
301 if (dns_header_arcount(resp->res) != 0) { in eval_response1()
306 rc = dns_msg_pack_qname(&qname_len, qname, MAX_BUF_SIZE, resp->dname); in eval_response1()
314 if (offset + qname_len + 2 * INT_SIZE >= resp->res_len) { in eval_response1()
319 if (memcmp(qname, resp->res + offset, qname_len) != 0) { in eval_response1()
326 if (dns_unpack_query_qtype(resp->res + offset) != resp->answer_type) { in eval_response1()
331 if (dns_unpack_query_qclass(resp->res + offset) != DNS_CLASS_IN) { in eval_response1()
344 msg.msg = resp->res; in eval_response1()
345 msg.msg_size = resp->res_len; in eval_response1()
359 if (resp->res[offset + 0] != 0xc0 || in eval_response1()
360 resp->res[offset + 1] != 0x0c) { in eval_response1()
366 resp->res += offset; in eval_response1()
370 resp->res) != resp->answer_type) { in eval_response1()
378 resp->res) != DNS_CLASS_IN) { in eval_response1()
385 if (dns_answer_ttl(NAME_PTR_SIZE, resp->res) != resp->ttl) { in eval_response1()
393 resp->res) != resp->rdlen) { in eval_response1()
401 if (resp->rdlen + offset > resp->res_len) { in eval_response1()
406 if (memcmp(resp->res + offset, resp->rdata, resp->rdlen) != 0) { in eval_response1()
411 resp->res = ptr; in eval_response1()