* [PATCH datacenter-manager] api: remote: add permission check for metric collection RRD endpoint
@ 2026-08-28 15:25 Shan Shaji
2026-08-28 15:30 ` Thomas Ellmenreich
0 siblings, 1 reply; 2+ messages in thread
From: Shan Shaji @ 2026-08-28 15:25 UTC (permalink / raw)
To: pdm-devel; +Cc: Thomas Ellmenreich
The /remote/{id}/rrddata endpoint didn't had the access parameter
defined inside the API macro. This resulted in a
"403: permission check failed" error even though the user
was assigned the Administrator role on the / ACL path.
Reported-by: Thomas Ellmenreich <t.ellmenreich@proxmox.com>
Signed-off-by: Shan Shaji <s.shaji@proxmox.com>
---
server/src/api/remotes/mod.rs | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/server/src/api/remotes/mod.rs b/server/src/api/remotes/mod.rs
index 5c9fdccf..d6f512f6 100644
--- a/server/src/api/remotes/mod.rs
+++ b/server/src/api/remotes/mod.rs
@@ -625,7 +625,11 @@ impl DataPoint for RemoteDatapoint {
items: {
type: RemoteDatapoint,
}
- }
+ },
+ access: {
+ permission: &Permission::Privilege(&["resource", "{id}"], PRIV_RESOURCE_AUDIT, false),
+ description: "Requires `Resource.Audit` privilege on `/resource/{id}`."
+ },
)]
/// Read metric collection RRD data.
fn get_per_remote_rrd_data(
--
2.47.3
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH datacenter-manager] api: remote: add permission check for metric collection RRD endpoint
2026-08-28 15:25 [PATCH datacenter-manager] api: remote: add permission check for metric collection RRD endpoint Shan Shaji
@ 2026-08-28 15:30 ` Thomas Ellmenreich
0 siblings, 0 replies; 2+ messages in thread
From: Thomas Ellmenreich @ 2026-08-28 15:30 UTC (permalink / raw)
To: Shan Shaji, pdm-devel
Thanks for sending in this patch as well!
Reviewed-by: Thomas Ellmenreich <t.ellmenreich@proxmox.com>
Tested-by Thomas Ellmenreich <t.ellmenreich@proxmox.com>
On Fri Aug 28, 2026 at 5:25 PM CEST, Shan Shaji wrote:
> The /remote/{id}/rrddata endpoint didn't had the access parameter
> defined inside the API macro. This resulted in a
> "403: permission check failed" error even though the user
> was assigned the Administrator role on the / ACL path.
>
> Reported-by: Thomas Ellmenreich <t.ellmenreich@proxmox.com>
> Signed-off-by: Shan Shaji <s.shaji@proxmox.com>
> ---
> server/src/api/remotes/mod.rs | 6 +++++-
> 1 file changed, 5 insertions(+), 1 deletion(-)
>
> diff --git a/server/src/api/remotes/mod.rs b/server/src/api/remotes/mod.rs
> index 5c9fdccf..d6f512f6 100644
> --- a/server/src/api/remotes/mod.rs
> +++ b/server/src/api/remotes/mod.rs
> @@ -625,7 +625,11 @@ impl DataPoint for RemoteDatapoint {
> items: {
> type: RemoteDatapoint,
> }
> - }
> + },
> + access: {
> + permission: &Permission::Privilege(&["resource", "{id}"], PRIV_RESOURCE_AUDIT, false),
> + description: "Requires `Resource.Audit` privilege on `/resource/{id}`."
> + },
> )]
> /// Read metric collection RRD data.
> fn get_per_remote_rrd_data(
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-08-28 15:30 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-28 15:25 [PATCH datacenter-manager] api: remote: add permission check for metric collection RRD endpoint Shan Shaji
2026-08-28 15:30 ` Thomas Ellmenreich
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.