hdygxsj commented on code in PR #7736:
URL: https://github.com/apache/gravitino/pull/7736#discussion_r2222960496
##########
server/src/main/java/org/apache/gravitino/server/web/rest/PermissionOperations.java:
##########
@@ -173,8 +184,10 @@ public Response revokeRolesFromGroup(
@Produces("application/vnd.gravitino.v1+json")
@Timed(name = "grant-privilege-to-role." +
MetricNames.HTTP_PROCESS_DURATION, absolute = true)
@ResponseMetered(name = "grant-privilege-to-role", absolute = true)
+ @AuthorizationExpression(expression = "METALAKE::OWNER ||
METALAKE::MANAGE_GRANTS")
public Response grantPrivilegeToRole(
Review Comment:
fixed
##########
server/src/main/java/org/apache/gravitino/server/web/rest/RoleOperations.java:
##########
@@ -177,8 +207,11 @@ public Response createRole(@PathParam("metalake") String
metalake, RoleCreateReq
@Produces("application/vnd.gravitino.v1+json")
@Timed(name = "delete-role." + MetricNames.HTTP_PROCESS_DURATION, absolute =
true)
@ResponseMetered(name = "delete-role", absolute = true)
+ @AuthorizationExpression(expression = "METALAKE::OWNER")
Review Comment:
fixed
##########
server/src/main/java/org/apache/gravitino/server/web/rest/UserOperations.java:
##########
@@ -67,7 +76,11 @@ public UserOperations() {
@Produces("application/vnd.gravitino.v1+json")
@Timed(name = "get-user." + MetricNames.HTTP_PROCESS_DURATION, absolute =
true)
@ResponseMetered(name = "get-user", absolute = true)
- public Response getUser(@PathParam("metalake") String metalake,
@PathParam("user") String user) {
+ @AuthorizationExpression(expression = "METALAKE::OWNER || USER::SELF")
Review Comment:
fixed
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]