From e4681f9f71936bfffb3fa4ff37a4fe9452900f77 Mon Sep 17 00:00:00 2001 From: Dietmar Maurer Date: Thu, 16 Apr 2020 17:08:19 +0200 Subject: [PATCH] src/api2/node/syslog.rs: add access permissions --- src/api2/node/syslog.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/api2/node/syslog.rs b/src/api2/node/syslog.rs index 2a43ece7..55b3bd5c 100644 --- a/src/api2/node/syslog.rs +++ b/src/api2/node/syslog.rs @@ -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, @@ -122,6 +123,9 @@ fn dump_journal( } }, }, + access: { + permission: &Permission::Privilege(&[], PRIV_SYS_AUDIT, false), + }, )] /// Read syslog entries. fn get_syslog(