-
Bug
-
Resolution: Done
-
Major
-
None
-
None
In https://github.com/wildfly/wildfly/commit/38f8f5915b40d036bd0fd1a904d6a13916f3fa2c#diff-faf7ca63d4b901f1bff0697491c8f5ddL1147 you added check on if (securityRoles != null).
securityRoles is not checked few lines below your check (in different if block)
https://github.com/wildfly/wildfly/blob/master/ejb3/src/main/java/org/jboss/as/ejb3/component/EJBComponentDescription.java#L1162 (securityRoles.getSecurityRoleNamesByPrincipal ... )
I suggest to change https://github.com/wildfly/wildfly/blob/master/ejb3/src/main/java/org/jboss/as/ejb3/component/EJBComponentDescription.java#L1158 from
if (runAsPrincipal != null) {
to
if ((securityRoles != null) && (runAsPrincipal != null)) {
- clones
-
JBEAP-9217 EJBComponentDescription : possible NPE on securityRoles
- Closed