Use 'c' prefix for bucket policies instead of 'n' #360

Merged
alexvanin merged 2 commits from alexvanin/frostfs-s3-gw:fix/8574 into support/v0.29 2024-04-10 14:56:06 +00:00

With 'c' prefix, acl chains become shorter, thus gateway
receives shorter results and avoids sessions to neo-go.

There is still issue with many IAM rules.

With 'c' prefix, acl chains become shorter, thus gateway receives shorter results and avoids sessions to neo-go. There is still issue with many IAM rules.
alexvanin added 1 commit 2024-04-10 12:54:36 +00:00
/ Vulncheck (pull_request) Failing after 2m15s Details
/ Lint (pull_request) Failing after 2m0s Details
/ Tests (1.20) (pull_request) Failing after 2m30s Details
/ Tests (1.21) (pull_request) Failing after 2m24s Details
/ DCO (pull_request) Failing after 2m4s Details
/ Builds (1.20) (pull_request) Successful in 2m34s Details
/ Builds (1.21) (pull_request) Successful in 2m28s Details
335cfd3a3b
[#xxx] Use 'c' prefix for bucket policies instead of 'n'
With 'c' prefix, acl chains become shorter, thus gateway
receives shorter results and avoids sessions to neo-go.

There is still issue with many IAM rules.

Signed-off-by: Alex Vanin <a.vanin@yadro.com>
dkirillov reviewed 2024-04-10 13:07:28 +00:00
@ -76,1 +81,3 @@
st = chain.NoRuleFound
st := chain.NoRuleFound
for _, target := range targets {
status, found, err := cfg.Storage.IsAllowed(chain.S3, target, req)
Collaborator

Why don't we use just one RequestTarget?

if bktInfo !=nil {
	cnrTarget:=engine.ContainerTarget(bktInfo.CID.EncodeToString())
	target.Container = &cnrTarget
}
Why don't we use just one `RequestTarget`? ```golang if bktInfo !=nil { cnrTarget:=engine.ContainerTarget(bktInfo.CID.EncodeToString()) target.Container = &cnrTarget } ```
Poster
Owner

Missed that, thanks!

Missed that, thanks!
alexvanin added 1 commit 2024-04-10 13:29:27 +00:00
/ DCO (pull_request) Failing after 1m37s Details
/ Builds (1.20) (pull_request) Successful in 2m34s Details
/ Builds (1.21) (pull_request) Successful in 1m53s Details
/ Vulncheck (pull_request) Failing after 2m14s Details
/ Lint (pull_request) Failing after 2m31s Details
/ Tests (1.20) (pull_request) Failing after 2m37s Details
/ Tests (1.21) (pull_request) Failing after 2m22s Details
3863c0689c
[#xxx] Reuse single target during policy check
Policy engine library is able to manage multiple
targets and resolve different status results.

Signed-off-by: Alex Vanin <a.vanin@yadro.com>
alexvanin force-pushed fix/8574 from 3863c0689c to 802f3f57f9 2024-04-10 14:06:21 +00:00 Compare
alexvanin requested review from storage-services-committers 2024-04-10 14:06:31 +00:00
alexvanin requested review from storage-services-developers 2024-04-10 14:06:31 +00:00
alexvanin changed title from WIP: Use 'c' prefix for bucket policies instead of 'n' to Use 'c' prefix for bucket policies instead of 'n' 2024-04-10 14:07:01 +00:00
alexvanin force-pushed fix/8574 from 802f3f57f9 to 65a8e2dadc 2024-04-10 14:40:34 +00:00 Compare
dkirillov approved these changes 2024-04-10 14:52:12 +00:00
alexvanin merged commit 65a8e2dadc into support/v0.29 2024-04-10 14:56:06 +00:00
alexvanin deleted branch fix/8574 2024-04-10 14:56:06 +00:00
alexvanin added this to the v0.29.0 milestone 2024-05-27 10:06:45 +00:00
Sign in to join this conversation.
There is no content yet.