continuum-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Emmanuel Venisse <emmanuel.veni...@gmail.com>
Subject Re: svn commit: r767816 - /continuum/branches/continuum-1.3.x/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddMavenTwoProjectAction.java
Date Mon, 27 Apr 2009 09:31:50 GMT
ping

On Thu, Apr 23, 2009 at 10:05 AM, Emmanuel Venisse <
emmanuel.venisse@gmail.com> wrote:

> I'd prefer to see http://username:****@....So the user will be sure the
> user/password is used.
>
> We already replaced passwords by "*****" in logs in other parts in
> Continuum
>
> Emmanuel
>
>
> On Thu, Apr 23, 2009 at 8:31 AM, <jzurbano@apache.org> wrote:
>
>> Author: jzurbano
>> Date: Thu Apr 23 06:31:43 2009
>> New Revision: 767816
>>
>> URL: http://svn.apache.org/viewvc?rev=767816&view=rev
>> Log:
>> [CONTINUUM-2200] Logs should not display scm credentials when adding
>> projects
>>
>> Modified:
>>
>>  continuum/branches/continuum-1.3.x/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddMavenTwoProjectAction.java
>>
>> Modified:
>> continuum/branches/continuum-1.3.x/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddMavenTwoProjectAction.java
>> URL:
>> http://svn.apache.org/viewvc/continuum/branches/continuum-1.3.x/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddMavenTwoProjectAction.java?rev=767816&r1=767815&r2=767816&view=diff
>>
>> ==============================================================================
>> ---
>> continuum/branches/continuum-1.3.x/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddMavenTwoProjectAction.java
>> (original)
>> +++
>> continuum/branches/continuum-1.3.x/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddMavenTwoProjectAction.java
>> Thu Apr 23 06:31:43 2009
>> @@ -112,7 +112,18 @@
>>
>> this.getBuildDefinitionTemplateId() );
>>         }
>>
>> -        AuditLog event = new AuditLog( pomUrl,
>> AuditLogConstants.ADD_M2_PROJECT );
>> +        String projectUrl = pomUrl;
>> +
>> +        if ( projectUrl.indexOf( "@" ) > 0 )
>> +        {
>> +            // remove scm credentials from the url
>> +            StringBuilder urlBuilder = new StringBuilder();
>> +            urlBuilder.append( projectUrl.substring( 0,
>> projectUrl.indexOf( "://" ) + 3 ) );
>> +            urlBuilder.append( projectUrl.substring( projectUrl.indexOf(
>> "@" ) + 1 ) );
>> +            projectUrl = urlBuilder.toString();
>> +        }
>> +
>> +        AuditLog event = new AuditLog( projectUrl,
>> AuditLogConstants.ADD_M2_PROJECT );
>>         event.setCategory( AuditLogConstants.PROJECT );
>>         event.setCurrentUser( getPrincipal() );
>>         event.log();
>>
>>
>>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message