Skip to content

Commit

Permalink
Adding org.eclipse.core.pki capability
Browse files Browse the repository at this point in the history
  • Loading branch information
JavaJoeS committed Apr 30, 2024
1 parent c9f0582 commit 2ba449b
Showing 1 changed file with 13 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,11 @@

import java.io.*;
import java.net.*;
import java.security.NoSuchAlgorithmException;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.TimeUnit;
import javax.net.ssl.SSLContext;
import org.eclipse.core.runtime.*;
import org.eclipse.ecf.core.identity.IDCreateException;
import org.eclipse.ecf.core.security.ConnectContextFactory;
Expand Down Expand Up @@ -95,7 +97,18 @@ public RepositoryTransport(IProvisioningAgent agent) {
@Override
public IStatus download(URI toDownload, OutputStream target, IProgressMonitor monitor) {
boolean promptUser = false;

boolean useJREHttp = false;
try {
// DELMARVA - is org.eclipse.core.pki installed and configured
if (SSLContext.getDefault().getProvider().getName().contains("PKCS")) { //$NON-NLS-1$
useJREHttp = true;
Activator.getDefault().useJREHttpClient();
}
} catch (NoSuchAlgorithmException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
AuthenticationInfo loginDetails = null;
URI secureToDownload;
try {
Expand Down

0 comments on commit 2ba449b

Please sign in to comment.