herb wrote:
But shouldn't do "@SecurityDomain" (at EJB level) the same as jboss-ejb3.xml (as also mentioned in https://community.jboss.org/thread/177728)?
Like I expected, you are using the wrong annotation:
import org.jboss.security.annotation.SecurityDomain;
@Stateless
@SecurityDomain(value = "formauth")
public class Ejb
You should be using @org.jboss.ejb3.annotation.SecurityDomain