The current format-hostname test suite does not include a case ensuring that dotted-decimal IPv4 addresses (e.g., 192.168.0.1) are rejected.
Because hostname labels are allowed to:
- start with digits, and
- be entirely numeric,
a validator may incorrectly validate 192.168.0.1 as four numeric labels and accept it as a hostname.
However, RFC 1123 section2.1 mentioned in the spec states:
a valid host name can never have the dotted-decimal form #.#.#.#
Therefore, dotted-decimal IPv4 addresses must not be considered valid hostnames.
Since we already provide a separate format: ipv4, allowing such values to pass hostname would blur the distinction between the two formats.