g-Eclipse
Release 1.0.0

eu.geclipse.core.security
Class Security

java.lang.Object
  extended by eu.geclipse.core.security.Security

public class Security
extends java.lang.Object

Base class of the g-Eclipse security framework.


Constructor Summary
Security()
           
 
Method Summary
static IPath getCertificateLocation()
          Get the location where the ICertificateManager singleton implementation stores its certificates.
static ICertificateManager getCertificateManager()
          Get the ICertificateManager singleton implementation.
static javax.net.ssl.SSLSocketFactory getSocketFactory()
          Get a singleton implementation of an SSLSocketFactory that hooks in the g-Eclipse trust management into the SSL/TLS framework.
static javax.net.ssl.X509TrustManager getTrustManager(javax.net.ssl.X509TrustManager slave)
          Get a X509TrustManager wrapping up the specified slave.
static void setCertificateLocation(IPath location)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Security

public Security()
Method Detail

getCertificateLocation

public static IPath getCertificateLocation()
Get the location where the ICertificateManager singleton implementation stores its certificates.

Returns:
The certificate path in the local file system.

getCertificateManager

public static ICertificateManager getCertificateManager()
Get the ICertificateManager singleton implementation.

Returns:
The ICertificateManager.

getTrustManager

public static javax.net.ssl.X509TrustManager getTrustManager(javax.net.ssl.X509TrustManager slave)
Get a X509TrustManager wrapping up the specified slave. The returned manager will use the ICertificateTrustVerifiers that are specified via the eu.geclipse.core.certificateTrustVerifier extension point to verify trust on certificates that are not yet known as trusted or untrusted.

Parameters:
slave - The slave manager that is used at the very first step to verify certificate trust.
Returns:
A trust manager wrapping up the specified slave.

getSocketFactory

public static final javax.net.ssl.SSLSocketFactory getSocketFactory()
                                                             throws java.security.NoSuchAlgorithmException,
                                                                    java.security.KeyManagementException,
                                                                    java.security.UnrecoverableKeyException,
                                                                    java.security.KeyStoreException,
                                                                    java.security.InvalidAlgorithmParameterException
Get a singleton implementation of an SSLSocketFactory that hooks in the g-Eclipse trust management into the SSL/TLS framework.

Returns:
A SSLSocketFactory singleton.
Throws:
java.security.NoSuchAlgorithmException
java.security.KeyManagementException
java.security.UnrecoverableKeyException
java.security.KeyStoreException
java.security.InvalidAlgorithmParameterException

setCertificateLocation

public static void setCertificateLocation(IPath location)

g-Eclipse
Release 1.0.0