diff --git a/bind8/CHANGELOG b/bind8/CHANGELOG index c04d8ab16..ba5fac4bf 100644 --- a/bind8/CHANGELOG +++ b/bind8/CHANGELOG @@ -67,3 +67,5 @@ When adding a remote slave zone, the IPs of all other slaves and the master are ---- Changes since 1.390 ---- BIND on Windows can now be configured using this module. Mass record creation can now add records for the domain name (by entering @ as the name), as records that already exist. +---- Changes since 1.400 ---- +Keys in ACL sections are no long mangled by Webmin. This means that each IP or key must be entered on a separate line in the Access Control Lists page. diff --git a/bind8/conf_acls.cgi b/bind8/conf_acls.cgi index a4cff8bc2..7c6bb9299 100755 --- a/bind8/conf_acls.cgi +++ b/bind8/conf_acls.cgi @@ -9,20 +9,18 @@ $access{'defaults'} || &error($text{'acls_ecannot'}); $conf = &get_config(); @acls = ( &find("acl", $conf), { } ); -print "
\n"; +print &ui_columns_end(); +print &ui_form_end([ [ undef, $text{'save'} ] ]); &ui_print_footer("", $text{'index_return'}); diff --git a/bind8/lang/en b/bind8/lang/en index f4acc0066..2edc35a9b 100644 --- a/bind8/lang/en +++ b/bind8/lang/en @@ -522,6 +522,7 @@ acls_name=ACL Name acls_values=Matching addresses, networks and ACLs acls_err=Failed to save access control lists acls_ename='$1' is not a valid ACL name +acls_eline=Each IP address must be entered on a separate line for ACL '$1' files_title=Files and Directories files_ecannot=You are not allowed to configure files diff --git a/bind8/module.info b/bind8/module.info index bee003cd0..d7b89feb3 100644 --- a/bind8/module.info +++ b/bind8/module.info @@ -28,3 +28,4 @@ desc_zh_CN.UTF-8=BIND 8 DNS 服务器 desc_ja_JP.UTF-8=BIND DNS サーバ desc_ko_KR.UTF-8=BIND DNS 서버 desc_cz=DNS BIND Server +desc_nl=BIND DNS-server diff --git a/bind8/save_acls.cgi b/bind8/save_acls.cgi index 387179f46..34c2ce4fd 100755 --- a/bind8/save_acls.cgi +++ b/bind8/save_acls.cgi @@ -12,11 +12,19 @@ $conf = &get_config(); for($i=0; defined($name = $in{"name_$i"}); $i++) { next if (!$name); $name =~ /^\S+$/ || &error(&text('acls_ename', $name)); - @vals = split(/\s+/, $in{"values_$i"}); + $in{"values_$i"} =~ s/\r//g; + @vals = split(/\n+/, $in{"values_$i"}); + foreach $v (@vals) { + if ($v =~ /^[0-9\.]+\s+\S/) { + &error(&text('acls_eline', $name)); + } + } push(@acls, { 'name' => 'acl', 'values' => [ $name ], 'type' => 1, - 'members' => [ map { { 'name' => $_ } } @vals ] }); + 'members' => [ map { my ($n, @w)=split(/\s+/, $_); + { 'name' => $n, + 'values' => \@w } } @vals ] }); } &save_directive(&get_config_parent(), 'acl', \@acls, 0, 0, 1);