C# Class Dev2.Runtime.Security.HostSecureConfig

The Secure Config
Inheritance: ISecureConfig
Afficher le fichier Open project: Warewolf-ESB/Warewolf

Méthodes publiques

Méthode Description
CreateKey ( string base64String ) : RSACryptoServiceProvider

Creates the RSACryptoServiceProvider from the given base64 encoded key.

CreateSettings ( string serverID, string serverKey, string systemKey ) : NameValueCollection

Creates the a NameValueCollection configuration settings.

HostSecureConfig ( ) : System
HostSecureConfig ( NameValueCollection settings, bool shouldProtectConfig = true ) : System

Méthodes protégées

Méthode Description
Initialize ( NameValueCollection settings, bool shouldProtectConfig ) : void

Initializes config with the given values and optionally protects it. If shouldProtectConfig is true, then the config file must exist on disk.

ProtectConfig ( ) : void

Protects the configuration using the RsaProtectedConfigurationProvider.

SaveConfig ( NameValueCollection secureSettings ) : void

Saves the given secure settings into XML configuration file called FileName.

Private Methods

Méthode Description
EnsureSecureConfigFileExists ( ) : void

Method Details

CreateKey() public static méthode

Creates the RSACryptoServiceProvider from the given base64 encoded key.
public static CreateKey ( string base64String ) : RSACryptoServiceProvider
base64String string The base64 encoded key.
Résultat System.Security.Cryptography.RSACryptoServiceProvider

CreateSettings() public static méthode

Creates the a NameValueCollection configuration settings.
public static CreateSettings ( string serverID, string serverKey, string systemKey ) : NameValueCollection
serverID string The server ID.
serverKey string The server key.
systemKey string The system key.
Résultat System.Collections.Specialized.NameValueCollection

HostSecureConfig() public méthode

public HostSecureConfig ( ) : System
Résultat System

HostSecureConfig() public méthode

public HostSecureConfig ( NameValueCollection settings, bool shouldProtectConfig = true ) : System
settings System.Collections.Specialized.NameValueCollection
shouldProtectConfig bool
Résultat System

Initialize() protected méthode

Initializes config with the given values and optionally protects it. If shouldProtectConfig is true, then the config file must exist on disk.
settings
protected Initialize ( NameValueCollection settings, bool shouldProtectConfig ) : void
settings System.Collections.Specialized.NameValueCollection The settings to be loaded.
shouldProtectConfig bool true if the configuration should be protected; false otherwise.
Résultat void

ProtectConfig() protected méthode

Protects the configuration using the RsaProtectedConfigurationProvider.
protected ProtectConfig ( ) : void
Résultat void

SaveConfig() protected méthode

Saves the given secure settings into XML configuration file called FileName.
protected SaveConfig ( NameValueCollection secureSettings ) : void
secureSettings System.Collections.Specialized.NameValueCollection The settings to be saved.
Résultat void