Example #1
0
        private bool IsSupportedEncryptionAlgorithm(string algorithm, object[] args, out AuthenticatedEncryptionProviderDescriptor descriptor)
        {
            if (args.Length == 1 && args[0] is SecurityKey key)
            {
                return(IsSupportedEncryptionAlgorithm(algorithm, key, out descriptor));
            }

            descriptor = null;
            return(false);
        }
Example #2
0
 private bool IsSupportedEncryptionAlgorithm(string algorithm, SecurityKey key, out AuthenticatedEncryptionProviderDescriptor descriptor)
 => _options.SupportedEncryptionAlgorithms.TryGetValue(algorithm, out descriptor);