You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@nutch.apache.org by "Piotr Kosiorowski (JIRA)" <ji...@apache.org> on 2006/03/25 12:40:24 UTC

[jira] Closed: (NUTCH-239) I changed httpclient to use javax.net.ssl instead of com.sun.net.ssl

     [ http://issues.apache.org/jira/browse/NUTCH-239?page=all ]
     
Piotr Kosiorowski closed NUTCH-239:
-----------------------------------

    Fix Version: 0.7.2-dev
     Resolution: Fixed
      Assign To: Piotr Kosiorowski

Applied with JavaDoc changes. Thanks.

> I changed httpclient to use javax.net.ssl instead of com.sun.net.ssl
> --------------------------------------------------------------------
>
>          Key: NUTCH-239
>          URL: http://issues.apache.org/jira/browse/NUTCH-239
>      Project: Nutch
>         Type: Improvement
>   Components: fetcher
>     Versions: 0.7.2-dev
>  Environment: RedHat Enterprise Linux
>     Reporter: Jake Vanderdray
>     Assignee: Piotr Kosiorowski
>     Priority: Trivial
>      Fix For: 0.7.2-dev

>
> I made the following changes in order to get the dependency on com.sun.ssl out of the 0.7 branch.  The same changes have already been applied to the 0.8 branch (Revision 379215) thanks to ab.  There is still a dependency on using the Sun JRE.  In order to get it to work with the IBM JRE I had to change SunX509 to IbmX509, but I didn't include that change in this patch.  
> Thanks,
> Jake.
> Index: DummySSLProtocolSocketFactory.java
> ===================================================================
> --- DummySSLProtocolSocketFactory.java  (revision 388638)
> +++ DummySSLProtocolSocketFactory.java  (working copy)
> @@ -22,8 +22,8 @@
>  import org.apache.commons.logging.Log;
>  import org.apache.commons.logging.LogFactory;
>  
> -import com.sun.net.ssl.SSLContext;
> -import com.sun.net.ssl.TrustManager;
> +import javax.net.ssl.SSLContext;
> +import javax.net.ssl.TrustManager;
>  
>  public class DummySSLProtocolSocketFactory implements ProtocolSocketFactory {
>  
> Index: DummyX509TrustManager.java
> ===================================================================
> --- DummyX509TrustManager.java  (revision 388638)
> +++ DummyX509TrustManager.java  (working copy)
> @@ -10,9 +10,9 @@
>  import java.security.cert.CertificateException;
>  import java.security.cert.X509Certificate;
>  
> -import com.sun.net.ssl.TrustManagerFactory;
> -import com.sun.net.ssl.TrustManager;
> -import com.sun.net.ssl.X509TrustManager;
> +import javax.net.ssl.TrustManagerFactory;
> +import javax.net.ssl.TrustManager;
> +import javax.net.ssl.X509TrustManager;
>  import org.apache.commons.logging.Log; 
>  import org.apache.commons.logging.LogFactory;
>  
> @@ -57,4 +57,12 @@
>      public X509Certificate[] getAcceptedIssuers() {
>          return this.standardTrustManager.getAcceptedIssuers();
>      }
> +   
> +    public void checkClientTrusted(X509Certificate[] arg0, String arg1) throws CertificateException {
> +       // do nothing
> +    }
> +
> +    public void checkServerTrusted(X509Certificate[] arg0, String arg1) throws CertificateException {
> +       // do nothing
> +    }
>  }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira