User: starksm
Date: 01/07/09 01:54:12
Modified: src/resources/security/META-INF Tag: Branch_2_4 ejb-jar.xml
jboss-spec.xml jboss.xml
Log:
Added test of an unsecure MDB accessing an internal entity EJB using
the run-as element.
Revision Changes Path
No revision
No revision
1.7.2.1 +79 -54 jbosstest/src/resources/security/META-INF/ejb-jar.xml
Index: ejb-jar.xml
===================================================================
RCS file: /cvsroot/jboss/jbosstest/src/resources/security/META-INF/ejb-jar.xml,v
retrieving revision 1.7
retrieving revision 1.7.2.1
diff -u -r1.7 -r1.7.2.1
--- ejb-jar.xml 2001/06/15 08:48:25 1.7
+++ ejb-jar.xml 2001/07/09 08:54:12 1.7.2.1
@@ -89,61 +89,86 @@
</security-identity>
</session>
- <session>
- <description>An unsecured trival echo session bean</description>
- <ejb-name>UnsecureStatelessSession</ejb-name>
- <home>org.jboss.test.security.interfaces.StatelessSessionHome</home>
- <remote>org.jboss.test.security.interfaces.StatelessSession</remote>
- <ejb-class>org.jboss.test.security.ejb.StatelessSessionBean</ejb-class>
- <session-type>Stateless</session-type>
- <transaction-type>Container</transaction-type>
- </session>
- <session>
- <description>An unsecured trival echo session bean type 2</description>
- <ejb-name>UnsecureStatelessSession2</ejb-name>
- <home>org.jboss.test.security.interfaces.StatelessSessionHome</home>
- <remote>org.jboss.test.security.interfaces.StatelessSession</remote>
- <ejb-class>org.jboss.test.security.ejb.StatelessSessionBean2</ejb-class>
- <session-type>Stateless</session-type>
- <transaction-type>Container</transaction-type>
- <ejb-ref>
- <ejb-ref-name>ejb/Entity</ejb-ref-name>
- <ejb-ref-type>Entity</ejb-ref-type>
- <home>org.jboss.test.security.interfaces.EntityHome</home>
- <remote>org.jboss.test.security.interfaces.Entity</remote>
- <ejb-link>Entity</ejb-link>
- </ejb-ref>
- <ejb-ref>
- <ejb-ref-name>ejb/Session</ejb-ref-name>
- <ejb-ref-type>Session</ejb-ref-type>
- <home>org.jboss.test.security.interfaces.StatelessSessionHome</home>
- <remote>org.jboss.test.security.interfaces.StatelessSession</remote>
- <ejb-link>StatelessSession</ejb-link>
- </ejb-ref>
- </session>
+ <session>
+ <description>An unsecured trival echo session bean</description>
+ <ejb-name>UnsecureStatelessSession</ejb-name>
+ <home>org.jboss.test.security.interfaces.StatelessSessionHome</home>
+ <remote>org.jboss.test.security.interfaces.StatelessSession</remote>
+ <ejb-class>org.jboss.test.security.ejb.StatelessSessionBean</ejb-class>
+ <session-type>Stateless</session-type>
+ <transaction-type>Container</transaction-type>
+ </session>
+ <session>
+ <description>An unsecured trival echo session bean type 2</description>
+ <ejb-name>UnsecureStatelessSession2</ejb-name>
+ <home>org.jboss.test.security.interfaces.StatelessSessionHome</home>
+ <remote>org.jboss.test.security.interfaces.StatelessSession</remote>
+ <ejb-class>org.jboss.test.security.ejb.StatelessSessionBean2</ejb-class>
+ <session-type>Stateless</session-type>
+ <transaction-type>Container</transaction-type>
+ <ejb-ref>
+ <ejb-ref-name>ejb/Entity</ejb-ref-name>
+ <ejb-ref-type>Entity</ejb-ref-type>
+ <home>org.jboss.test.security.interfaces.EntityHome</home>
+ <remote>org.jboss.test.security.interfaces.Entity</remote>
+ <ejb-link>Entity</ejb-link>
+ </ejb-ref>
+ <ejb-ref>
+ <ejb-ref-name>ejb/Session</ejb-ref-name>
+ <ejb-ref-type>Session</ejb-ref-type>
+ <home>org.jboss.test.security.interfaces.StatelessSessionHome</home>
+ <remote>org.jboss.test.security.interfaces.StatelessSession</remote>
+ <ejb-link>StatelessSession</ejb-link>
+ </ejb-ref>
+ </session>
- <entity>
- <description>A trival echo entity bean</description>
- <ejb-name>Entity</ejb-name>
- <home>org.jboss.test.security.interfaces.EntityHome</home>
- <remote>org.jboss.test.security.interfaces.Entity</remote>
- <ejb-class>org.jboss.test.security.ejb.EntityBeanImpl</ejb-class>
- <persistence-type>Bean</persistence-type>
- <prim-key-class>java.lang.String</prim-key-class>
- <reentrant>False</reentrant>
- </entity>
- <entity>
- <description>A trival echo entity bean that should only be
- accessible via other beans</description>
- <ejb-name>PrivateEntity</ejb-name>
- <home>org.jboss.test.security.interfaces.EntityHome</home>
- <remote>org.jboss.test.security.interfaces.Entity</remote>
- <ejb-class>org.jboss.test.security.ejb.EntityBeanImpl</ejb-class>
- <persistence-type>Bean</persistence-type>
- <prim-key-class>java.lang.String</prim-key-class>
- <reentrant>False</reentrant>
- </entity>
- </enterprise-beans>
+ <entity>
+ <description>A trival echo entity bean</description>
+ <ejb-name>Entity</ejb-name>
+ <home>org.jboss.test.security.interfaces.EntityHome</home>
+ <remote>org.jboss.test.security.interfaces.Entity</remote>
+ <ejb-class>org.jboss.test.security.ejb.EntityBeanImpl</ejb-class>
+ <persistence-type>Bean</persistence-type>
+ <prim-key-class>java.lang.String</prim-key-class>
+ <reentrant>False</reentrant>
+ </entity>
+ <entity>
+ <description>A trival echo entity bean that should only be
+ accessible via other beans</description>
+ <ejb-name>PrivateEntity</ejb-name>
+ <home>org.jboss.test.security.interfaces.EntityHome</home>
+ <remote>org.jboss.test.security.interfaces.Entity</remote>
+ <ejb-class>org.jboss.test.security.ejb.EntityBeanImpl</ejb-class>
+ <persistence-type>Bean</persistence-type>
+ <prim-key-class>java.lang.String</prim-key-class>
+ <reentrant>False</reentrant>
+ </entity>
+
+ <message-driven>
+ <description>A trival echo entity bean</description>
+ <ejb-name>RunAsMDB</ejb-name>
+ <ejb-class>org.jboss.test.security.ejb.RunAsMDB</ejb-class>
+ <transaction-type>Container</transaction-type>
+ <message-driven-destination>
+ <destination-type>javax.jms.Queue</destination-type>
+ <subscription-durability>NonDurable</subscription-durability>
+ </message-driven-destination>
+ <ejb-ref>
+ <ejb-ref-name>ejb/Entity</ejb-ref-name>
+ <ejb-ref-type>Entity</ejb-ref-type>
+ <home>org.jboss.test.security.interfaces.EntityHome</home>
+ <remote>org.jboss.test.security.interfaces.Entity</remote>
+ <ejb-link>PrivateEntity</ejb-link>
+ </ejb-ref>
+ <security-identity>
+ <description>Use a role that is not assigned to any users to
+ access restricted server side functionallity</description>
+ <run-as>
+ <role-name>InternalRole</role-name>
+ </run-as>
+ </security-identity>
+ </message-driven>
+ </enterprise-beans>
<assembly-descriptor>
<security-role>
1.6.2.1 +10 -0 jbosstest/src/resources/security/META-INF/jboss-spec.xml
Index: jboss-spec.xml
===================================================================
RCS file: /cvsroot/jboss/jbosstest/src/resources/security/META-INF/jboss-spec.xml,v
retrieving revision 1.6
retrieving revision 1.6.2.1
diff -u -r1.6 -r1.6.2.1
--- jboss-spec.xml 2001/06/22 04:31:43 1.6
+++ jboss-spec.xml 2001/07/09 08:54:12 1.6.2.1
@@ -113,6 +113,16 @@
<jndi-name>spec.StatelessSession</jndi-name>
</ejb-ref>
</session>
+ <message-driven>
+ <ejb-name>RunAsMDB</ejb-name>
+ <configuration-name>Standard Message Driven Bean</configuration-name>
+ <destination-jndi-name>queue/A</destination-jndi-name>
+ <ejb-ref>
+ <ejb-ref-name>ejb/Entity</ejb-ref-name>
+ <jndi-name>spec.PrivateEntity</jndi-name>
+ </ejb-ref>
+ </message-driven>
+
</enterprise-beans>
</jboss>
1.2.2.1 +28 -23 jbosstest/src/resources/security/META-INF/jboss.xml
Index: jboss.xml
===================================================================
RCS file: /cvsroot/jboss/jbosstest/src/resources/security/META-INF/jboss.xml,v
retrieving revision 1.2
retrieving revision 1.2.2.1
diff -u -r1.2 -r1.2.2.1
--- jboss.xml 2001/06/13 04:54:06 1.2
+++ jboss.xml 2001/07/09 08:54:12 1.2.2.1
@@ -46,27 +46,32 @@
</container-configurations>
- <enterprise-beans>
- <session>
- <ejb-name>ProjRepository</ejb-name>
- <configuration-name>Standard Stateful SessionBean</configuration-name>
-
<security-proxy>org.jboss.test.security.proxy.ProjRepositorySecurityProxy2</security-proxy>
- </session>
- <session>
- <ejb-name>StatelessSession</ejb-name>
- <configuration-name>Standard Stateless SessionBean</configuration-name>
- </session>
- <session>
- <ejb-name>StatelessSession2</ejb-name>
- <configuration-name>Standard Stateless SessionBean</configuration-name>
- </session>
- <session>
- <ejb-name>UnsecureStatelessSession</ejb-name>
- <configuration-name>Unsecure Stateless SessionBean</configuration-name>
- </session>
- <entity>
- <ejb-name>Entity</ejb-name>
- <configuration-name>Standard BMP EntityBean</configuration-name>
- </entity>
- </enterprise-beans>
+ <enterprise-beans>
+ <session>
+ <ejb-name>ProjRepository</ejb-name>
+ <configuration-name>Standard Stateful SessionBean</configuration-name>
+
<security-proxy>org.jboss.test.security.proxy.ProjRepositorySecurityProxy2</security-proxy>
+ </session>
+ <session>
+ <ejb-name>StatelessSession</ejb-name>
+ <configuration-name>Standard Stateless SessionBean</configuration-name>
+ </session>
+ <session>
+ <ejb-name>StatelessSession2</ejb-name>
+ <configuration-name>Standard Stateless SessionBean</configuration-name>
+ </session>
+ <session>
+ <ejb-name>UnsecureStatelessSession</ejb-name>
+ <configuration-name>Unsecure Stateless SessionBean</configuration-name>
+ </session>
+ <entity>
+ <ejb-name>Entity</ejb-name>
+ <configuration-name>Standard BMP EntityBean</configuration-name>
+ </entity>
+ <message-driven>
+ <ejb-name>RunAsMDB</ejb-name>
+ <configuration-name>Standard Message Driven Bean</configuration-name>
+ <destination-jndi-name>queue/A</destination-jndi-name>
+ </message-driven>
+ </enterprise-beans>
</jboss>
_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-development