Package org.globus.gsi.jsse

# Class SSLConfigurator

java.lang.Object
org.globus.gsi.jsse.SSLConfigurator

public class SSLConfigurator extends Object
This class is used to configure and create SSL socket factories. The factories can either be built by setting the credentialStore, crlStore, trustAnchorStore and policyStore directly, or it can use the java security SPI mechanism. This is the simplest way to configure the globus ssl support.

Since:
  1.0
Version:
  ${version}

## Constructor Summary

Constructors
Constructor
Description
`SSLConfigurator()`

## Method Summary

Modifier and Type
Method
Description
`SSLSocketFactory`
`createFactory()`
Create an SSLSocketFactory based on the configured stores.
`SSLServerSocketFactory`
`createServerFactory()`
Create an SSLServerSocketFactory based on the configured stores.
`KeyStore`
`getCredentialStore()`
`String`
`getCredentialStoreLocation()`
`String`
`getCredentialStorePassword()`
`String`
`getCredentialStoreType()`
`String`
`getCrlLocationPattern()`
`CertStore`
`getCrlStore()`
`String`
`getCrlStoreType()`
`Map<String,ProxyPolicyHandler>`
`getHandlers()`
`SigningPolicyStore`
`getPolicyStore()`
`String`
`getProtocol()`
`String`
`getProvider()`
`String`
`getSecureRandomAlgorithm()`
`SSLContext`
`getSSLContext()`
Create an SSLContext based on the configured stores.
`KeyStore`
`getTrustAnchorStore()`
`String`
`getTrustAnchorStoreLocation()`
`String`
`getTrustAnchorStorePassword()`
`String`
`getTrustAnchorStoreType()`
`boolean`
`isRejectLimitProxy()`
`void`
`setCredentialStore(KeyStore credentialStore)`
`void`
`setCredentialStoreLocation(String credentialStoreLocation)`
`void`
`setCredentialStorePassword(String credentialStorePassword)`
`void`
`setCredentialStoreType(String credentialStoreType)`
`void`
`setCrlLocationPattern(String crlLocationPattern)`
`void`
`setCrlStore(CertStore crlStore)`
`void`
`setCrlStoreType(String crlStoreType)`
`void`
`setHandlers(Map<String,ProxyPolicyHandler> handlers)`
`void`
`setPolicyStore(SigningPolicyStore policyStore)`
`void`
`setProtocol(String protocol)`
`void`
`setProvider(String provider)`
`void`
`setRejectLimitProxy(boolean rejectLimitProxy)`
`void`
`setSecureRandomAlgorithm(String secureRandomAlgorithm)`
`void`
`setTrustAnchorStore(KeyStore trustAnchorStore)`
`void`
`setTrustAnchorStoreLocation(String trustAnchorStoreLocation)`
`void`
`setTrustAnchorStorePassword(String trustAnchorStorePassword)`
`void`
`setTrustAnchorStoreType(String trustAnchorStoreType)`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### SSLConfigurator

public SSLConfigurator()

## Method Details

### createFactory

public SSLSocketFactory createFactory() throws GlobusSSLConfigurationException
Create an SSLSocketFactory based on the configured stores.

Returns:
  A configured SSLSocketFactory
Throws:
  `GlobusSSLConfigurationException` - If we fail to create the socketFactory.

### getSSLContext

public SSLContext getSSLContext() throws GlobusSSLConfigurationException
Create an SSLContext based on the configured stores.

Returns:
  A configured SSLContext.
Throws:
  `GlobusSSLConfigurationException` - If we fail to create the context.

### createServerFactory

public SSLServerSocketFactory createServerFactory() throws GlobusSSLConfigurationException
Create an SSLServerSocketFactory based on the configured stores.

Returns:
  A configured SSLServerSocketFactory
Throws:
  `GlobusSSLConfigurationException` - If we fail to create the server socket factory.

### getProvider

public String getProvider()

### setProvider

public void setProvider(String provider)

### getProtocol

public String getProtocol()

### setProtocol

public void setProtocol(String protocol)

### getSecureRandomAlgorithm

public String getSecureRandomAlgorithm()

### setSecureRandomAlgorithm

public void setSecureRandomAlgorithm(String secureRandomAlgorithm)

### getCredentialStorePassword

public String getCredentialStorePassword()

### setCredentialStorePassword

public void setCredentialStorePassword(String credentialStorePassword)

### getTrustAnchorStore

public KeyStore getTrustAnchorStore()

### setTrustAnchorStore

public void setTrustAnchorStore(KeyStore trustAnchorStore)

### getCrlStore

public CertStore getCrlStore()

### setCrlStore

public void setCrlStore(CertStore crlStore)

### getPolicyStore

public SigningPolicyStore getPolicyStore()

### setPolicyStore

public void setPolicyStore(SigningPolicyStore policyStore)

### isRejectLimitProxy

public boolean isRejectLimitProxy()

### setRejectLimitProxy

public void setRejectLimitProxy(boolean rejectLimitProxy)

### getHandlers

public Map<String,ProxyPolicyHandler> getHandlers()

### setHandlers

public void setHandlers(Map<String,ProxyPolicyHandler> handlers)

### getCredentialStoreLocation

public String getCredentialStoreLocation()

### setCredentialStoreLocation

public void setCredentialStoreLocation(String credentialStoreLocation)

### getCredentialStoreType

public String getCredentialStoreType()

### setCredentialStoreType

public void setCredentialStoreType(String credentialStoreType)

### getTrustAnchorStoreType

public String getTrustAnchorStoreType()

### setTrustAnchorStoreType

public void setTrustAnchorStoreType(String trustAnchorStoreType)

### getTrustAnchorStoreLocation

public String getTrustAnchorStoreLocation()

### setTrustAnchorStoreLocation

public void setTrustAnchorStoreLocation(String trustAnchorStoreLocation)

### getTrustAnchorStorePassword

public String getTrustAnchorStorePassword()

### setTrustAnchorStorePassword

public void setTrustAnchorStorePassword(String trustAnchorStorePassword)

### getCrlStoreType

public String getCrlStoreType()

### setCrlStoreType

public void setCrlStoreType(String crlStoreType)

### getCrlLocationPattern

public String getCrlLocationPattern()

### setCrlLocationPattern

public void setCrlLocationPattern(String crlLocationPattern)

### getCredentialStore

public KeyStore getCredentialStore()

### setCredentialStore

public void setCredentialStore(KeyStore credentialStore)