Hi What's the issue? Le 2 oct. 2013 21:50, "Mark Hanfland" a écrit : > I am converting from JBoss and unsure how to set the security realm for my > EJBs in TomEE Plus /OpenEJB > > In JBoss there is an annotation > (org.jboss.annotation.security.SecurityDomain) you place on the EJB bean > @SecurityDomain(value = "MySecurityRealm") > > For TomEE/OpenEJB what is the equivalent?? > > I am not sure, but I think I have the realm created correctly. > > Added in server.xml > appName="MySecurityRealm" > > > userClassNames="org.apache.openejb.core.security.AbstractSecurityService$User" > > > roleClassNames="org.apache.openejb.core.security.AbstractSecurityService$Group"> > > > Created login.conf with the following > > MySecurityRealm { > org.apache.openejb.core.security.jaas.SQLLoginModule required > dataSourceName="MyDataSource" > digest MD5 > encoding base64 > userSelect="SELECT USER_NAME,PASSWORD FROM ADMIN_USER WHERE > USER_NAME=?" > groupSelect="SELECT USER_NAME, ROLE_CODE FROM ADMIN_ROLE, > ADMIN_USER_ROLE, ADMIN_USER WHERE ADMIN_USER.ADMIN_USER_ID = > ADMIN_USER_ROLE.ADMIN_USER_ID AND ADMIN_ROLE.ADMIN_ROLE_ID = > ADMIN_USER_ROLE.ADMIN_ROLE_ID AND ADMIN_USER.USER_NAME=?" > }; > > pointed Tomcat to it using > SET > > "CATALINA_OPTS=-Djava.security.auth.login.config=%CATALINA_HOME%/conf/login.conf" > > > > > -- > View this message in context: > http://openejb.979440.n4.nabble.com/OpenEJB-TomEE-Security-Realm-tp4665393.html > Sent from the OpenEJB User mailing list archive at Nabble.com. >