From: hickert Date: Tue, 6 Oct 2009 07:18:31 +0000 (+0000) Subject: Updated nSRecord handling X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=35310219b4718de1ede0e9e2c951d60dbfd3024e;p=gosa.git Updated nSRecord handling -Add a trailing dot at the end of nSRecords - for full qualified host names only git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@14531 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-plugins/dns/admin/systems/services/dns/class_servDNSeditZone.inc b/gosa-plugins/dns/admin/systems/services/dns/class_servDNSeditZone.inc index 67f2c0df0..cc1daff37 100644 --- a/gosa-plugins/dns/admin/systems/services/dns/class_servDNSeditZone.inc +++ b/gosa-plugins/dns/admin/systems/services/dns/class_servDNSeditZone.inc @@ -548,8 +548,10 @@ class servdnseditZone extends plugin $ret['sOAmail'] = preg_replace("/\@/",".",$this->sOAmail); foreach(array("sOAprimary","zoneName","sOAmail") as $attr){ + + // Append trailing dots if we've full qualified host names. if(!preg_match("/\.$/",$ret[$attr])){ - if(!tests::is_ip($ret[$attr])){ + if(!tests::is_ip($ret[$attr]) && preg_match("/\./",$ret[$attr])){ $ret[$attr] = $ret[$attr]."."; } }