26 references to KeyType
System.Security.Cryptography.Cose (26)
System\Security\Cryptography\Cose\CoseHelpers.cs (12)
110KeyType keyType = signer._keyType; 112if (keyType == KeyType.ECDsa) 118Debug.Assert(keyType == KeyType.RSA); 202KeyType keyType = signer._keyType; 204if (keyType == KeyType.ECDsa) 210Debug.Assert(keyType == KeyType.RSA); 259internal static HashAlgorithmName GetHashAlgorithmFromCoseAlgorithmAndKeyType(int algorithm, KeyType keyType, out RSASignaturePadding? padding) 261if (keyType == KeyType.ECDsa) 274Debug.Assert(keyType == KeyType.RSA); 298internal static KeyType GetKeyType(AsymmetricAlgorithm key) 302ECDsa => KeyType.ECDsa, 303RSA => KeyType.RSA,
System\Security\Cryptography\Cose\CoseSign1Message.cs (5)
609private bool VerifyCore(AsymmetricAlgorithm key, ReadOnlySpan<byte> contentBytes, Stream? contentStream, ReadOnlySpan<byte> associatedData, KeyType keyType) 710private async Task<bool> VerifyAsyncCore(AsymmetricAlgorithm key, Stream content, ReadOnlyMemory<byte> associatedData, KeyType keyType, CancellationToken cancellationToken) 741private bool VerifyHash(AsymmetricAlgorithm key, IncrementalHash hasher, HashAlgorithmName hashAlgorithm, KeyType keyType, RSASignaturePadding? padding) 750if (keyType == KeyType.ECDsa) 757Debug.Assert(keyType == KeyType.RSA);
System\Security\Cryptography\Cose\CoseSignature.cs (5)
385private async Task<bool> VerifyAsyncCore(AsymmetricAlgorithm key, Stream content, ReadOnlyMemory<byte> associatedData, KeyType keyType, CancellationToken cancellationToken) 419private bool VerifyCore(AsymmetricAlgorithm key, ReadOnlySpan<byte> contentBytes, Stream? contentStream, ReadOnlySpan<byte> associatedData, KeyType keyType) 451private bool VerifyHash(AsymmetricAlgorithm key, IncrementalHash hasher, HashAlgorithmName hashAlgorithm, KeyType keyType, RSASignaturePadding? padding) 460if (keyType == KeyType.ECDsa) 467Debug.Assert(keyType == KeyType.RSA);
System\Security\Cryptography\Cose\CoseSigner.cs (4)
13internal readonly KeyType _keyType; 162if (_keyType == KeyType.RSA) 178if (_keyType == KeyType.ECDsa) 189Debug.Assert(_keyType == KeyType.RSA);