Skip to content

Commit 6b81acb

Browse files
committed
eos: do not read user ACLs any longer
1 parent 716e6b8 commit 6b81acb

File tree

1 file changed

+2
-20
lines changed

1 file changed

+2
-20
lines changed

pkg/eosclient/eosbinary/eosbinary.go

+2-20
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,8 @@ import (
4343
)
4444

4545
const (
46-
versionPrefix = ".sys.v#."
47-
userACLEvalKey = "eval.useracl"
48-
favoritesKey = "http://owncloud.org/ns/favorite"
46+
versionPrefix = ".sys.v#."
47+
favoritesKey = "http://owncloud.org/ns/favorite"
4948
)
5049

5150
func serializeAttribute(a *eosclient.Attribute) string {
@@ -1226,23 +1225,6 @@ func (c *Client) mapToFileInfo(ctx context.Context, kv, attrs map[string]string,
12261225
return nil, err
12271226
}
12281227

1229-
// Temporary until we migrate the user ACLs to sys ACLs on our MGMs
1230-
// Read user ACLs if sys.eval.useracl is set
1231-
if userACLEval, ok := attrs["sys."+userACLEvalKey]; ok && userACLEval == "1" {
1232-
if userACL, ok := attrs["user.acl"]; ok {
1233-
userAcls, err := acl.Parse(userACL, acl.ShortTextForm)
1234-
if err != nil {
1235-
return nil, err
1236-
}
1237-
for _, e := range userAcls.Entries {
1238-
err = sysACL.SetEntry(e.Type, e.Qualifier, e.Permissions)
1239-
if err != nil {
1240-
return nil, err
1241-
}
1242-
}
1243-
}
1244-
}
1245-
12461228
// Read the favorite attr
12471229
if parseFavoriteKey {
12481230
parseAndSetFavoriteAttr(ctx, attrs)

0 commit comments

Comments
 (0)