Remove PermissionBackend#user(Provider<CurrentUser>)
Checking permissions of users that aren't the caller on the current request can have implications on the security of the system. The most prominent one is creating a group-oracle. To limit the cases where we could potentially expose Gerrit to these threats, PermissionBackend removes the method that was operating solely on the provider of the current user. Change-Id: I601ea1200a15a5f262ca0770b23cc1c7bee126b1
This commit is contained in:
@@ -360,7 +360,7 @@ public class PostReviewers
|
||||
ListMultimap<RecipientType, Account.Id> accountsToNotify)
|
||||
throws PermissionBackendException {
|
||||
if (!permissionBackend
|
||||
.user(anonymousProvider)
|
||||
.user(anonymousProvider.get())
|
||||
.change(rsrc.getNotes())
|
||||
.database(dbProvider)
|
||||
.test(ChangePermission.READ)) {
|
||||
|
||||
Reference in New Issue
Block a user