Class SilverbackCryptoStreamFactory
- Namespace
- Silverback.Messaging.Encryption
- Assembly
- Silverback.Integration.dll
The factory used to create the SilverbackCryptoStream implementation according to the IEncryptionSettings or IDecryptionSettings.
public class SilverbackCryptoStreamFactory : ISilverbackCryptoStreamFactory
- Inheritance
-
SilverbackCryptoStreamFactory
- Implements
- Inherited Members
Constructors
SilverbackCryptoStreamFactory()
public SilverbackCryptoStreamFactory()
Methods
GetDecryptStream(Stream, IDecryptionSettings, string?)
Gets a SilverbackCryptoStream compatible with the specified settings.
public SilverbackCryptoStream GetDecryptStream(Stream stream, IDecryptionSettings settings, string? keyIdentifier = null)
Parameters
streamStreamThe inner Stream to read the encrypted message from.
settingsIDecryptionSettingsThe IDecryptionSettings specifying the cryptographic algorithm settings.
keyIdentifierstringThe encryption key identifier that was submitted as header.
Returns
- SilverbackCryptoStream
A SilverbackCryptoStream compatible with the specified settings.
GetEncryptStream(Stream, IEncryptionSettings)
Gets a SilverbackCryptoStream compatible with the specified settings.
public SilverbackCryptoStream GetEncryptStream(Stream stream, IEncryptionSettings settings)
Parameters
streamStreamThe inner Stream to read the clear-text message from.
settingsIEncryptionSettingsThe IEncryptionSettings specifying the cryptographic algorithm settings.
Returns
- SilverbackCryptoStream
A SilverbackCryptoStream compatible with the specified settings.