Improvement to access control

This commit is contained in:
Lennart
2024-10-31 21:18:41 +01:00
parent c484a17911
commit 0c14f8ba90
24 changed files with 394 additions and 215 deletions

View File

@@ -47,16 +47,32 @@ pub async fn route_report_calendar<C: CalendarStore + ?Sized>(
Ok(match request.clone() {
ReportRequest::CalendarQuery(cal_query) => {
handle_calendar_query(cal_query, req, &principal, &cal_id, cal_store.as_ref()).await?
handle_calendar_query(
cal_query,
req,
&user,
&principal,
&cal_id,
cal_store.as_ref(),
)
.await?
}
ReportRequest::CalendarMultiget(cal_multiget) => {
handle_calendar_multiget(cal_multiget, req, &principal, &cal_id, cal_store.as_ref())
.await?
handle_calendar_multiget(
cal_multiget,
req,
&user,
&principal,
&cal_id,
cal_store.as_ref(),
)
.await?
}
ReportRequest::SyncCollection(sync_collection) => {
handle_sync_collection(
sync_collection,
req,
&user,
&principal,
&cal_id,
cal_store.as_ref(),