valtz.git
12 months agoUpdate copyright information in the LICENSE file and executable. master
Michael Orlitzky [Wed, 21 Oct 2020 21:41:03 +0000 (17:41 -0400)]
Update copyright information in the LICENSE file and executable.

12 months agoAUTHORS: add an authors file in preparation for updating the copyright.
Michael Orlitzky [Wed, 21 Oct 2020 21:36:18 +0000 (17:36 -0400)]
AUTHORS: add an authors file in preparation for updating the copyright.

The valtz project is no longer the exclusive copyright of Magnus
Bodin. Rather than list everyone everywhere, I plan to change it to
"the valtz authors," which is more useful when there's a list of the
valtz authors.

12 months agoDrop the "-s" option.
Michael Orlitzky [Wed, 21 Oct 2020 18:17:38 +0000 (14:17 -0400)]
Drop the "-s" option.

With all due respect to the original authors, the behavior of the "-s"
flag is trivial to implement with the POSIX "find" command. The
benefit of having it reimplemented in valtz itself is small.

12 months agoShow only a usage summary when -h is passed.
Michael Orlitzky [Wed, 21 Oct 2020 18:11:14 +0000 (14:11 -0400)]
Show only a usage summary when -h is passed.

There was a long "usage" string contained within the program itself
that is now contained within the man page. The long usage would be
shown with "valtz -h", and a shorter one would be shown with simply
"valtz", which is an error by itself. This commit also unifies those
two: if you try to run valtz with no arguments, the "valtz -h" output
is shown but the exit code will be non-zero.

12 months agoREADME: remove information now contained in the man page.
Michael Orlitzky [Wed, 21 Oct 2020 15:19:50 +0000 (11:19 -0400)]
README: remove information now contained in the man page.

12 months agoAdd a man page.
Michael Orlitzky [Wed, 21 Oct 2020 15:15:52 +0000 (11:15 -0400)]
Add a man page.

12 months agoCHANGES: reword the headers, and perform some minor cleanup.
Michael Orlitzky [Wed, 21 Oct 2020 01:56:25 +0000 (21:56 -0400)]
CHANGES: reword the headers, and perform some minor cleanup.

12 months agoTODO: delete this old file as it didn't contain anything actionable.
Michael Orlitzky [Wed, 21 Oct 2020 01:51:41 +0000 (21:51 -0400)]
TODO: delete this old file as it didn't contain anything actionable.

12 months agoUpdate some copyright, version, and contact information.
Michael Orlitzky [Wed, 21 Oct 2020 01:51:08 +0000 (21:51 -0400)]
Update some copyright, version, and contact information.

12 months agoDrop the "-x" flag.
Michael Orlitzky [Wed, 21 Oct 2020 01:43:50 +0000 (21:43 -0400)]
Drop the "-x" flag.

The "-x" flag used to set the exit code non-zero on error, thus making
it easier to detect errors in shell scripts. But I can imagine no
situation where returning zero unconditionally is preferable; and so,
I've removed the flag and enabled the "-x" behavior by default.

12 months agoCHANGES: add recent changes from v0.7.
Michael Orlitzky [Tue, 20 Oct 2020 22:24:49 +0000 (18:24 -0400)]
CHANGES: add recent changes from v0.7.

12 months agoREADME: whitespace cleanup.
Michael Orlitzky [Tue, 20 Oct 2020 22:20:05 +0000 (18:20 -0400)]
README: whitespace cleanup.

12 months agoWarn about IP addresses in hostname fields.
Michael Orlitzky [Tue, 20 Oct 2020 22:00:52 +0000 (18:00 -0400)]
Warn about IP addresses in hostname fields.

A common error is to specify an IP address as the result of an MX
lookup. The RFCs (974, 1035, 2181...) state that the result should be
a "domain name," which in this context, means "host name." This commit
adds a check on "hostname" fields that rejects a dotted-quad contained
therein. In particular, it catches the aforementioned MX record error.

22 months agoWhitespace cleanup.
Michael Orlitzky [Thu, 5 Dec 2019 15:48:59 +0000 (10:48 -0500)]
Whitespace cleanup.

Remove some trailing whitespace and empty comments where it should (ha
ha) have no effect on the behavior of the program.

22 months agoAdd support for SRV records.
Michael Orlitzky [Thu, 5 Dec 2019 15:28:40 +0000 (10:28 -0500)]
Add support for SRV records.

There is a patch for djbdns that adds support for SRV records to both
tinydns-data and axfr-get:

  From: Michael Handler <handler@sub-rosa.com>
  To: dns@list.cr.yp.to
  Subject: tinydns-data SRV & axfr-get SRV/PTR patches
  Date: Thu, 14 Sep 2000 20:37:50 -040

Many distributions carry the patch, but valtz rejects the SRV records
because it doesn't recognize the "S" indicator or know how to validate
the port, weight, or priority fields.

This commit adds support for the new record type, and adds validation
routines for the three new fields. All of them are the same: ports,
weights, and priorities are all integers between 0 and 65536.

22 months agoAllow underscore characters in FQDNs and pointers.
Michael Orlitzky [Thu, 5 Dec 2019 15:34:54 +0000 (10:34 -0500)]
Allow underscore characters in FQDNs and pointers.

Modern DNS records can contain underscores for a number of reasons. In
particular, DKIM records involve a "_domainkey" part,

  https://tools.ietf.org/html/rfc6376

that is rejected by the current "fqdn" and "p" validation routines.
Moreover, any SRV records will have a service name prefixed with an
underscore:

  https://tools.ietf.org/html/rfc2782

To recognize these tokens as valid, this commit expands the "fqdn" and
"p" regular expressions to allow underscores as the first character in
each component of an FQDN.

6 years agoFix support for generic records
wKovacs64 [Wed, 17 Dec 2014 00:13:17 +0000 (17:13 -0700)]
Fix support for generic records

6 years agoInitial commit
wKovacs64 [Tue, 16 Dec 2014 23:52:07 +0000 (16:52 -0700)]
Initial commit

Forked from http://x42.com/software/valtz