if is_default:
return
for d in datasources:
- if "class" in d:
- dclass = d["class"]
- else:
- dclass = "IN"
- if d["type"].lower() == "memory" and dclass.lower() == zone_class.to_text().lower():
+ try:
+ if "class" in d:
+ dclass = RRClass(d["class"])
+ else:
+ dclass = RRClass("IN")
+ except InvalidRRType as err:
+ logger.info(XFRIN_AUTH_CONFIG_ERROR, str(err))
+ continue
+
+ if d["type"].lower() == "memory" and dclass == zone_class:
for zone in d["zones"]:
- # Remove trailing periods
- n1 = zone["origin"]
- if n1[-1] == '.':
- n1 = n1[:-1]
- n2 = zone_name.to_text()
- if n2[-1] == '.':
- n2 = n2[:-1]
-
- if zone["filetype"].lower() == "sqlite3" and n1.lower() == n2.lower():
- param = {"origin": n1,
+ if "filetype" not in zone:
+ continue
+ try:
+ name = Name(zone["origin"])
+ except (EmptyLabel, TooLongLabel, BadLabelType, BadEscape, TooLongName, IncompleteName):
+ logger.info(XFRIN_AUTH_CONFIG_ERROR, str(err))
+ continue
+
+ if zone["filetype"].lower() == "sqlite3" and name == zone_name:
+ param = {"origin": zone_name.to_text(),
"class": zone_class.to_text(),
"datasrc": d["type"]}
+
logger.debug(DBG_XFRIN_TRACE, XFRIN_AUTH_LOADZONE,
param["origin"], param["class"], param["datasrc"])
There was a problem sending a message to b10-auth. This most likely
means that the msgq daemon has quit or was killed.
+% XFRIN_AUTH_CONFIG_ERROR Error parsing Auth configuration: %1
+There was an error when parsing Auth configuration.
+
% XFRIN_AUTH_LOADZONE sending Auth loadzone for origin=%1, class=%2, datasrc=%3
There was a successful zone transfer, and the zone is served by b10-auth
in the in-memory data source using sqlite3 as a backend. We send the