commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ggreg...@apache.org
Subject svn commit: r1364490 - in /commons/proper/vfs/trunk: core/src/main/java/org/apache/commons/vfs2/cache/SoftRefFilesCache.java src/changes/changes.xml
Date Mon, 23 Jul 2012 04:36:18 GMT
Author: ggregory
Date: Mon Jul 23 04:36:17 2012
New Revision: 1364490

URL: http://svn.apache.org/viewvc?rev=1364490&view=rev
Log:
[VFS-430] The SoftRefFilesCache class logs clear text password.

Modified:
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/SoftRefFilesCache.java
    commons/proper/vfs/trunk/src/changes/changes.xml

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/SoftRefFilesCache.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/SoftRefFilesCache.java?rev=1364490&r1=1364489&r2=1364490&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/SoftRefFilesCache.java
(original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/SoftRefFilesCache.java
Mon Jul 23 04:36:17 2012
@@ -161,7 +161,7 @@ public class SoftRefFilesCache extends A
     {
         if (log.isDebugEnabled())
         {
-            log.debug("putFile: " + file.getName());
+            log.debug("putFile: " + this.getSafeName(file));
         }
 
         Map<FileName, Reference<FileObject>> files = getOrCreateFilesystemCache(file.getFileSystem());
@@ -185,13 +185,22 @@ public class SoftRefFilesCache extends A
         }
     }
 
+    private String getSafeName(final FileName file)
+    {
+        return file.getFriendlyURI();
+    }
+
+    private String getSafeName(final FileObject file)
+    {
+        return this.getSafeName(file.getName());
+    }
 
     @Override
     public boolean putFileIfAbsent(final FileObject file)
     {
         if (log.isDebugEnabled())
         {
-            log.debug("putFile: " + file.getName());
+            log.debug("putFile: " + this.getSafeName(file));
         }
 
         Map<FileName, Reference<FileObject>> files = getOrCreateFilesystemCache(file.getFileSystem());
@@ -341,7 +350,7 @@ public class SoftRefFilesCache extends A
     {
         if (log.isDebugEnabled())
         {
-            log.debug("removeFile: " + key.getFileName());
+            log.debug("removeFile: " + this.getSafeName(key.getFileName()));
         }
 
         Map<?, ?> files = getOrCreateFilesystemCache(key.getFileSystem());

Modified: commons/proper/vfs/trunk/src/changes/changes.xml
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/src/changes/changes.xml?rev=1364490&r1=1364489&r2=1364490&view=diff
==============================================================================
--- commons/proper/vfs/trunk/src/changes/changes.xml (original)
+++ commons/proper/vfs/trunk/src/changes/changes.xml Mon Jul 23 04:36:17 2012
@@ -23,6 +23,9 @@
 
   <body>
     <release version="2.1" date="TBD" description="New features and bug fix release.">
+      <action issue="VFS-430" dev="ggregory" type="add" due-to="antonin.stefanutti">
+        The SoftRefFilesCache class logs clear text password.
+      </action>
       <action issue="VFS-432" dev="ggregory" type="add" due-to="ggregory">
         [HTTP][WebDAV] Allow HTTP follow redirect.
       </action>



Mime
View raw message