Author: jlim
Date: Mon Jan 15 18:05:48 2007
New Revision: 496571

URL: http://svn.apache.org/viewvc?view=rev&rev=496571
Log:
updated patch for https://issues.apache.org/activemq/browse/AMQ-1010

Modified:
    
incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/security/AuthenticationUser.java
    
incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/security/SimpleAuthenticationPlugin.java
    
incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/security/SimpleAuthenticationPluginTest.java
    
incubator/activemq/trunk/activemq-core/src/test/resources/org/apache/activemq/security/simple-auth-broker.xml

Modified: 
incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/security/AuthenticationUser.java
URL: 
http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/security/AuthenticationUser.java?view=diff&rev=496571&r1=496570&r2=496571
==============================================================================
--- 
incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/security/AuthenticationUser.java
 (original)
+++ 
incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/security/AuthenticationUser.java
 Mon Jan 15 18:05:48 2007
@@ -29,22 +29,22 @@
 
        String username;
        String password;
-       String group;
+       String groups;
        
        
        
-       public AuthenticationUser(String username, String password, String 
group) {
+       public AuthenticationUser(String username, String password, String 
groups) {
                this.username = username;
                this.password = password;
-               this.group = group;
+               this.groups = groups;
        }
        
        
-       public String getGroup() {
-               return group;
+       public String getGroups() {
+               return groups;
        }
-       public void setGroup(String group) {
-               this.group = group;
+       public void setGroups(String groups) {
+               this.groups = groups;
        }
        public String getPassword() {
                return password;

Modified: 
incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/security/SimpleAuthenticationPlugin.java
URL: 
http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/security/SimpleAuthenticationPlugin.java?view=diff&rev=496571&r1=496570&r2=496571
==============================================================================
--- 
incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/security/SimpleAuthenticationPlugin.java
 (original)
+++ 
incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/security/SimpleAuthenticationPlugin.java
 Mon Jan 15 18:05:48 2007
@@ -70,7 +70,7 @@
            AuthenticationUser user = (AuthenticationUser)it.next();
            userPasswords.put(user.getUsername(), user.getPassword());
             Set groups = new HashSet();
-            StringTokenizer iter = new StringTokenizer(user.getGroup(), ",");
+            StringTokenizer iter = new StringTokenizer(user.getGroups(), ",");
             while (iter.hasMoreTokens()) {
                 String name = iter.nextToken().trim();
                 groups.add(new GroupPrincipal(name));

Modified: 
incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/security/SimpleAuthenticationPluginTest.java
URL: 
http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/security/SimpleAuthenticationPluginTest.java?view=diff&rev=496571&r1=496570&r2=496571
==============================================================================
--- 
incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/security/SimpleAuthenticationPluginTest.java
 (original)
+++ 
incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/security/SimpleAuthenticationPluginTest.java
 Mon Jan 15 18:05:48 2007
@@ -28,10 +28,10 @@
 
 public class SimpleAuthenticationPluginTest extends SecurityTestSupport {
 
-    private static final Log log = LogFactory.getLog(XBeanSecurityTest.class);
+    private static final Log log = 
LogFactory.getLog(SimpleAuthenticationPluginTest.class);
     
     public static Test suite() {
-        return suite(XBeanSecurityTest.class);
+        return suite(SimpleAuthenticationPluginTest.class);
     }
 
     public static void main(String[] args) {

Modified: 
incubator/activemq/trunk/activemq-core/src/test/resources/org/apache/activemq/security/simple-auth-broker.xml
URL: 
http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/test/resources/org/apache/activemq/security/simple-auth-broker.xml?view=diff&rev=496571&r1=496570&r2=496571
==============================================================================
--- 
incubator/activemq/trunk/activemq-core/src/test/resources/org/apache/activemq/security/simple-auth-broker.xml
 (original)
+++ 
incubator/activemq/trunk/activemq-core/src/test/resources/org/apache/activemq/security/simple-auth-broker.xml
 Mon Jan 15 18:05:48 2007
@@ -27,10 +27,10 @@
                <simpleAuthenticationPlugin>
                        <users>
                                <authenticationUser username="system" 
password="manager"
-                                       group="users,admins"/>
+                                       groups="users,admins"/>
                                <authenticationUser username="user" 
password="password"
-                                       group="users"/>
-                               <authenticationUser username="guest" 
password="password" group="guests"/>
+                                       groups="users"/>
+                               <authenticationUser username="guest" 
password="password" groups="guests"/>
                        </users>
                </simpleAuthenticationPlugin>
 


Reply via email to