Author: brett
Date: Mon Mar 22 05:32:14 2010
New Revision: 925958

URL: http://svn.apache.org/viewvc?rev=925958&view=rev
Log:
[MPH-57] Hide server passphrase for effective-settings
Submitted by: Marcel May

Modified:
     
maven/plugins/trunk/maven-help-plugin/src/main/java/org/apache/maven/plugins/help/EffectiveSettingsMojo.java

Modified: 
maven/plugins/trunk/maven-help-plugin/src/main/java/org/apache/maven/plugins/help/EffectiveSettingsMojo.java
URL: 
http://svn.apache.org/viewvc/maven/plugins/trunk/maven-help-plugin/src/main/java/org/apache/maven/plugins/help/EffectiveSettingsMojo.java?rev=925958&r1=925957&r2=925958&view=diff
==============================================================================
--- 
maven/plugins/trunk/maven-help-plugin/src/main/java/org/apache/maven/plugins/help/EffectiveSettingsMojo.java
 (original)
+++ 
maven/plugins/trunk/maven-help-plugin/src/main/java/org/apache/maven/plugins/help/EffectiveSettingsMojo.java
 Mon Mar 22 05:32:14 2010
@@ -156,11 +156,16 @@ public class EffectiveSettingsMojo
          for ( Iterator it = aSettings.getServers().iterator(); it.hasNext(); )
          {
              Server server = (Server) it.next();
-
+            // Password
              if ( StringUtils.isNotEmpty( server.getPassword() ) )
              {
                  server.setPassword( StringUtils.repeat( "*", 
server.getPassword().length() ) );
              }
+            // Passphrase
+            if ( StringUtils.isNotEmpty( server.getPassphrase() ) )
+            {
+                server.setPassphrase( StringUtils.repeat( "*", 
server.getPassphrase().length() ) );
+            }

While I see this, shouldn't we just use a fixed number of asterisk characters in order to not reveal the actual length of the password/passphrase?


Benjamin

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org

Reply via email to