Lines Matching defs:rep

364 	if(must_validate && (msg->rep->security == sec_status_bogus ||
365 msg->rep->security == sec_status_secure_sentinel_fail)) {
368 } else if(msg->rep->security == sec_status_unchecked && must_validate) {
372 } else if(msg->rep->security == sec_status_secure &&
373 !reply_all_rrsets_secure(msg->rep) && must_validate) {
426 struct edns_data* edns, struct comm_reply* rep, uint16_t qid,
436 struct sldns_buffer* r_buffer = rep->c->buffer;
438 if(rep->c->tcp_req_info) {
439 r_buffer = rep->c->tcp_req_info->spool_buffer;
441 if(!infra_wait_limit_allowed(mesh->env->infra_cache, rep,
445 comm_point_drop_reply(rep);
453 if(!mesh_make_new_space(mesh, rep->c->buffer)) {
456 comm_point_drop_reply(rep);
467 comm_point_drop_reply(rep);
482 LDNS_RCODE_SERVFAIL, edns, rep, mesh->env->scratch, mesh->env->now_tv))
486 comm_point_send_reply(rep);
501 NULL, LDNS_RCODE_SERVFAIL, edns, rep, mesh->env->scratch, mesh->env->now_tv))
505 comm_point_send_reply(rep);
527 if(!mesh_state_add_reply(s, edns, rep, qid, qflags, qinfo)) {
531 if(rep->c->tcp_req_info) {
532 if(!tcp_req_info_add_meshstate(rep->c->tcp_req_info, mesh, s)) {
537 if(rep->c->use_h2) {
538 http2_stream_add_meshstate(rep->c->h2_stream, mesh, s);
556 infra_wait_limit_inc(mesh->env->infra_cache, rep, *mesh->env->now,
586 NULL, LDNS_RCODE_SERVFAIL, edns, rep, mesh->env->scratch, mesh->env->now_tv))
590 if(rep->c->use_h2)
591 http2_stream_remove_mesh_state(rep->c->h2_stream);
592 comm_point_send_reply(rep);
1062 struct mesh_reply* rep = mstate->reply_list;
1068 for(; rep; rep=rep->next) {
1070 &rep->query_reply, mesh->env->cfg);
1071 if(rep->query_reply.c->use_h2)
1072 http2_stream_remove_mesh_state(rep->h2_stream);
1073 comm_point_drop_reply(&rep->query_reply);
1301 * @param rep: reply to send (or NULL if rcode is set).
1307 mesh_do_callback(struct mesh_state* m, int rcode, struct reply_info* rep,
1315 if(rep && rep->security == sec_status_secure)
1318 if(!rep && rcode == LDNS_RCODE_NOERROR)
1320 if(!rcode && rep && (rep->security == sec_status_bogus ||
1321 rep->security == sec_status_secure_sentinel_fail)) {
1329 rep, rcode, &r->edns, NULL, m->s.region, start_time))
1332 if(!inplace_cb_reply_call(m->s.env, &m->s.qinfo, &m->s, rep, rcode,
1349 if(!inplace_cb_reply_call(m->s.env, &m->s.qinfo, &m->s, rep,
1351 !reply_info_answer_encode(&m->s.qinfo, rep, r->qid,
1362 (rep?rep->security:sec_status_unchecked),
1391 struct reply_info* rep, struct mesh_reply* r)
1408 if(rep->reason_bogus != LDNS_EDE_NONE) {
1410 m->s.region, rep->reason_bogus, rep->reason_bogus_str);
1418 * @param rep: reply to send (or NULL if rcode is set).
1425 mesh_send_reply(struct mesh_state* m, int rcode, struct reply_info* rep,
1445 m->s.env->cfg->ignore_cd) && rep &&
1446 (rep->security <= sec_status_bogus ||
1447 rep->security == sec_status_secure_sentinel_fail)) {
1452 if(rep && rep->security == sec_status_secure)
1455 if(!rep && rcode == LDNS_RCODE_NOERROR)
1498 rep, rcode, &r->edns, &r->query_reply, m->s.region, &r->start_time))
1501 if(!inplace_cb_reply_call(m->s.env, &m->s.qinfo, &m->s, rep, rcode,
1507 /* Since we are SERVFAILing here, CD bit and rep->security
1509 if(m->s.env->cfg->ede && rep) {
1510 mesh_find_and_attach_ede_and_reason(m, rep, r);
1529 * Need to explicitly check for rep->security otherwise failed
1531 if(m->s.env->cfg->ede && rep &&
1532 (rep->security <= sec_status_bogus ||
1533 rep->security == sec_status_secure_sentinel_fail)) {
1534 mesh_find_and_attach_ede_and_reason(m, rep, r);
1537 if(!inplace_cb_reply_call(m->s.env, &m->s.qinfo, &m->s, rep,
1539 !reply_info_answer_encode(&m->s.qinfo, rep, r->qid,
1545 rep, LDNS_RCODE_SERVFAIL, &r->edns, &r->query_reply, m->s.region, &r->start_time))
1591 * @param rep: prepared reply to be sent.
1594 struct reply_info* rep)
1629 if(rep && ((reason_bogus == LDNS_EDE_DNSSEC_BOGUS &&
1630 rep->reason_bogus != LDNS_EDE_NONE) ||
1632 reason_bogus = rep->reason_bogus;
1703 struct reply_info* rep = (mstate->s.return_msg?
1704 mstate->s.return_msg->rep:NULL);
1713 (rep && FLAGS_GET_RCODE(rep->flags) == LDNS_RCODE_SERVFAIL)) {
1727 dns_error_reporting(&mstate->s, rep);
1791 mesh_send_reply(mstate, mstate->s.return_rcode, rep,
1849 mesh_do_callback(mstate, mstate->s.return_rcode, rep, c, &tv);
1942 struct comm_reply* rep, uint16_t qid, uint16_t qflags,
1949 r->query_reply = *rep;
1968 if(rep->c->use_h2)
1969 r->h2_stream = rep->c->h2_stream;
2221 m->s.curmod, (m->reply_list)?"rep":"", /*hasreply*/
2367 struct respip_action_info* actinfo, struct reply_info* rep,
2376 if(!respip_rewrite_reply(qinfo, cinfo, rep, encode_repp, actinfo,
2385 *encode_repp == rep)
2433 if(!msg || (FLAGS_GET_RCODE(msg->rep->flags) != LDNS_RCODE_NOERROR
2434 && FLAGS_GET_RCODE(msg->rep->flags) != LDNS_RCODE_NXDOMAIN
2435 && FLAGS_GET_RCODE(msg->rep->flags) != LDNS_RCODE_YXDOMAIN)) {
2441 encode_rep = msg->rep;
2447 qstate->client_info, &actinfo, msg->rep, &alias_rrset, &encode_rep,
2451 !respip_merge_cname(partial_rep, &qstate->qinfo, msg->rep,
2489 log_dns_msg("Serve expired lookup", &qstate->qinfo, msg->rep);
2541 mesh_send_reply(mstate, LDNS_RCODE_NOERROR, msg->rep,
2590 mesh_do_callback(mstate, LDNS_RCODE_NOERROR, msg->rep, c, &tv);