Commit 705ac953 authored by Dietmar Maurer's avatar Dietmar Maurer

require Sys.Audit to read cluster status

parent eaa70df1
...@@ -310,6 +310,7 @@ __PACKAGE__->register_method({ ...@@ -310,6 +310,7 @@ __PACKAGE__->register_method({
}, },
code => sub { code => sub {
my ($param) = @_; my ($param) = @_;
return PVE::Cluster::cfs_read_file('datacenter.cfg'); return PVE::Cluster::cfs_read_file('datacenter.cfg');
}}); }});
...@@ -440,7 +441,9 @@ __PACKAGE__->register_method({ ...@@ -440,7 +441,9 @@ __PACKAGE__->register_method({
path => 'status', path => 'status',
method => 'GET', method => 'GET',
description => "Get cluster status informations.", description => "Get cluster status informations.",
permissions => { user => 'all' }, permissions => {
check => ['perm', '/', [ 'Sys.Audit' ]],
},
protected => 1, protected => 1,
parameters => { parameters => {
additionalProperties => 0, additionalProperties => 0,
......
...@@ -307,6 +307,3 @@ __PACKAGE__->register_method({ ...@@ -307,6 +307,3 @@ __PACKAGE__->register_method({
return undef; return undef;
}}); }});
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment