accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From e..@apache.org
Subject svn commit: r1196722 - /incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/Accumulo.java
Date Wed, 02 Nov 2011 18:05:10 GMT
Author: ecn
Date: Wed Nov  2 18:05:10 2011
New Revision: 1196722

URL: http://svn.apache.org/viewvc?rev=1196722&view=rev
Log:
ACCUMULO-114: don't print the system password in all the logs at start-up.

Modified:
    incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/Accumulo.java

Modified: incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/Accumulo.java
URL: http://svn.apache.org/viewvc/incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/Accumulo.java?rev=1196722&r1=1196721&r2=1196722&view=diff
==============================================================================
--- incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/Accumulo.java
(original)
+++ incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/Accumulo.java
Wed Nov  2 18:05:10 2011
@@ -121,8 +121,12 @@ public class Accumulo {
     for (Entry<String,String> entry : ServerConfiguration.getSystemConfiguration())
       sortedProps.put(entry.getKey(), entry.getValue());
     
-    for (Entry<String,String> entry : sortedProps.entrySet())
-      log.info(entry.getKey() + " = " + entry.getValue());
+    for (Entry<String,String> entry : sortedProps.entrySet()) {
+      if (entry.getKey().toLowerCase().contains("password"))
+        log.info(entry.getKey() + " = <hidden>");
+      else
+        log.info(entry.getKey() + " = " + entry.getValue());
+    }
   }
   
   public static InetAddress getLocalAddress(String[] args) throws UnknownHostException {



Mime
View raw message