You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Add JSR-250 annotation support to shiro-aspectj #2979
Background
Apache Shiro's security model and the reply from the security mailing list both state that the AspectJ integration has never supported the @RolesAllowed, @permitAll and @Denyall annotations. This is a missing feature rather than a security vulnerability, and the team suggested raising it through a public issue as a feature request.
Request
Please add support for JSR-250 security annotations to shiro-aspectj, bringing it in line with other integrations such as CDI.
Current Status
AuthorizationAnnotations.allTypes() already conditionally registers JSR-250 annotations when jakarta.annotation is available on the classpath. ShiroAnnotationAuthorizingAspect's pointcut historically covered only the five Shiro annotations. PR #2974 changed it to a broad match plus AnnotationHierarchy, but the gate still checks only AuthorizationAnnotations.shiroTypes(). As a result, applications that use JSR-250 annotations and rely on AspectJ weaving have those authorization annotations silently ignored.
Suggestion
Change the AspectJ gate from AuthorizationAnnotations.shiroTypes() to AuthorizationAnnotations.allTypes(), or otherwise include the JSR-250 annotation types, and add corresponding weaving tests.
Note
This is a feature enhancement request, not a security vulnerability report.
Activity
lprimak commentedon Nov 30, 2026
Thanks for your report. Would you consider issuing PR for this? Thank you.