Show / Hide Table of Contents

# Class SslContextFactory

This SSL context factory that provides ssl context configuration with specified key and trust stores.

##### Inheritance

System.Object
SslContextFactory

##### Implements

ISslContextFactory

##### Inherited Members

System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()

###### Namespace: Apache.Ignite.Core.Ssl

###### Assembly: Apache.Ignite.Core.dll

##### Syntax

    [Serializable]
    public class SslContextFactory : ISslContextFactory

### Constructors

#### SslContextFactory()

Default constructor.

##### Declaration

    public SslContextFactory()

#### SslContextFactory(String, String)

Creates a new instance of the SslContextFactory class. Trust store file is not set that results in accepting any SSL Certificate.

##### Declaration

    public SslContextFactory(string keyStoreFilePath, string keyStorePassword)

##### Parameters

Type | Name | Description
--- | --- | ---
System.String | keyStoreFilePath | Path to key store file.
System.String | keyStorePassword | Key store password.

#### SslContextFactory(String, String, String, String)

Creates a new instance of the SslContextFactory class.

##### Declaration

    public SslContextFactory(string keyStoreFilePath, string keyStorePassword, string trustStoreFilePath, string trustStorePassword)

##### Parameters

Type | Name | Description
--- | --- | ---
System.String | keyStoreFilePath | Path to key store file.
System.String | keyStorePassword | Key store password.
System.String | trustStoreFilePath | Path to trust store file.
System.String | trustStorePassword | Trust store password.

### Fields

#### DefaultKeyAlgorithm

Default value for KeyAlgorithm.

##### Declaration

    public const string DefaultKeyAlgorithm = "SunX509"

##### Field Value

Type | Description
--- | ---
System.String |

#### DefaultSslProtocol

Default value for Protocol.

##### Declaration

    public const string DefaultSslProtocol = "TLS"

##### Field Value

Type | Description
--- | ---
System.String |

#### DefaultStoreType

Default value for KeyStoreType and TrustStoreType.

##### Declaration

    public const string DefaultStoreType = "JKS"

##### Field Value

Type | Description
--- | ---
System.String |

### Properties

#### KeyAlgorithm

Key manager algorithm that will be used to create a key manager. Notice that in most cased default value DefaultKeyAlgorithm suites well, however, on Android platform this value need to be set to X509.

##### Declaration

    public string KeyAlgorithm { get; set; }

##### Property Value

Type | Description
--- | ---
System.String |

#### KeyStoreFilePath

Key store file path.

##### Declaration

    public string KeyStoreFilePath { get; set; }

##### Property Value

Type | Description
--- | ---
System.String |

#### KeyStorePassword

Key store file password.

##### Declaration

    public string KeyStorePassword { get; set; }

##### Property Value

Type | Description
--- | ---
System.String |

#### KeyStoreType

Key store type used for context creation. DefaultStoreType by default.

##### Declaration

    public string KeyStoreType { get; set; }

##### Property Value

Type | Description
--- | ---
System.String |

#### Protocol

Protocol for secure transport. DefaultSslProtocol by default.

##### Declaration

    public string Protocol { get; set; }

##### Property Value

Type | Description
--- | ---
System.String |

#### TrustStoreFilePath

Path to trust store file. Could be null if any SSL Certificate should be accepted/succeed.

##### Declaration

    public string TrustStoreFilePath { get; set; }

##### Property Value

Type | Description
--- | ---
System.String |

#### TrustStorePassword

Trust store password.

##### Declaration

    public string TrustStorePassword { get; set; }

##### Property Value

Type | Description
--- | ---
System.String |

#### TrustStoreType

Trust store type used for context creation. DefaultStoreType by default.

##### Declaration

    public string TrustStoreType { get; set; }

##### Property Value

Type | Description
--- | ---
System.String |

### Implements

ISslContextFactory