src/api2/node/syslog.rs: add access permissions

This commit is contained in:
Dietmar Maurer 2020-04-16 17:08:19 +02:00
parent b5037fa8ed
commit e4681f9f71

View File

@ -3,9 +3,10 @@ use std::process::{Command, Stdio};
use failure::*;
use serde_json::{json, Value};
use proxmox::api::{api, ApiMethod, Router, RpcEnvironment};
use proxmox::api::{api, ApiMethod, Router, RpcEnvironment, Permission};
use crate::api2::types::*;
use crate::config::acl::PRIV_SYS_AUDIT;
fn dump_journal(
start: Option<u64>,
@ -122,6 +123,9 @@ fn dump_journal(
}
},
},
access: {
permission: &Permission::Privilege(&[], PRIV_SYS_AUDIT, false),
},
)]
/// Read syslog entries.
fn get_syslog(