add a permission check to the logo upload

This commit is contained in:
David Christofas
2023-02-09 16:18:44 +01:00
parent 13dfc06f63
commit 7c17ddb0b0
10 changed files with 137 additions and 25 deletions

View File

@@ -1,7 +1,6 @@
package defaults
import (
"net/http"
"path"
"strings"
@@ -84,6 +83,10 @@ func DefaultPolicies() []config.Policy {
Service: "com.owncloud.web.idp",
Unprotected: true,
},
{
Endpoint: "/branding/logo",
Service: "com.owncloud.web.web",
},
{
Endpoint: "/konnect/",
Service: "com.owncloud.web.idp",
@@ -199,11 +202,6 @@ func DefaultPolicies() []config.Policy {
Endpoint: "/api/v0/settings",
Service: "com.owncloud.web.settings",
},
{
Method: http.MethodPost,
Endpoint: "/branding/logo",
Service: "com.owncloud.web.web",
},
},
},
}