1#!/usr/bin/perl -l 2 3use DNSCheck; 4 5my $dc = DNSCheck->new; 6 7if ($dc->host->host_syntax($ARGV[0]) == 0) { 8 print "TRUE"; 9} else { 10 print "FALSE"; 11} 12 13=head1 NAME 14 15dnscheck-hostsyntax - check if a name is syntactically correct for DNS 16 17=head1 DESCRIPTION 18 19The dnscheck-hostsyntax script takes a string as a command line argument and 20checks if it's a syntactically correct hostname according to 21L<DNSCheck::Test::Host::host_syntax>. 22 23There are no options. The script will print the string TRUE to standard output 24if it thinks the name is correct, and the string FALSE otherwise. 25 26=head1 EXAMPLE 27 28 dnscheck-hostsyntax iis.se 29