Felipe Gasper <fel...@felipegasper.com> wrote: > > Is there any public code interface that exposes named-checkzone’s > functionality? > I’d specifically like to have numeric error codes rather than strings.
It isn't easy to do that, I'm afraid. There are two places that don't do what you want. The source for named-checkzone is in https://gitlab.isc.org/isc-projects/bind9/-/tree/main/bin/check The file named-checkzone.c has the setup and option handling, and check-tool.c has some of the zone checks - but not all. It deals with things like using the system resolver to check CNAME or MX records that point out of the zone. There are also a load of checks in lib/dns/zone.c - look for integrity_checks() and the various zone_check_*() functions. https://gitlab.isc.org/isc-projects/bind9/-/blob/main/lib/dns/zone.c Both lib/dns/zone.c and bin/check/check-tool.c report their findings by logging; there isn't an intermediate error code that might describe the problem. And BIND's error codes are simple errno-style numbers: they can't say multi-parameter things like "foo.dotat.at/MX points to bar.dotat.at which is a CNAME". Tony. -- f.anthony.n.finch <d...@dotat.at> https://dotat.at/ North Utsire, South Utsire: Variable 2 to 4. Slight or moderate. Fog patches later. Moderate or good, occasionally very poor later.
_______________________________________________ Please visit https://lists.isc.org/mailman/listinfo/bind-users to unsubscribe from this list ISC funds the development of this software with paid support subscriptions. Contact us at https://www.isc.org/contact/ for more information. bind-users mailing list bind-users@lists.isc.org https://lists.isc.org/mailman/listinfo/bind-users