Author: vsiveton
Date: Mon Nov 29 11:36:59 2010
New Revision: 1040071

URL: http://svn.apache.org/viewvc?rev=1040071&view=rev
Log:
MPIR-180: Repositories which require authentication get blacklisted

o refactor getInputStream to try to get auth from settings.xml
o take care of SSL repo
o added test case

Added:
    
maven/plugins/trunk/maven-project-info-reports-plugin/src/test/java/org/apache/maven/report/projectinfo/ProjectInfoReportUtilsTest.java
   (with props)
    
maven/plugins/trunk/maven-project-info-reports-plugin/src/test/resources/realm.properties
   (with props)
Modified:
    maven/plugins/trunk/maven-project-info-reports-plugin/pom.xml
    
maven/plugins/trunk/maven-project-info-reports-plugin/src/main/java/org/apache/maven/report/projectinfo/ProjectInfoReportUtils.java

Modified: maven/plugins/trunk/maven-project-info-reports-plugin/pom.xml
URL: 
http://svn.apache.org/viewvc/maven/plugins/trunk/maven-project-info-reports-plugin/pom.xml?rev=1040071&r1=1040070&r2=1040071&view=diff
==============================================================================
--- maven/plugins/trunk/maven-project-info-reports-plugin/pom.xml (original)
+++ maven/plugins/trunk/maven-project-info-reports-plugin/pom.xml Mon Nov 29 
11:36:59 2010
@@ -346,6 +346,12 @@ under the License.
       <version>1.4</version>
       <scope>test</scope>
     </dependency>
+    <dependency>
+      <groupId>org.mortbay.jetty</groupId>
+      <artifactId>jetty</artifactId>
+      <version>6.1.5</version>
+      <scope>test</scope>
+    </dependency>
   </dependencies>
 
   <build>
@@ -359,8 +365,68 @@ under the License.
             <target>1.5</target>
           </configuration>
         </plugin>
+        <plugin>
+          <groupId>org.apache.maven.plugins</groupId>
+          <artifactId>maven-jarsigner-plugin</artifactId>
+          <version>1.2</version>
+          <configuration>
+            <keystore>${basedir}/target/jetty.jks</keystore>
+            <keypass>apache</keypass>
+            <storepass>apache</storepass>
+            <alias>apache</alias>
+          </configuration>
+        </plugin>
+        <plugin>
+          <groupId>org.codehaus.mojo</groupId>
+          <artifactId>keytool-maven-plugin</artifactId>
+          <version>1.0</version>
+          <configuration>
+            <keystore>${basedir}/target/jetty.jks</keystore>
+            <dname>cn=jetty, ou=jetty, L=Unknown, ST=Unknown, o=Apache, 
c=Unknown</dname>
+            <keypass>apache</keypass>
+            <storepass>apache</storepass>
+            <alias>apache</alias>
+            <validity>365</validity>
+            <keyalg>RSA</keyalg>
+          </configuration>
+        </plugin>
       </plugins>
     </pluginManagement>
+    <plugins>
+      <!-- To use jetty ssl in tests -->
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-jarsigner-plugin</artifactId>
+        <executions>
+          <execution>
+            <id>sign</id>
+            <goals>
+              <goal>sign</goal>
+            </goals>
+          </execution>
+          <execution>
+            <id>verify</id>
+            <goals>
+              <goal>verify</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+      <plugin>
+        <groupId>org.codehaus.mojo</groupId>
+        <artifactId>keytool-maven-plugin</artifactId>
+        <executions>
+          <execution>
+            <id>init</id>
+            <phase>initialize</phase>
+            <goals>
+              <goal>clean</goal>
+              <goal>genkey</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
   </build>
 
   <reporting>

Modified: 
maven/plugins/trunk/maven-project-info-reports-plugin/src/main/java/org/apache/maven/report/projectinfo/ProjectInfoReportUtils.java
URL: 
http://svn.apache.org/viewvc/maven/plugins/trunk/maven-project-info-reports-plugin/src/main/java/org/apache/maven/report/projectinfo/ProjectInfoReportUtils.java?rev=1040071&r1=1040070&r2=1040071&view=diff
==============================================================================
--- 
maven/plugins/trunk/maven-project-info-reports-plugin/src/main/java/org/apache/maven/report/projectinfo/ProjectInfoReportUtils.java
 (original)
+++ 
maven/plugins/trunk/maven-project-info-reports-plugin/src/main/java/org/apache/maven/report/projectinfo/ProjectInfoReportUtils.java
 Mon Nov 29 11:36:59 2010
@@ -25,10 +25,22 @@ import java.net.Authenticator;
 import java.net.PasswordAuthentication;
 import java.net.URL;
 import java.net.URLConnection;
+import java.security.KeyManagementException;
+import java.security.NoSuchAlgorithmException;
+import java.security.SecureRandom;
+import java.security.cert.X509Certificate;
 import java.util.Collections;
 import java.util.List;
 import java.util.Properties;
 
+import javax.net.ssl.HostnameVerifier;
+import javax.net.ssl.HttpsURLConnection;
+import javax.net.ssl.SSLContext;
+import javax.net.ssl.SSLSession;
+import javax.net.ssl.SSLSocketFactory;
+import javax.net.ssl.TrustManager;
+import javax.net.ssl.X509TrustManager;
+
 import org.apache.commons.validator.UrlValidator;
 import org.apache.maven.artifact.Artifact;
 import org.apache.maven.artifact.ArtifactUtils;
@@ -37,8 +49,11 @@ import org.apache.maven.artifact.reposit
 import org.apache.maven.project.MavenProject;
 import org.apache.maven.project.MavenProjectBuilder;
 import org.apache.maven.project.ProjectBuildingException;
+import org.apache.maven.reporting.AbstractMavenReportRenderer;
 import org.apache.maven.settings.Proxy;
+import org.apache.maven.settings.Server;
 import org.apache.maven.settings.Settings;
+import org.codehaus.plexus.util.Base64;
 import org.codehaus.plexus.util.IOUtil;
 import org.codehaus.plexus.util.StringUtils;
 
@@ -83,50 +98,82 @@ public class ProjectInfoReportUtils
     public static String getInputStream( URL url, Settings settings, String 
encoding )
         throws IOException
     {
+        return getInputStream( url, null, settings, encoding );
+    }
+
+    /**
+     * Get the input stream from an URL.
+     *
+     * @param url not null
+     * @param project could be null
+     * @param settings not null to handle proxy settings
+     * @param encoding the wanted encoding for the inputstream. If empty, 
encoding will be "ISO-8859-1".
+     * @return the inputstream found depending the wanted encoding.
+     * @throws IOException if any
+     * @since 2.3
+     */
+    public static String getInputStream( URL url, MavenProject project, 
Settings settings, String encoding )
+        throws IOException
+    {
         String scheme = url.getProtocol();
-        if ( !"file".equals( scheme ) )
+
+        if ( StringUtils.isEmpty( encoding ) )
+        {
+            encoding = "ISO-8859-1";
+        }
+
+        if ( "file".equals( scheme ) )
         {
-            Proxy proxy = settings.getActiveProxy();
-            if ( proxy != null )
+            InputStream in = null;
+            try
             {
-                if ( "http".equals( scheme ) || "https".equals( scheme ) )
-                {
-                    scheme = "http.";
-                }
-                else if ( "ftp".equals( scheme ) )
-                {
-                    scheme = "ftp.";
-                }
-                else
+                URLConnection conn = url.openConnection();
+                in = conn.getInputStream();
+
+                return IOUtil.toString( in, encoding );
+            }
+            finally
+            {
+                IOUtil.close( in );
+            }
+        }
+
+        Proxy proxy = settings.getActiveProxy();
+        if ( proxy != null )
+        {
+            if ( "http".equals( scheme ) || "https".equals( scheme ) || 
"ftp".equals( scheme ) )
+            {
+                scheme += ".";
+            }
+            else
+            {
+                scheme = "";
+            }
+
+            String host = proxy.getHost();
+            if ( !StringUtils.isEmpty( host ) )
+            {
+                Properties p = System.getProperties();
+                p.setProperty( scheme + "proxySet", "true" );
+                p.setProperty( scheme + "proxyHost", host );
+                p.setProperty( scheme + "proxyPort", String.valueOf( 
proxy.getPort() ) );
+                if ( !StringUtils.isEmpty( proxy.getNonProxyHosts() ) )
                 {
-                    scheme = "";
+                    p.setProperty( scheme + "nonProxyHosts", 
proxy.getNonProxyHosts() );
                 }
 
-                String host = proxy.getHost();
-                if ( !StringUtils.isEmpty( host ) )
+                final String userName = proxy.getUsername();
+                if ( !StringUtils.isEmpty( userName ) )
                 {
-                    Properties p = System.getProperties();
-                    p.setProperty( scheme + "proxySet", "true" );
-                    p.setProperty( scheme + "proxyHost", host );
-                    p.setProperty( scheme + "proxyPort", String.valueOf( 
proxy.getPort() ) );
-                    if ( !StringUtils.isEmpty( proxy.getNonProxyHosts() ) )
+                    final String pwd = StringUtils.isEmpty( 
proxy.getPassword() ) ? "" : proxy.getPassword();
+                    Authenticator.setDefault( new Authenticator()
                     {
-                        p.setProperty( scheme + "nonProxyHosts", 
proxy.getNonProxyHosts() );
-                    }
-
-                    final String userName = proxy.getUsername();
-                    if ( !StringUtils.isEmpty( userName ) )
-                    {
-                        final String pwd = StringUtils.isEmpty( 
proxy.getPassword() ) ? "" : proxy.getPassword();
-                        Authenticator.setDefault( new Authenticator()
+                        /** {...@inheritdoc} */
+                        protected PasswordAuthentication 
getPasswordAuthentication()
                         {
-                            /** {...@inheritdoc} */
-                            protected PasswordAuthentication 
getPasswordAuthentication()
-                            {
-                                return new PasswordAuthentication( userName, 
pwd.toCharArray() );
-                            }
-                        } );
-                    }
+                            return new PasswordAuthentication( userName, 
pwd.toCharArray() );
+                        }
+                    } );
                 }
             }
         }
@@ -134,15 +181,9 @@ public class ProjectInfoReportUtils
         InputStream in = null;
         try
         {
-            URLConnection conn = url.openConnection();
-            conn.setConnectTimeout( TIMEOUT );
-            conn.setReadTimeout( TIMEOUT );
+            URLConnection conn = getURLConnection( url, project, settings );
             in = conn.getInputStream();
 
-            if ( encoding == null )
-            {
-                return IOUtil.toString( in, "ISO-8859-1" );
-            }
             return IOUtil.toString( in, encoding );
         }
         finally
@@ -171,8 +212,9 @@ public class ProjectInfoReportUtils
         Artifact copyArtifact = ArtifactUtils.copyArtifact( artifact );
         if ( !"pom".equals( copyArtifact.getType() ) )
         {
-            copyArtifact = factory.createProjectArtifact( 
copyArtifact.getGroupId(), copyArtifact.getArtifactId(),
-                                                             
copyArtifact.getVersion(), copyArtifact.getScope() );
+            copyArtifact =
+                factory.createProjectArtifact( copyArtifact.getGroupId(), 
copyArtifact.getArtifactId(),
+                                               copyArtifact.getVersion(), 
copyArtifact.getScope() );
         }
         try
         {
@@ -223,5 +265,100 @@ public class ProjectInfoReportUtils
 
         return URL_VALIDATOR.isValid( url );
     }
-}
 
+    /**
+     * @param url not null
+     * @param project not null
+     * @param settings not null
+     * @return the url connection with auth if required. Don't check the 
certificate if SSL scheme.
+     * @throws IOException if any
+     */
+    private static URLConnection getURLConnection( URL url, MavenProject 
project, Settings settings )
+        throws IOException
+    {
+        URLConnection conn = url.openConnection();
+        conn.setConnectTimeout( TIMEOUT );
+        conn.setReadTimeout( TIMEOUT );
+
+        // conn authorization
+        if ( settings.getServers() != null
+            && !settings.getServers().isEmpty()
+            && project != null
+            && project.getDistributionManagement() != null
+            && ( project.getDistributionManagement().getRepository() != null 
|| project.getDistributionManagement().getSnapshotRepository() != null )
+            && ( StringUtils.isNotEmpty( 
project.getDistributionManagement().getRepository().getUrl() ) || 
StringUtils.isNotEmpty( 
project.getDistributionManagement().getSnapshotRepository().getUrl() ) ) )
+        {
+            Server server = null;
+            if ( url.toString().contains( 
project.getDistributionManagement().getRepository().getUrl() ) )
+            {
+                server = settings.getServer( 
project.getDistributionManagement().getRepository().getId() );
+            }
+            if ( server == null
+                && url.toString().contains( 
project.getDistributionManagement().getSnapshotRepository().getUrl() ) )
+            {
+                server = settings.getServer( 
project.getDistributionManagement().getRepository().getId() );
+            }
+
+            if ( server != null && StringUtils.isNotEmpty( 
server.getUsername() )
+                && StringUtils.isNotEmpty( server.getPassword() ) )
+            {
+                String up = server.getUsername().trim() + ":" + 
server.getPassword().trim();
+                String upEncoded = new String( Base64.encodeBase64Chunked( 
up.getBytes() ) ).trim();
+
+                conn.setRequestProperty( "Authorization", "Basic " + upEncoded 
);
+            }
+        }
+
+        if ( HttpsURLConnection.class.isAssignableFrom( conn.getClass() ) )
+        {
+            HostnameVerifier hostnameverifier = new HostnameVerifier()
+            {
+                /** {...@inheritdoc} */
+                public boolean verify( String urlHostName, SSLSession session )
+                {
+                    return true;
+                }
+            };
+            ( (HttpsURLConnection) conn ).setHostnameVerifier( 
hostnameverifier );
+
+            TrustManager[] trustAllCerts = new TrustManager[] { new 
X509TrustManager()
+            {
+                /** {...@inheritdoc} */
+                public void checkClientTrusted( final X509Certificate[] chain, 
final String authType )
+                {
+                }
+
+                /** {...@inheritdoc} */
+                public void checkServerTrusted( final X509Certificate[] chain, 
final String authType )
+                {
+                }
+
+                /** {...@inheritdoc} */
+                public X509Certificate[] getAcceptedIssuers()
+                {
+                    return null;
+                }
+            } };
+
+            try
+            {
+                SSLContext sslContext = SSLContext.getInstance( "SSL" );
+                sslContext.init( null, trustAllCerts, new SecureRandom() );
+
+                SSLSocketFactory sslSocketFactory = 
sslContext.getSocketFactory();
+
+                ( (HttpsURLConnection) conn ).setSSLSocketFactory( 
sslSocketFactory );
+            }
+            catch ( NoSuchAlgorithmException e1 )
+            {
+                // ignore
+            }
+            catch ( KeyManagementException e )
+            {
+                // ignore
+            }
+        }
+
+        return conn;
+    }
+}

Added: 
maven/plugins/trunk/maven-project-info-reports-plugin/src/test/java/org/apache/maven/report/projectinfo/ProjectInfoReportUtilsTest.java
URL: 
http://svn.apache.org/viewvc/maven/plugins/trunk/maven-project-info-reports-plugin/src/test/java/org/apache/maven/report/projectinfo/ProjectInfoReportUtilsTest.java?rev=1040071&view=auto
==============================================================================
--- 
maven/plugins/trunk/maven-project-info-reports-plugin/src/test/java/org/apache/maven/report/projectinfo/ProjectInfoReportUtilsTest.java
 (added)
+++ 
maven/plugins/trunk/maven-project-info-reports-plugin/src/test/java/org/apache/maven/report/projectinfo/ProjectInfoReportUtilsTest.java
 Mon Nov 29 11:36:59 2010
@@ -0,0 +1,268 @@
+package org.apache.maven.report.projectinfo;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import java.io.File;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.List;
+
+import junit.framework.Assert;
+
+import org.apache.maven.model.DeploymentRepository;
+import org.apache.maven.model.DistributionManagement;
+import org.apache.maven.plugin.testing.AbstractMojoTestCase;
+import org.apache.maven.plugin.testing.stubs.MavenProjectStub;
+import org.apache.maven.project.MavenProject;
+import org.apache.maven.report.projectinfo.stubs.SettingsStub;
+import org.apache.maven.settings.Settings;
+import org.mortbay.jetty.Connector;
+import org.mortbay.jetty.Handler;
+import org.mortbay.jetty.Server;
+import org.mortbay.jetty.handler.DefaultHandler;
+import org.mortbay.jetty.nio.SelectChannelConnector;
+import org.mortbay.jetty.security.Constraint;
+import org.mortbay.jetty.security.ConstraintMapping;
+import org.mortbay.jetty.security.HashUserRealm;
+import org.mortbay.jetty.security.SecurityHandler;
+import org.mortbay.jetty.security.SslSocketConnector;
+import org.mortbay.jetty.webapp.WebAppContext;
+
+/**
+ * @author <a href="mailto:[email protected]";>Vincent Siveton</a>
+ * @version $Id:$
+ */
+public class ProjectInfoReportUtilsTest
+    extends AbstractMojoTestCase
+{
+    private static final int MAX_IDLE_TIME = 30000;
+
+    private MavenProject projectStub;
+
+    private Settings settingsStub;
+
+    private MavenProject projectStubSec;
+
+    private Server jettyServer;
+
+    protected void setUp()
+        throws Exception
+    {
+        super.setUp();
+
+        final List<org.apache.maven.settings.Server> servers = new 
ArrayList<org.apache.maven.settings.Server>();
+        org.apache.maven.settings.Server server = new 
org.apache.maven.settings.Server();
+        server.setId( "localhost" );
+        server.setUsername( "admin" );
+        server.setPassword( "admin" );
+        servers.add( server );
+        settingsStub = new SettingsStub()
+        {
+            private static final long serialVersionUID = 1L;
+
+            @Override
+            public org.apache.maven.settings.Server getServer( String serverId 
)
+            {
+                for ( org.apache.maven.settings.Server server : getServers() )
+                {
+                    if ( server.getId().equals( serverId ) )
+                    {
+                        return server;
+                    }
+                }
+                return null;
+            }
+
+            @Override
+            public List<org.apache.maven.settings.Server> getServers()
+            {
+                return servers;
+            }
+        };
+
+        final DistributionManagement distributionManagement = new 
DistributionManagement();
+        DeploymentRepository repository = new DeploymentRepository();
+        repository.setId( "localhost" );
+        repository.setUrl( "http://localhost:8080"; );
+        distributionManagement.setRepository( repository );
+        distributionManagement.setSnapshotRepository( repository );
+        projectStub = new MavenProjectStub()
+        {
+            @Override
+            public DistributionManagement getDistributionManagement()
+            {
+                return distributionManagement;
+            }
+        };
+
+        final DistributionManagement distributionManagementSec = new 
DistributionManagement();
+        DeploymentRepository repositorySec = new DeploymentRepository();
+        repositorySec.setId( "localhost" );
+        repositorySec.setUrl( "https://localhost:8443"; );
+        distributionManagementSec.setRepository( repositorySec );
+        distributionManagementSec.setSnapshotRepository( repositorySec );
+        projectStubSec = new MavenProjectStub()
+        {
+            @Override
+            public DistributionManagement getDistributionManagement()
+            {
+                return distributionManagementSec;
+            }
+        };
+    }
+
+    protected void tearDown()
+        throws Exception
+    {
+        super.tearDown();
+    }
+
+    public void testGetInputStreamURL()
+        throws Exception
+    {
+        // file
+        URL url = new File( getBasedir(), 
"/target/classes/project-info-report.properties" ).toURI().toURL();
+
+        String content = ProjectInfoReportUtils.getInputStream( url, 
projectStub, settingsStub, null );
+        Assert.assertNotNull( content );
+        Assert.assertTrue( content.contains( "Licensed to the Apache Software 
Foundation" ) );
+
+        // http + no auth
+        startJetty( false, false );
+
+        url = new URL( "http://localhost:8080/project-info-report.properties"; 
);
+
+        content = ProjectInfoReportUtils.getInputStream( url, projectStub, 
settingsStub, null );
+        Assert.assertNotNull( content );
+        Assert.assertTrue( content.contains( "Licensed to the Apache Software 
Foundation" ) );
+
+        stopJetty();
+
+        // http + auth
+        startJetty( false, true );
+
+        url = new URL( "http://localhost:8080/project-info-report.properties"; 
);
+
+        content = ProjectInfoReportUtils.getInputStream( url, projectStub, 
settingsStub, null );
+        Assert.assertNotNull( content );
+        Assert.assertTrue( content.contains( "Licensed to the Apache Software 
Foundation" ) );
+
+        stopJetty();
+
+        // https + no auth
+        startJetty( true, false );
+
+        url = new URL( "https://localhost:8443/project-info-report.properties"; 
);
+
+        content = ProjectInfoReportUtils.getInputStream( url, projectStub, 
settingsStub, null );
+        Assert.assertNotNull( content );
+        Assert.assertTrue( content.contains( "Licensed to the Apache Software 
Foundation" ) );
+
+        stopJetty();
+
+        // https + auth
+        startJetty( true, true );
+
+        url = new URL( "https://localhost:8443/project-info-report.properties"; 
);
+
+        content = ProjectInfoReportUtils.getInputStream( url, projectStubSec, 
settingsStub, null );
+        Assert.assertNotNull( content );
+        Assert.assertTrue( content.contains( "Licensed to the Apache Software 
Foundation" ) );
+
+        stopJetty();
+
+        // TODO need to test with a proxy
+    }
+
+    private void startJetty( boolean isSSL, boolean withAuth )
+        throws Exception
+    {
+        jettyServer = new Server();
+        jettyServer.setStopAtShutdown( true );
+
+        Connector connector = ( isSSL ? getSSLConnector() : 
getDefaultConnector() );
+        jettyServer.setConnectors( new Connector[] { connector } );
+
+        WebAppContext webapp = new WebAppContext();
+        webapp.setContextPath( "/" );
+        webapp.setResourceBase( getBasedir() + "/target/classes/" );
+
+        webapp.setServer( jettyServer );
+
+        if ( withAuth )
+        {
+            Constraint constraint = new Constraint();
+            constraint.setName( Constraint.__BASIC_AUTH );
+            constraint.setRoles( new String[] { "user", "admin" } );
+            constraint.setAuthenticate( true );
+
+            ConstraintMapping cm = new ConstraintMapping();
+            cm.setConstraint( constraint );
+            cm.setPathSpec( "/*" );
+
+            SecurityHandler sh = new SecurityHandler();
+            sh.setUserRealm( new HashUserRealm( "MyRealm", getBasedir() + 
"/src/test/resources/realm.properties" ) );
+            sh.setConstraintMappings( new ConstraintMapping[] { cm } );
+
+            webapp.addHandler( sh );
+        }
+
+        DefaultHandler defaultHandler = new DefaultHandler();
+        defaultHandler.setServer( jettyServer );
+
+        Handler[] handlers = new Handler[2];
+        handlers[0] = webapp;
+        handlers[1] = defaultHandler;
+        jettyServer.setHandlers( handlers );
+
+        jettyServer.start();
+    }
+
+    private void stopJetty()
+        throws Exception
+    {
+        if ( jettyServer != null )
+        {
+            jettyServer.stop();
+
+            jettyServer = null;
+        }
+    }
+
+    private Connector getDefaultConnector()
+    {
+        Connector connector = new SelectChannelConnector();
+        connector.setPort( 8080 );
+        connector.setMaxIdleTime( MAX_IDLE_TIME );
+        return connector;
+    }
+
+    private Connector getSSLConnector()
+    {
+        SslSocketConnector connector = new SslSocketConnector();
+        connector.setPort( 8443 );
+        connector.setKeystore( getBasedir() + "/target/jetty.jks" );
+        connector.setPassword( "apache" );
+        connector.setKeyPassword( "apache" );
+        connector.setTruststore( getBasedir() + "/target/jetty.jks" );
+        connector.setTrustPassword( "apache" );
+        return connector;
+    }
+}

Propchange: 
maven/plugins/trunk/maven-project-info-reports-plugin/src/test/java/org/apache/maven/report/projectinfo/ProjectInfoReportUtilsTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: 
maven/plugins/trunk/maven-project-info-reports-plugin/src/test/java/org/apache/maven/report/projectinfo/ProjectInfoReportUtilsTest.java
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Propchange: 
maven/plugins/trunk/maven-project-info-reports-plugin/src/test/java/org/apache/maven/report/projectinfo/ProjectInfoReportUtilsTest.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: 
maven/plugins/trunk/maven-project-info-reports-plugin/src/test/resources/realm.properties
URL: 
http://svn.apache.org/viewvc/maven/plugins/trunk/maven-project-info-reports-plugin/src/test/resources/realm.properties?rev=1040071&view=auto
==============================================================================
--- 
maven/plugins/trunk/maven-project-info-reports-plugin/src/test/resources/realm.properties
 (added)
+++ 
maven/plugins/trunk/maven-project-info-reports-plugin/src/test/resources/realm.properties
 Mon Nov 29 11:36:59 2010
@@ -0,0 +1,19 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#  http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+admin: admin,admin
+user: user,read-only

Propchange: 
maven/plugins/trunk/maven-project-info-reports-plugin/src/test/resources/realm.properties
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: 
maven/plugins/trunk/maven-project-info-reports-plugin/src/test/resources/realm.properties
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Propchange: 
maven/plugins/trunk/maven-project-info-reports-plugin/src/test/resources/realm.properties
------------------------------------------------------------------------------
    svn:mime-type = text/plain


Reply via email to