namespace DigitalData.Core.Abstractions.Security
{
public interface IAsymCryptService : IRSAFactory
{
///
/// Gets the formatter function for generating RSA key names.
/// This formatter takes an issuer, audience, isPrivate, and optional version and separator
/// to produce a formatted string used for the key naming convention.
///
/// A string representing the issuer of the key. It should not contain invalid file name characters or the separator.
/// A string representing the audience for which the key is intended. It should not contain invalid file name characters or the separator.
/// An bool to check if the key is private.
/// An instance of the interface, which is used to keep the version of Pbe password.
/// An optional string separator used to separate the issuer and audience. The default is "-_-". It should not be included in the issuer or audience strings.
/// A formatted string combining the issuer, audience, and separator, which adheres to valid file naming rules.
/// Thrown when the issuer, audience, or separator contains invalid characters or when the separator is present within the issuer or audience.
Func RSAKeyNameFormatter { get; }
IRSADecryptor this[string key] { get; }
bool TryGetRSADecryptor(string key, out IRSADecryptor? decryptor);
}
}