From e4e4dea1401068374f513a61e4d3a864ada16392 Mon Sep 17 00:00:00 2001 From: Chris Lu Date: Wed, 28 Jan 2026 13:28:42 -0800 Subject: [PATCH] s3tables: remove legacy principal fallback header Removed the fallback to X-Amz-Principal in getPrincipalFromRequest as S3 Tables is a new feature and does not require legacy header support. --- weed/s3api/s3tables/handler.go | 5 ----- 1 file changed, 5 deletions(-) diff --git a/weed/s3api/s3tables/handler.go b/weed/s3api/s3tables/handler.go index 76be2334a..ccff1fe7c 100644 --- a/weed/s3api/s3tables/handler.go +++ b/weed/s3api/s3tables/handler.go @@ -159,11 +159,6 @@ func (h *S3TablesHandler) getPrincipalFromRequest(r *http.Request) string { return identityName } - // Fallback to request header (e.g., for testing or legacy clients) - if principal := r.Header.Get("X-Amz-Principal"); principal != "" { - return principal - } - // Fallback to the authenticated account ID if accountID := r.Header.Get(s3_constants.AmzAccountId); accountID != "" { return accountID