From 3534d6d05bdddcf40783d51aa281434e2e128cc0 Mon Sep 17 00:00:00 2001 From: aarifullin Date: Wed, 8 Nov 2023 17:12:45 +0300 Subject: [PATCH] [#794] objectsvc: Return accidentally removed acl checks for Head Signed-off-by: Airat Arifullin --- pkg/services/object/acl/v2/service.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pkg/services/object/acl/v2/service.go b/pkg/services/object/acl/v2/service.go index 6d6f9c448..ee167d0e4 100644 --- a/pkg/services/object/acl/v2/service.go +++ b/pkg/services/object/acl/v2/service.go @@ -218,6 +218,12 @@ func (b Service) Head( reqInfo.obj = obj + if !b.checker.CheckBasicACL(reqInfo) { + return nil, basicACLErr(reqInfo) + } else if err := b.checker.CheckEACL(request, reqInfo); err != nil { + return nil, eACLErr(reqInfo, err) + } + resp, err := b.next.Head(ctx, request) if err == nil { if err = b.checker.CheckEACL(resp, reqInfo); err != nil {