mirror of
https://github.com/DSpace/DSpace.git
synced 2025-10-13 04:53:16 +00:00
Fix for GHSA-cf2j-vf36-c6w8
This commit is contained in:
@@ -920,8 +920,7 @@ public class CollectionServiceImpl extends DSpaceObjectServiceImpl<Collection> i
|
||||
int defaultRead)
|
||||
throws SQLException, AuthorizeException {
|
||||
Group role = groupService.create(context);
|
||||
groupService.setName(role, "COLLECTION_" + collection.getID().toString() + "_" + typeOfGroupString +
|
||||
"_DEFAULT_READ");
|
||||
groupService.setName(role, getDefaultReadGroupName(collection, typeOfGroupString));
|
||||
|
||||
// Remove existing privileges from the anonymous group.
|
||||
authorizeService.removePoliciesActionFilter(context, collection, defaultRead);
|
||||
@@ -932,6 +931,12 @@ public class CollectionServiceImpl extends DSpaceObjectServiceImpl<Collection> i
|
||||
return role;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getDefaultReadGroupName(Collection collection, String typeOfGroupString) {
|
||||
return "COLLECTION_" + collection.getID().toString() + "_" + typeOfGroupString +
|
||||
"_DEFAULT_READ";
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Collection> findCollectionsWithSubmit(String q, Context context, Community community,
|
||||
int offset, int limit) throws SQLException, SearchServiceException {
|
||||
|
Reference in New Issue
Block a user