accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From e..@apache.org
Subject svn commit: r1450405 - /accumulo/branches/1.5/test/src/main/java/org/apache/accumulo/test/randomwalk/security/WalkingSecurity.java
Date Tue, 26 Feb 2013 20:44:53 GMT
Author: ecn
Date: Tue Feb 26 20:44:53 2013
New Revision: 1450405

URL: http://svn.apache.org/r1450405
Log:
ACCUMULO-1114 a partial fix for user/table password handling

Modified:
    accumulo/branches/1.5/test/src/main/java/org/apache/accumulo/test/randomwalk/security/WalkingSecurity.java

Modified: accumulo/branches/1.5/test/src/main/java/org/apache/accumulo/test/randomwalk/security/WalkingSecurity.java
URL: http://svn.apache.org/viewvc/accumulo/branches/1.5/test/src/main/java/org/apache/accumulo/test/randomwalk/security/WalkingSecurity.java?rev=1450405&r1=1450404&r2=1450405&view=diff
==============================================================================
--- accumulo/branches/1.5/test/src/main/java/org/apache/accumulo/test/randomwalk/security/WalkingSecurity.java
(original)
+++ accumulo/branches/1.5/test/src/main/java/org/apache/accumulo/test/randomwalk/security/WalkingSecurity.java
Tue Feb 26 20:44:53 2013
@@ -280,7 +280,7 @@ public class WalkingSecurity extends Sec
   }
   
   public byte[] getUserPassword(String user) {
-    Object obj = state.get(getSysUserName() + userPass);
+    Object obj = state.get(user + userPass);
     if (obj instanceof PasswordToken) {
       return ((PasswordToken) obj).getPassword();
     }
@@ -296,7 +296,11 @@ public class WalkingSecurity extends Sec
   }
   
   public byte[] getTabPassword() {
-    return (byte[]) state.get(getTabUserName() + userPass);
+    Object obj = state.get(getTabUserName() + userPass);
+    if (obj instanceof PasswordToken) {
+      return ((PasswordToken) obj).getPassword();
+    }
+    return null;
   }
   
   public boolean userPassTransient(String user) {



Mime
View raw message