[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#37045: Needs a stricter hostname sanity check



Package: boot-floppies
Version: 2.1.9

Our current MTA's (at least exim and smail, perhaps sendmail as well) do a
sanity check on the system's hostname. They will refuse to configure if your
hostname is invalid (starts with a number, etc).

Slink's bootdisks don't do this same check. You can install the base just
fine, then when you have dselect pull in standard, it'll install exim, which
will *then* complain about the hostname. At this point, because the hostname
isn't centrally set (it gets littered all over various config files) the
sysadmin is in a bit of a fix.

The bootdisks should at least warn the sysadmin about an invalid hostname.

Joey (Martin Schulze) whipped up a patch for me:

Hi rcw,

here is the patch against boot-floppies.  Please include it in your
bug report.

--- boot-floppies/utilities/dbootstrap/netconfig.c.orig Sun May  2 21:08:11 1999
+++ boot-floppies/utilities/dbootstrap/netconfig.c      Sun May  2 21:09:53 1999
@@ -177,6 +177,10 @@
     {
       problemBox(_("The host name must not contain dots."),_("Problem"));
       return 1;
+  else if(isdigit(host[0]))
+    {
+      problemBox(_("The host name must not begin with a digit."),_("Problem"));
+      return 1;
     }

 #ifdef _TESTING_

Regards,

        Joey
-- 
Robert Woodcock - rcw@debian.org
"Now we'll have to kill you." -- Linus Torvalds


Reply to: