diff --git a/CHANGELOG.md b/CHANGELOG.md index 6023e5c1..ae018a33 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -46,6 +46,7 @@ Changelog for FrostFS Node - Do not fetch an object if `meta` is missing it (#61) - Create contract wallet only by `init` and `update-config` command (#63) - Actually use `object.put.pool_size_local` and independent pool for local puts (#64). +- Pretty printer of basic ACL in the NeoFS CLI (#2259) ### Removed ### Updated diff --git a/cmd/frostfs-cli/modules/util/acl.go b/cmd/frostfs-cli/modules/util/acl.go index 6620ca70..c8366e5b 100644 --- a/cmd/frostfs-cli/modules/util/acl.go +++ b/cmd/frostfs-cli/modules/util/acl.go @@ -24,7 +24,7 @@ func PrettyPrintTableBACL(cmd *cobra.Command, bacl *acl.Basic) { fmt.Fprintln(w, "\tRangeHASH\tRange\tSearch\tDelete\tPut\tHead\tGet") // Bits bits := []string{ - boolToString(bacl.Sticky()) + " " + boolToString(bacl.Extendable()), + boolToString(bacl.Sticky()) + " " + boolToString(!bacl.Extendable()), getRoleBitsForOperation(bacl, acl.OpObjectHash), getRoleBitsForOperation(bacl, acl.OpObjectRange), getRoleBitsForOperation(bacl, acl.OpObjectSearch), getRoleBitsForOperation(bacl, acl.OpObjectDelete), getRoleBitsForOperation(bacl, acl.OpObjectPut), getRoleBitsForOperation(bacl, acl.OpObjectHead), @@ -47,7 +47,7 @@ func getRoleBitsForOperation(bacl *acl.Basic, op acl.Op) string { return boolToString(bacl.IsOpAllowed(op, acl.RoleOwner)) + " " + boolToString(bacl.IsOpAllowed(op, acl.RoleContainer)) + " " + boolToString(bacl.IsOpAllowed(op, acl.RoleOthers)) + " " + - boolToString(bacl.IsOpAllowed(op, acl.RoleInnerRing)) + boolToString(bacl.AllowedBearerRules(op)) } func boolToString(b bool) string {