From c10a872d10c0eaa1223c42ffdcfdb254364dac4f Mon Sep 17 00:00:00 2001 From: hickert Date: Wed, 8 Feb 2006 07:35:26 +0000 Subject: [PATCH] Added Checks for lowercase git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@2639 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../admin/systems/class_servDNSeditZone.inc | 31 +++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/plugins/admin/systems/class_servDNSeditZone.inc b/plugins/admin/systems/class_servDNSeditZone.inc index eda11ea19..d95d24a54 100644 --- a/plugins/admin/systems/class_servDNSeditZone.inc +++ b/plugins/admin/systems/class_servDNSeditZone.inc @@ -152,6 +152,37 @@ class servdnseditZone extends plugin $message[] =_("This reverse zone is already in use"); } } + + if($this->zoneName != strtolower($this->zoneName)){ + $message[] = _("Only lowercase strings are allowed as zone name."); + } + + if(!is_numeric($this->sOAserial)){ + $message[] = _("Please specify a numeric value for serial number."); + } + + if(!is_numeric($this->sOArefresh)){ + $message[] = _("Please specify a numeric value for refresh."); + } + + if(!is_numeric($this->sOAttl)){ + $message[] = _("Please specify a numeric value for ttl."); + } + + if(!is_numeric($this->sOAexpire)){ + $message[] = _("Please specify a numeric value for expire."); + } + + if(!is_numeric($this->sOAretry)){ + $message[] = _("Please specify a numeric value for retry."); + } + + foreach($this->Records as $name => $values){ + /* only lower-case is allowed in record entries ... */ + if($values['value'] != strtolower($values['value'])){ + $message[] = sprintf(_("Only lowercase is allowed, please check your '%ss'."),$values['type']); + } + } return ($message); } -- 2.30.2