Hi all, AuthorizingRealm is a good starting point for most custom realms, however the large number of private methods prevent real customization. Over a year ago, someone already asked to change isPermitted to protected in SHIRO-332 and now we are facing similar issues.
In our application it is quite expensive to resolve the permissions for a role, so I want to cache the permissions for an AuthorizationInfo, just as the AuthorizationInfo itself is cached. For this to work, I have to change the implementation of getPermissions to first check the cache and then perform the default behavior. If getPermissions were protected, I could simply override that method, check the cache and call super if nothing was cached, but now I have to copy-paste all these methods (over 100 lines of code) to change only a few lines: private Collection<Permission> getPermissions(AuthorizationInfo) to change the code private Collection<Permission> resolvePermissions(Collection<String>) private Collection<Permission> resolveRolePermissions(Collection<String>) because they are used by getPermissions and private private boolean isPermitted(Permission, AuthorizationInfo) because it uses getPermissions protected void checkPermission(Permission, AuthorizationInfo) protected boolean[] isPermitted(List<Permission>, AuthorizationInfo) public boolean isPermitted(PrincipalCollection, Permission) protected boolean isPermittedAll(Collection<Permission>, AuthorizationInfo) because they use isPermitted Can this issue please be fixed for 1.2.2? The changes are binary compatible and small, but would help is a lot. Best regards, Emond Papegaaij
