Hi all,
I deployed my
ejb in Weblogic 8.1. In my client, i am having the username/role, the welogic server has to check for the username/role and then allow to access that EJB. I got struck here, please help me by giving sample code or some tips...
ejb-jar.xml
<!DOCTYPE ejb-jar PUBLIC
"-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN"
"http://java.sun.com/dtd/ejb-jar_2_0.dtd">
<ejb-jar>
<enterprise-beans>
<session>
<ejb-name>SIApp</ejb-name>
<home>com.lawson.ejb.SIHome</home>
<remote>com.lawson.ejb.SI</remote>
<ejb-class>com.lawson.ejb.SIBean</ejb-class>
<session-type>Stateful</session-type>
<transaction-type>Bean</transaction-type>
</session>
</enterprise-beans>
<assembly-descriptor>
<security-role>
<role-name>testrole</role-name>
</security-role>
<method-permission>
<role-name>testrole</role-name>
<method>
<ejb-name>SIApp</ejb-name>
<method-name>*</method-name>
</method>
</method-permission>
</assembly-descriptor>
</ejb-jar>
weblogic-ejb-jar.xml
<?xml version="1.0"?>
<!DOCTYPE weblogic-ejb-jar PUBLIC
'-//BEA Systems, Inc.//DTD WebLogic 8.1.0 EJB//EN'
'http://www.bea.com/servers/wls810/dtd/weblogic-ejb-jar.dtd'>
<weblogic-ejb-jar>
<weblogic-enterprise-bean>
<ejb-name>SIApp</ejb-name>
<jndi-name>SimpleInterest</jndi-name>
</weblogic-enterprise-bean>
<security-role-assignment>
<role-name>testrole</role-name>
<principal-name>everyone</principal-name>
</security-role-assignment>
</weblogic-ejb-jar>
How can I use these in my Client....?
Thanks and regards
Mohan.G