Package ubic.gemma.core.security.acl
@ParametersAreNonnullByDefault
package ubic.gemma.core.security.acl
-
ClassesClassDescriptionFast unit tests for
AclEventListener.SecuredChild without a populatedgetSecurityOwner— the realistic case for BioAssay / FactorValue persisted via ExpressionPersister.SecuredChild with an explicit ManyToOne back-ref to aAclEventListenerTest.ChildNoOwner— exercises the force-flatten reconciliation when the back-ref ACL gets its own parent set late.SecuredChild that exposes a populatedAclEventListenerTest.ChildWithOwner.getSecurityOwner()— covers the locateParentAcl path (used when entity-author wired the back-ref explicitly).SecuredNotChild — its own ACL root.SecuredChild with only a SecuredNotChild back-ref.Fluent builder for a per-entity-classEntityPersistermock.Plain top-level Securable.SecuredChild that references another instance of its own class — covers the cycle guard in the recursive fixup walk.MinimalBaseAclAdviceconcrete subclass.SecuredChild with two ManyToOne back-refs: one to aSecuredNotChildroot and one to anotherSecuredChild.Reproducer for the long-standing Phase-3 ACL evaluation bug surfaced byUserGroupServiceTest#testUpdateUserGroup: when the admin test user (authorityGROUP_ADMIN) calls a method protected by@PreAuthorize("hasPermission(#group, 'administration')")on a UserGroup whose ACL was created byBaseAclAdvice.setupBaseAces(MutableAcl, ObjectIdentity, Sid, boolean)— which inserts aGrantedAuthoritySid("GROUP_ADMIN") ADMINISTRATION granting=trueACE — the evaluation returnsfalseeven though by inspection it should returntrue.MinimalSecurablestand-in — only needs a class name and id for theObjectIdentityImplkey.Regression guard for the CLI-only failure in which the Hibernate event listeners were never registered.Test-onlyAclServicethat stores ACLs in an in-memoryMapusing real Spring SecurityAclImplinstances.