From 68ed0c629d34e224d34f5895c07ef8d87ab5c2f1 Mon Sep 17 00:00:00 2001 From: Dietmar Maurer Date: Thu, 16 Apr 2020 12:44:59 +0200 Subject: [PATCH] src/api2/node/journal.rs: add access permissions --- src/api2/node/journal.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/api2/node/journal.rs b/src/api2/node/journal.rs index aef67f18..494968c6 100644 --- a/src/api2/node/journal.rs +++ b/src/api2/node/journal.rs @@ -4,9 +4,10 @@ use failure::*; use serde_json::{json, Value}; use std::io::{BufRead,BufReader}; -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; #[api( protected: true, @@ -53,6 +54,9 @@ use crate::api2::types::*; description: "Line text.", }, }, + access: { + permission: &Permission::Privilege(&[], PRIV_SYS_AUDIT, false), + }, )] /// Read syslog entries. fn get_journal(