C# Class CCNet.Build.Common.SecureConfig

Helps storing sensitive data in a secure way.
Show file Open project: shuruev/CCNet.Extensions

Public Methods

Method Description
Decrypt ( string text ) : string

Decrypts text from its specified UTF-8 binary representation.

Decrypt64 ( string text ) : string

Decrypts data from its specified base-64 representation.

Encrypt ( string text ) : string

Encrypts specified text using UTF-8 as its binary representation.

Encrypt64 ( string text ) : string

Encrypts specified data specified by its base-64 representation.

Initialize ( string thumbprint ) : void

Initializes a secured storage using certificate with specified thumbprint.

Private Methods

Method Description
Find ( string thumbprint ) : X509Certificate2

Tries to find certificate by specified thumbprint.

Method Details

Decrypt() public static method

Decrypts text from its specified UTF-8 binary representation.
public static Decrypt ( string text ) : string
text string
return string

Decrypt64() public static method

Decrypts data from its specified base-64 representation.
public static Decrypt64 ( string text ) : string
text string
return string

Encrypt() public static method

Encrypts specified text using UTF-8 as its binary representation.
public static Encrypt ( string text ) : string
text string
return string

Encrypt64() public static method

Encrypts specified data specified by its base-64 representation.
public static Encrypt64 ( string text ) : string
text string
return string

Initialize() public static method

Initializes a secured storage using certificate with specified thumbprint.
public static Initialize ( string thumbprint ) : void
thumbprint string
return void