"Apply Zone" option missing for server owners

5 posts / 0 new
Last post
#1 Tue, 02/03/2009 - 14:21
rwsiv

"Apply Zone" option missing for server owners

I am running the following: OS: Debian Linux 4.0 Webmin version: 1.450 Virtualmin version: 3.65.gpl GPL Theme version: 6.6

When a virtual server owner updates their DNS zone it appears that they are unable to publish the changes because the "Apply Zone" link appears to be missing.

Any suggestions?

-Bob

Sun, 06/07/2009 - 07:38
rwsiv

I have been able to work around this problem by creating the following patch to /bind8/bind8-lib.pl:

[code:1]
--- bind8-lib-20090205-01.pl 2009-02-05 12:40:36.000000000 -0600
+++ bind8-lib.pl 2009-02-05 12:58:57.000000000 -0600
@@ -2587,17 +2587,19 @@
{
local ($zone) = @_;
local @rv;
-if (!$access{'ro'} && ($access{'apply'} == 1 || $access{'apply'} == 3)) {
+if (!$access{'ro'} && ($access{'apply'} == 1 || $access{'apply'} == 2 || $access{'apply'} == 3)) {
local $r = $ENV{'REQUEST_METHOD'} eq 'POST' ? 0 : 1;
if (&is_bind_running()) {
if ($zone) {
push(@rv, "<a href='restart_zone.cgi?return=$r&".
"view=$zone->{'viewindex'}&".
"index=$zone->{'index'}'>".
- "$text{'links_apply'}</a>-Apply Zone"«»);
+ "$text{'links_apply'}</a>"«»);
}
- push(@rv, "<a href='restart.cgi?return=$r'>".
- "$text{'links_restart'}</a>-Apply Config"«»);
+ if ($access{'apply'} == 1 || $access{'apply'} == 3) {
+ push(@rv, "<a href='restart.cgi?return=$r'>".
+ "$text{'links_restart'}</a>"«»);
+ }
if ($access{'apply'} == 1) {
push(@rv, "<a href='stop.cgi?return=$r'>".
"$text{'links_stop'}</a>"«»);
[/code:1]

Server owners are now presented with a "Apply Zone" option when accessing their zones. The problem does not appear to be specific to Virtualmin. There appears to have been a recent change to how ACLs apply in the BIND8 module of Webmin. Any Webmin users with the "BIND DNS Server access control options" of "Can stop, start and apply?" set to "Only apply for zones" appears to experience this same problem.

-Bob

Sun, 06/07/2009 - 07:38
rwsiv

I have been able to work around this problem by creating the following patch to /bind8/bind8-lib.pl:

[code:1]
--- bind8-lib-20090205-01.pl 2009-02-05 12:40:36.000000000 -0600
+++ bind8-lib.pl 2009-02-05 12:58:57.000000000 -0600
@@ -2587,17 +2587,19 @@
{
local ($zone) = @_;
local @rv;
-if (!$access{'ro'} && ($access{'apply'} == 1 || $access{'apply'} == 3)) {
+if (!$access{'ro'} && ($access{'apply'} == 1 || $access{'apply'} == 2 || $access{'apply'} == 3)) {
local $r = $ENV{'REQUEST_METHOD'} eq 'POST' ? 0 : 1;
if (&is_bind_running()) {
if ($zone) {
push(@rv, "<a href='restart_zone.cgi?return=$r&".
"view=$zone->{'viewindex'}&".
"index=$zone->{'index'}'>".
- "$text{'links_apply'}</a>-Apply Zone"«»);
+ "$text{'links_apply'}</a>"«»);
}
- push(@rv, "<a href='restart.cgi?return=$r'>".
- "$text{'links_restart'}</a>-Apply Config"«»);
+ if ($access{'apply'} == 1 || $access{'apply'} == 3) {
+ push(@rv, "<a href='restart.cgi?return=$r'>".
+ "$text{'links_restart'}</a>"«»);
+ }
if ($access{'apply'} == 1) {
push(@rv, "<a href='stop.cgi?return=$r'>".
"$text{'links_stop'}</a>"«»);
[/code:1]

Server owners are now presented with a "Apply Zone" option when accessing their zones. The problem does not appear to be specific to Virtualmin. There appears to have been a recent change to how ACLs apply in the BIND8 module of Webmin. Any Webmin users with the "BIND DNS Server access control options" of "Can stop, start and apply?" set to "Only apply for zones" appears to experience this same problem.

-Bob

Thu, 02/05/2009 - 12:28
Joe
Joe's picture

File a bug in the tracker, and Jamie will get it fixed in the next version (or explain why it is the way it is).

--

Check out the forum guidelines!

Thu, 02/05/2009 - 18:54 (Reply to #4)
rwsiv

Thanks Joe!

As you suggested, I filed bug report (#5207). Jamie has already replied that the fix for this problem will be in Webmin 1.460.

-Bob

Topic locked