[jboss-cvs] JBossAS SVN: r100860 - in projects/ejb3/trunk/security: src/main/java/org/jboss/ejb3/security/helpers and 3 other directories.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Thu Feb 11 04:55:11 EST 2010


Author: wolfc
Date: 2010-02-11 04:55:10 -0500 (Thu, 11 Feb 2010)
New Revision: 100860

Added:
   projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/
   projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/CustomPrincipal.java
   projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/RealmMappingUnitTestCase.java
   projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/SecuredBean.java
   projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/SimplePolicyRegistration.java
   projects/ejb3/trunk/security/src/test/resources/jaas.conf
   projects/ejb3/trunk/security/src/test/resources/jboss-aop.xml
   projects/ejb3/trunk/security/src/test/resources/jndi.properties
   projects/ejb3/trunk/security/src/test/resources/log4j.xml
   projects/ejb3/trunk/security/src/test/resources/roles.properties
   projects/ejb3/trunk/security/src/test/resources/users.properties
Modified:
   projects/ejb3/trunk/security/pom.xml
   projects/ejb3/trunk/security/src/main/java/org/jboss/ejb3/security/helpers/EJBContextHelper.java
Log:
EJBTHREE-1756: map the caller principal through RealmMapping

Modified: projects/ejb3/trunk/security/pom.xml
===================================================================
--- projects/ejb3/trunk/security/pom.xml	2010-02-11 08:45:48 UTC (rev 100859)
+++ projects/ejb3/trunk/security/pom.xml	2010-02-11 09:55:10 UTC (rev 100860)
@@ -53,6 +53,13 @@
 
     <dependency>
       <groupId>org.jboss.aspects</groupId>
+      <artifactId>jboss-aspects-common</artifactId>
+      <version>1.0.0.Beta1</version>
+      <scope>test</scope>
+    </dependency>
+
+    <dependency>
+      <groupId>org.jboss.aspects</groupId>
       <artifactId>jboss-current-invocation-aspects</artifactId>
       <version>1.0.0.CR1</version>
     </dependency>
@@ -136,6 +143,12 @@
       <artifactId>jboss-metadata</artifactId>
     </dependency>
 
+    <dependency>
+      <groupId>org.jboss.naming</groupId>
+      <artifactId>jnpserver</artifactId>
+      <scope>test</scope>
+    </dependency>
+
     <!-- JUnit -->
     <dependency>
       <groupId>junit</groupId>

Modified: projects/ejb3/trunk/security/src/main/java/org/jboss/ejb3/security/helpers/EJBContextHelper.java
===================================================================
--- projects/ejb3/trunk/security/src/main/java/org/jboss/ejb3/security/helpers/EJBContextHelper.java	2010-02-11 08:45:48 UTC (rev 100859)
+++ projects/ejb3/trunk/security/src/main/java/org/jboss/ejb3/security/helpers/EJBContextHelper.java	2010-02-11 09:55:10 UTC (rev 100860)
@@ -84,8 +84,6 @@
          {
             //try the incoming principal
             callerPrincipal = sc.getUtil().getUserPrincipal();
-            if (rm != null)
-               callerPrincipal = rm.getPrincipal(callerPrincipal);
          }
       }
       // either security context was absent or
@@ -103,7 +101,11 @@
             }
          }
       }
-      return callerPrincipal; 
+
+      if (rm != null)
+         callerPrincipal = rm.getPrincipal(callerPrincipal);
+      
+      return callerPrincipal;
    } 
    
    private static Invocation getCurrentInvocation(String reason)
@@ -217,4 +219,4 @@
          throw new IllegalStateException("No policy context id is set");
       return contextID;
    }
-}
\ No newline at end of file
+}

Added: projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/CustomPrincipal.java
===================================================================
--- projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/CustomPrincipal.java	                        (rev 0)
+++ projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/CustomPrincipal.java	2010-02-11 09:55:10 UTC (rev 100860)
@@ -0,0 +1,63 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright (c) 2010, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.ejb3.security.test.ejbthree1756;
+
+import java.security.Principal;
+
+/**
+ * @author <a href="cdewolf at redhat.com">Carlo de Wolf</a>
+ */
+public class CustomPrincipal implements Principal
+{
+   private static final long serialVersionUID = 1L;
+
+   private String name;
+
+   public CustomPrincipal(String name)
+   {
+      this.name = name;
+   }
+
+   @Override
+   public boolean equals(Object o)
+   {
+      if(this == o) return true;
+      if(o == null || getClass() != o.getClass()) return false;
+
+      CustomPrincipal that = (CustomPrincipal) o;
+
+      if(!name.equals(that.name)) return false;
+
+      return true;
+   }
+
+   public String getName()
+   {
+      return name;
+   }
+
+   @Override
+   public int hashCode()
+   {
+      return name.hashCode();
+   }
+}


Property changes on: projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/CustomPrincipal.java
___________________________________________________________________
Name: svn:keywords
   + Author Date Id Revision
Name: svn:eol-style
   + native

Added: projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/RealmMappingUnitTestCase.java
===================================================================
--- projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/RealmMappingUnitTestCase.java	                        (rev 0)
+++ projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/RealmMappingUnitTestCase.java	2010-02-11 09:55:10 UTC (rev 100860)
@@ -0,0 +1,108 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright (c) 2010, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.ejb3.security.test.ejbthree1756;
+
+import org.jboss.aspects.common.AOPDeployer;
+import org.jboss.ejb3.interceptors.container.BeanContext;
+import org.jboss.ejb3.interceptors.direct.DirectContainer;
+import org.jboss.security.SecurityAssociation;
+import org.jboss.security.client.SecurityClient;
+import org.jboss.security.client.SecurityClientFactory;
+import org.jboss.security.plugins.JBossAuthenticationManager;
+import org.jboss.security.plugins.JBossSecurityContext;
+import org.jboss.util.TimedCachePolicy;
+import org.jboss.util.naming.NonSerializableFactory;
+import org.jnp.server.SingletonNamingServer;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+import javax.naming.InitialContext;
+import java.security.Principal;
+
+import static org.junit.Assert.assertEquals;
+
+/**
+ * @author <a href="cdewolf at redhat.com">Carlo de Wolf</a>
+ */
+public class RealmMappingUnitTestCase
+{
+   private static AOPDeployer deployer = new AOPDeployer("jboss-aop.xml");
+
+   @AfterClass
+   public static void afterClass()
+   {
+      deployer.undeploy();
+   }
+
+   @BeforeClass
+   public static void beforeClass() throws Exception
+   {
+      System.setProperty("java.security.auth.login.config", RealmMappingUnitTestCase.class.getResource("/jaas.conf").toString());
+      SecurityAssociation.setServer();
+      
+      deployer.deploy();
+
+      new SingletonNamingServer();
+
+      InitialContext ctx = new InitialContext();
+      ctx.bind("java:policyRegistration", new SimplePolicyRegistration());
+
+      JBossSecurityContext context = new JBossSecurityContext("TestApp");
+      JBossAuthenticationManager authenticationManager = (JBossAuthenticationManager) context.getAuthenticationManager();
+      TimedCachePolicy domainCache = new TimedCachePolicy();
+      domainCache.create();
+      domainCache.start();
+      authenticationManager.setCachePolicy(domainCache);
+      NonSerializableFactory.rebind(ctx, "java:AuthenticationManager", authenticationManager);
+   }
+
+   @Test
+   public void testAnonymous() throws Throwable
+   {
+      DirectContainer<SecuredBean> container = new DirectContainer<SecuredBean>("Test", "SimpleContainer", SecuredBean.class);
+      BeanContext<SecuredBean> bean = container.construct();
+      Principal callerPrincipal = container.invoke(bean, "getCallerPrincipal");
+      assertEquals(CustomPrincipal.class, callerPrincipal.getClass());
+      assertEquals("anonymous", callerPrincipal.getName());
+   }
+
+   @Test
+   public void testTestUser() throws Throwable
+   {
+      SecurityClient client = SecurityClientFactory.getSecurityClient();
+      client.setSimple("testuser", "testpwd");
+      client.login();
+      try
+      {
+         DirectContainer<SecuredBean> container = new DirectContainer<SecuredBean>("Test", "SimpleContainer", SecuredBean.class);
+         BeanContext<SecuredBean> bean = container.construct();
+         Principal callerPrincipal = container.invoke(bean, "getCallerPrincipal");
+         assertEquals(CustomPrincipal.class, callerPrincipal.getClass());
+         assertEquals("testuser", callerPrincipal.getName());
+      }
+      finally
+      {
+         client.logout();
+      }
+   }
+}


Property changes on: projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/RealmMappingUnitTestCase.java
___________________________________________________________________
Name: svn:keywords
   + Author Date Id Revision
Name: svn:eol-style
   + native

Added: projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/SecuredBean.java
===================================================================
--- projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/SecuredBean.java	                        (rev 0)
+++ projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/SecuredBean.java	2010-02-11 09:55:10 UTC (rev 100860)
@@ -0,0 +1,111 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright (c) 2010, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.ejb3.security.test.ejbthree1756;
+
+import org.jboss.ejb3.annotation.SecurityDomain;
+import org.jboss.ejb3.security.helpers.EJBContextHelper;
+import org.jboss.security.*;
+import org.jboss.security.audit.AuditManager;
+import org.jboss.security.identitytrust.IdentityTrustManager;
+import org.jboss.security.javaee.EJBAuthenticationHelper;
+import org.jboss.security.javaee.SecurityHelperFactory;
+import org.jboss.security.mapping.MappingManager;
+
+import javax.naming.InitialContext;
+import javax.naming.NamingException;
+import javax.security.auth.Subject;
+import java.security.Principal;
+
+/**
+ * @author <a href="cdewolf at redhat.com">Carlo de Wolf</a>
+ */
+public class SecuredBean
+{
+   public Principal getCallerPrincipal() throws Exception
+   {
+      SecurityContext prevSC = SecurityContextAssociation.getSecurityContext();
+      EJBContextHelper helper = new EJBContextHelper();
+      final SecurityContext sc = SecurityContextFactory.createSecurityContext("TestApp");
+      if(prevSC != null)
+         sc.setSubjectInfo(prevSC.getSubjectInfo());
+      sc.setSecurityManagement(new ISecurityManagement()
+      {
+         public AuthenticationManager getAuthenticationManager(String securityDomain)
+         {
+            return lookup("java:AuthenticationManager", AuthenticationManager.class);
+         }
+
+         public AuthorizationManager getAuthorizationManager(String securityDomain)
+         {
+            throw new RuntimeException("NYI");
+         }
+
+         public MappingManager getMappingManager(String securityDomain)
+         {
+            throw new RuntimeException("NYI");
+         }
+
+         public AuditManager getAuditManager(String securityDomain)
+         {
+            return null;
+         }
+
+         public IdentityTrustManager getIdentityTrustManager(String securityDomain)
+         {
+            throw new RuntimeException("NYI");
+         }
+      });
+      SecurityContextAssociation.setSecurityContext(sc);
+      try
+      {
+         EJBAuthenticationHelper authenticationHelper = SecurityHelperFactory.getEJBAuthenticationHelper(sc);
+         Subject subject = new Subject();
+         boolean isValid = authenticationHelper.isValid(subject, "getCallerPrincipal");
+         if(!isValid)
+         {
+            Exception cause = (Exception) sc.getData().get("org.jboss.security.exception");
+            throw new RuntimeException("no valid principal", cause);
+         }
+         authenticationHelper.pushSubjectContext(subject);
+         //RealmMapping rm = (RealmMapping) sc.getAuthenticationManager();
+         RealmMapping rm = lookup("java:AuthenticationManager", RealmMapping.class);
+         SecurityDomain domain = null;
+         return helper.getCallerPrincipal(sc, rm, domain);
+      }
+      finally
+      {
+         SecurityContextAssociation.clearSecurityContext();
+      }
+   }
+
+   private static <T> T lookup(String name, Class<T> expectedType)
+   {
+      try
+      {
+         return expectedType.cast(new InitialContext().lookup(name));
+      }
+      catch(NamingException e)
+      {
+         throw new RuntimeException(e);
+      }
+   }
+}


Property changes on: projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/SecuredBean.java
___________________________________________________________________
Name: svn:keywords
   + Author Date Id Revision
Name: svn:eol-style
   + native

Copied: projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/SimplePolicyRegistration.java (from rev 100695, projects/ejb3/trunk/core/src/test/java/org/jboss/ejb3/core/test/common/security/SimplePolicyRegistration.java)
===================================================================
--- projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/SimplePolicyRegistration.java	                        (rev 0)
+++ projects/ejb3/trunk/security/src/test/java/org/jboss/ejb3/security/test/ejbthree1756/SimplePolicyRegistration.java	2010-02-11 09:55:10 UTC (rev 100860)
@@ -0,0 +1,95 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright (c) 2010, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.ejb3.security.test.ejbthree1756;
+
+import org.jboss.security.authorization.PolicyRegistration;
+
+import java.io.InputStream;
+import java.io.Serializable;
+import java.net.URL;
+import java.util.Map;
+
+/**
+ * @author <a href="mailto:cdewolf at redhat.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class SimplePolicyRegistration implements PolicyRegistration, Serializable
+{
+   private static final long serialVersionUID = 1L;
+
+   /* (non-Javadoc)
+    * @see org.jboss.security.authorization.PolicyRegistration#deRegisterPolicy(java.lang.String, java.lang.String)
+    */
+   public void deRegisterPolicy(String contextID, String type)
+   {
+      // TODO Auto-generated method stub
+      //
+      throw new RuntimeException("NYI");
+   }
+
+   /* (non-Javadoc)
+    * @see org.jboss.security.authorization.PolicyRegistration#getPolicy(java.lang.String, java.lang.String, java.util.Map)
+    */
+   public <T> T getPolicy(String contextID, String type, Map<String, Object> contextMap)
+   {
+      // TODO Auto-generated method stub
+      //return null;
+      throw new RuntimeException("NYI");
+   }
+
+   /* (non-Javadoc)
+    * @see org.jboss.security.authorization.PolicyRegistration#registerPolicy(java.lang.String, java.lang.String, java.net.URL)
+    */
+   public void registerPolicy(String contextID, String type, URL location)
+   {
+      // TODO Auto-generated method stub
+      //
+      throw new RuntimeException("NYI");
+   }
+
+   /* (non-Javadoc)
+    * @see org.jboss.security.authorization.PolicyRegistration#registerPolicy(java.lang.String, java.lang.String, java.io.InputStream)
+    */
+   public void registerPolicy(String contextID, String type, InputStream stream)
+   {
+      // TODO Auto-generated method stub
+      //
+      throw new RuntimeException("NYI");
+   }
+
+   /* (non-Javadoc)
+    * @see org.jboss.security.authorization.PolicyRegistration#registerPolicyConfigFile(java.lang.String, java.lang.String, java.io.InputStream)
+    */
+   public void registerPolicyConfigFile(String contextId, String type, InputStream stream)
+   {
+      // TODO Auto-generated method stub
+      //
+      throw new RuntimeException("NYI");
+   }
+
+   public <P> void registerPolicyConfig(String contextId, String type, P policyConfig)
+   {
+      // TODO Auto-generated method stub
+      throw new RuntimeException("NYI");
+   }
+
+}
\ No newline at end of file

Added: projects/ejb3/trunk/security/src/test/resources/jaas.conf
===================================================================
--- projects/ejb3/trunk/security/src/test/resources/jaas.conf	                        (rev 0)
+++ projects/ejb3/trunk/security/src/test/resources/jaas.conf	2010-02-11 09:55:10 UTC (rev 100860)
@@ -0,0 +1,3 @@
+TestApp {
+    org.jboss.security.auth.spi.UsersRolesLoginModule REQUIRED unauthenticatedIdentity=anonymous principalClass="org.jboss.ejb3.security.test.ejbthree1756.CustomPrincipal";
+};
\ No newline at end of file

Added: projects/ejb3/trunk/security/src/test/resources/jboss-aop.xml
===================================================================
--- projects/ejb3/trunk/security/src/test/resources/jboss-aop.xml	                        (rev 0)
+++ projects/ejb3/trunk/security/src/test/resources/jboss-aop.xml	2010-02-11 09:55:10 UTC (rev 100860)
@@ -0,0 +1,9 @@
+<aop>
+   <interceptor name="CurrentInvocation" class="org.jboss.aspects.currentinvocation.CurrentInvocationInterceptor" scope="PER_VM"/>
+
+   <domain name="SimpleContainer">
+      <bind pointcut="execution(public * *->*(..))">
+         <interceptor-ref name="CurrentInvocation"/>
+      </bind>
+   </domain>
+</aop>
\ No newline at end of file


Property changes on: projects/ejb3/trunk/security/src/test/resources/jboss-aop.xml
___________________________________________________________________
Name: svn:keywords
   + Author Date Id Revision
Name: svn:eol-style
   + native

Copied: projects/ejb3/trunk/security/src/test/resources/jndi.properties (from rev 100695, projects/ejb3/trunk/core/src/test/resources/jndi.properties)
===================================================================
--- projects/ejb3/trunk/security/src/test/resources/jndi.properties	                        (rev 0)
+++ projects/ejb3/trunk/security/src/test/resources/jndi.properties	2010-02-11 09:55:10 UTC (rev 100860)
@@ -0,0 +1,2 @@
+java.naming.factory.initial=org.jnp.interfaces.LocalOnlyContextFactory
+java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces

Added: projects/ejb3/trunk/security/src/test/resources/log4j.xml
===================================================================
--- projects/ejb3/trunk/security/src/test/resources/log4j.xml	                        (rev 0)
+++ projects/ejb3/trunk/security/src/test/resources/log4j.xml	2010-02-11 09:55:10 UTC (rev 100860)
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
+<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" debug="false">
+   <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
+      <param name="Target" value="System.out"/>
+
+      <layout class="org.apache.log4j.PatternLayout">
+         <!-- The default pattern: Date Priority [Category] Message\n -->
+         <param name="ConversionPattern" value="%d{ABSOLUTE} %-5p [%c{1}] %m%n"/>
+      </layout>
+   </appender>
+
+   <root>
+      <appender-ref ref="CONSOLE"/>
+   </root>
+</log4j:configuration>
\ No newline at end of file


Property changes on: projects/ejb3/trunk/security/src/test/resources/log4j.xml
___________________________________________________________________
Name: svn:keywords
   + Author Date Id Revision
Name: svn:eol-style
   + native

Added: projects/ejb3/trunk/security/src/test/resources/roles.properties
===================================================================
--- projects/ejb3/trunk/security/src/test/resources/roles.properties	                        (rev 0)
+++ projects/ejb3/trunk/security/src/test/resources/roles.properties	2010-02-11 09:55:10 UTC (rev 100860)
@@ -0,0 +1,4 @@
+anonymous.CallerPrincipal=anonymous
+
+testuser=testrole
+testuser.CallerPrincipal=testuser
\ No newline at end of file

Added: projects/ejb3/trunk/security/src/test/resources/users.properties
===================================================================
--- projects/ejb3/trunk/security/src/test/resources/users.properties	                        (rev 0)
+++ projects/ejb3/trunk/security/src/test/resources/users.properties	2010-02-11 09:55:10 UTC (rev 100860)
@@ -0,0 +1 @@
+testuser=testpwd
\ No newline at end of file




More information about the jboss-cvs-commits mailing list