Lines Matching +defs:fallback +defs:c
2 * services/authzone.c - authoritative zone that is locally hosted.
4 * Copyright (c) 2017, NLnet Labs. All rights reserved.
95 /** number of timeouts before we fallback from IXFR to AXFR,
575 /** set auth zone fallback. caller must have lock on zone */
580 log_err("auth zone fallback, expected yes or no, got %s",
2094 auth_zones_cfg(struct auth_zones* az, struct config_auth* c)
2100 if(c->isrpz) {
2106 if(!(z=auth_zones_find_or_add_zone(az, c->name))) {
2108 if(c->isrpz) {
2113 if(c->masters || c->urls) {
2117 if(c->isrpz) {
2123 if(c->for_downstream)
2129 if(!auth_zone_set_zonefile(z, c->zonefile)) {
2134 if(c->isrpz) {
2139 z->for_downstream = c->for_downstream;
2140 z->for_upstream = c->for_upstream;
2141 z->fallback_enabled = c->fallback_enabled;
2142 z->zonemd_check = c->zonemd_check;
2143 z->zonemd_reject_absence = c->zonemd_reject_absence;
2144 if(c->isrpz && !z->rpz){
2145 if(!(z->rpz = rpz_create(c))){
2155 } else if(c->isrpz && z->rpz) {
2156 if(!rpz_config(z->rpz, c)) {
2166 if(c->isrpz) {
2174 if(!xfer_set_masters(&x->task_probe->masters, c, 0)) {
2179 if(!xfer_set_masters(&x->task_transfer->masters, c, 1)) {
2280 struct auth_chunk* c, *cn;
2281 c = at->chunks_first;
2282 while(c) {
2283 cn = c->next;
2284 free(c->data);
2285 free(c);
2286 c = cn;
3439 struct regional* region, struct dns_msg** msg, int* fallback)
3444 /* does the zone want fallback in case of failure? */
3445 *fallback = z->fallback_enabled;
3492 struct regional* region, struct dns_msg** msg, int* fallback,
3502 /* no auth zone, fallback to internet */
3503 *fallback = 1;
3509 /* if not for upstream queries, fallback */
3512 *fallback = 1;
3516 *fallback = z->fallback_enabled;
3521 r = auth_zone_generate_answer(z, qinfo, region, msg, fallback);
3578 int fallback = 0;
3622 r = auth_zone_generate_answer(z, qinfo, temp, &msg, &fallback);
3624 if(!r && fallback) {
3625 /* fallback to regular answering (recursive) */
3650 /* no such auth zone, fallback */
4395 char c = (char)((*chunk)->data[*chunk_pos]);
4403 sldns_buffer_write_u8(buf, (uint8_t)c);
4404 if(c == '\n') {
4428 char c = (char)sldns_buffer_read_u8_at(buf, i);
4429 if(squote && c != '\'') continue;
4430 if(dquote && c != '"') continue;
4431 if(c == '"')
4433 else if(c == '\'')
4435 else if(c == '(')
4437 else if(c == ')')
4439 else if(c == ';') {
4455 char c = (char)sldns_buffer_read_u8_at(buf, i);
4456 if(squote && c != '\'') continue;
4457 if(dquote && c != '"') continue;
4458 if(c == '"')
4460 else if(c == '\'')
4462 else if(c == ';') {
4477 char c = (char)sldns_buffer_read_u8_at(buf, i);
4478 if(c == ';')
4480 else if(c != ' ' && c != '\t' && c != '\r' && c != '\n')
4653 char c = (char)sldns_buffer_read_u8_at(buf, i);
4654 if(c == '\n' && i==end-1) {
4659 if(c == '\n')
5799 /* if we are doing IXFR, check for fallback */
5805 verbose(VERB_ALGO, "xfr to %s, fallback "
5949 " fallback from IXFR to AXFR",
6159 verbose(VERB_ALGO, "xfr to %s, fallback "
6178 auth_xfer_transfer_tcp_callback(struct comm_point* c, void* arg, int err,
6207 verbose(VERB_ALGO, "xfr to %s, fallback "
6231 /* if it needs to fallback from IXFR to AXFR, do that */
6232 if(!check_xfer_packet(c->buffer, xfr, &gonextonfail, &transferdone)) {
6237 if(!xfer_link_data(c->buffer, xfr)) {
6253 c->tcp_is_reading = 1;
6254 sldns_buffer_clear(c->buffer);
6255 comm_point_start_listening(c, -1, AUTH_TRANSFER_TIMEOUT);
6261 auth_xfer_transfer_http_callback(struct comm_point* c, void* arg, int err,
6286 if(repinfo) repinfo->c = NULL; /* signal cp deleted to
6297 if(sldns_buffer_limit(c->buffer) > 0) {
6299 (int)sldns_buffer_limit(c->buffer));
6300 if(!xfer_link_data(c->buffer, xfr)) {
6308 if(repinfo) repinfo->c = NULL; /* signal cp deleted to
6319 c->tcp_is_reading = 1;
6320 sldns_buffer_clear(c->buffer);
6321 comm_point_start_listening(c, -1, AUTH_TRANSFER_TIMEOUT);
6511 auth_xfer_probe_udp_callback(struct comm_point* c, void* arg, int err,
6525 * and we set rep.c=NULL to stop if from looking inside the commpoint*/
6526 repinfo->c = NULL;
6533 if(check_packet_ok(c->buffer, LDNS_RR_TYPE_SOA, xfr,
7211 * or https://[::1@1234]/a/b/c/d */
7277 xfer_set_masters(struct auth_master** list, struct config_auth* c,
7287 for(p = c->urls; p; p = p->next) {
7294 for(p = c->masters; p; p = p->next) {
7304 for(p = c->allow_notify; p; p = p->next) {