791 references to CryptographicException
dotnet-sourcelink (1)
Microsoft.AspNetCore.Cryptography.Internal (5)
CryptoUtil.cs (1)
62throw new CryptographicException("Assertion failed: " + message);
SafeHandles\BCryptAlgorithmHandle.cs (1)
145throw new CryptographicException(message);
UnsafeNativeMethods.cs (3)
473throw new CryptographicException(message); 482throw new CryptographicException(message); 499throw new CryptographicException(message);
Microsoft.AspNetCore.DataProtection (5)
Error.cs (5)
37return new CryptographicException(message); 60return new CryptographicException(message); 66return new CryptographicException(message); 81return new CryptographicException(Resources.ProtectionProvider_BadMagicHeader); 86return new CryptographicException(Resources.ProtectionProvider_BadVersion);
Microsoft.AspNetCore.DataProtection.Abstractions (2)
CryptoUtil.cs (1)
22throw new CryptographicException("Assertion failed: " + message);
Error.cs (1)
20return new CryptographicException(message);
Microsoft.AspNetCore.DataProtection.Extensions (2)
TimeLimitedDataProtector.cs (2)
78throw new CryptographicException(Resources.TimeLimitedDataProtector_PayloadInvalid); 88throw new CryptographicException(Resources.FormatTimeLimitedDataProtector_PayloadExpired(embeddedExpiration));
Mono.Cecil (3)
Mono.Security.Cryptography\CryptoConvert.cs (3)
78 throw new CryptographicException ("Invalid blob header"); 185 throw new CryptographicException ("Invalid blob header"); 259 throw new CryptographicException ("Unknown blob format.");
NuGet.Packaging (49)
Signing\DerEncoding\DerEncoder.cs (6)
449throw new CryptographicException(SR.Argument_InvalidOidValue); 451throw new CryptographicException(SR.Argument_InvalidOidValue); 453throw new CryptographicException(SR.Argument_InvalidOidValue); 469throw new CryptographicException(SR.Argument_InvalidOidValue); 789throw new CryptographicException(SR.Cryptography_Invalid_IA5String); 1000throw new CryptographicException(SR.Argument_InvalidOidValue);
Signing\DerEncoding\DerGeneralizedTime.cs (5)
27throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 32throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 56throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 62throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 92throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
Signing\DerEncoding\DerSequenceReader.cs (23)
68throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 95throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 101throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 139throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 160throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 207throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 246throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 251throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 277throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 406throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 448throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 506throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 526throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 535throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 543throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 556throw new CryptographicException( 583throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 592throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 603throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 610throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 614throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 631throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 635throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
Signing\Timestamp\Accuracy.cs (4)
56throw new CryptographicException(Strings.InvalidAsn1); 66throw new CryptographicException(Strings.InvalidAsn1); 76throw new CryptographicException(Strings.InvalidAsn1); 82throw new CryptographicException(Strings.InvalidAsn1);
Signing\Timestamp\Extension.cs (1)
53throw new CryptographicException(Strings.InvalidAsn1);
Signing\Timestamp\Extensions.cs (1)
46throw new CryptographicException(Strings.InvalidAsn1);
Signing\Timestamp\MessageImprint.cs (2)
45throw new CryptographicException(Strings.InvalidAsn1); 50throw new CryptographicException(Strings.InvalidAsn1);
Signing\Timestamp\Rfc3161TimestampRequestNetstandard21Wrapper.cs (1)
63throw new CryptographicException(
Signing\Timestamp\Rfc3161TimestampTokenInfoNetstandard21Wrapper.cs (1)
22throw new CryptographicException(Strings.InvalidAsn1);
Signing\Timestamp\Rfc3161TimestampTokenNetstandard21Wrapper.cs (1)
28throw new CryptographicException(Strings.InvalidAsn1);
Signing\Timestamp\TstInfo.cs (3)
89throw new CryptographicException(Strings.InvalidAsn1); 141throw new CryptographicException(Strings.InvalidAsn1); 147throw new CryptographicException(Strings.InvalidAsn1);
Signing\Utility\AttributeUtility.cs (1)
339throw new CryptographicException(string.Format(CultureInfo.CurrentCulture, Strings.MultipleAttributesDisallowed, oid));
System.Net.Quic (1)
src\runtime\src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.ERR.cs (1)
112: base(message)
System.Net.Security (1)
src\runtime\src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.ERR.cs (1)
112: base(message)
System.Security.Cryptography (424)
src\runtime\src\libraries\Common\src\Internal\Cryptography\PkcsHelpers.cs (5)
70throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 91throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 120throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 135throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 326throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\AesAEAD.cs (1)
12throw new CryptographicException(SR.Cryptography_InvalidKeySize);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Asn1\AttributeAsn.xml.cs (1)
204throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Asn1\Pkcs12\PfxAsn.manual.cs (2)
49throw new CryptographicException( 55throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Asn1\PssParamsAsn.manual.cs (4)
15throw new CryptographicException(SR.Cryptography_Pkcs_InvalidSignatureParameters); 27throw new CryptographicException(SR.Cryptography_Pkcs_InvalidSignatureParameters); 37throw new CryptographicException( 53throw new CryptographicException(
src\runtime\src\libraries\Common\src\System\Security\Cryptography\AuthenticationTagMismatchException.cs (2)
16public AuthenticationTagMismatchException() : base(SR.Cryptography_AuthTagMismatch) 27public AuthenticationTagMismatchException(string? message) : base(message ?? SR.Cryptography_AuthTagMismatch)
src\runtime\src\libraries\Common\src\System\Security\Cryptography\CngPkcs8.cs (1)
235throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\CompositeMLDsa.cs (11)
679throw new CryptographicException(SR.Format(SR.Cryptography_AlgorithmNotSupported, nameof(CompositeMLDsa))); 684throw new CryptographicException(SR.Argument_PublicKeyWrongSizeForAlgorithm); 877throw new CryptographicException(SR.Format(SR.Cryptography_AlgorithmNotSupported, nameof(CompositeMLDsa))); 882throw new CryptographicException(SR.Argument_PrivateKeyWrongSizeForAlgorithm); 933throw new CryptographicException(SR.Argument_PublicKeyWrongSizeForAlgorithm); 983throw new CryptographicException(SR.Argument_PrivateKeyWrongSizeForAlgorithm); 1552throw new CryptographicException(SR.Argument_DestinationTooShort); 1557throw new CryptographicException(SR.Argument_DestinationTooShort); 1677throw new CryptographicException(SR.Argument_DestinationTooShort); 1682throw new CryptographicException(SR.Argument_DestinationTooShort); 1821throw new CryptographicException(SR.Argument_PrivateKeyWrongSizeForAlgorithm);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\CompositeMLDsaImplementation.Windows.cs (3)
44throw new CryptographicException(SR.Cryptography_NoPrivateKeyAvailable); 127throw new CryptographicException(SR.Cryptography_NoPrivateKeyAvailable); 140throw new CryptographicException(SR.Cryptography_NoPrivateKeyAvailable);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\CompositeMLKem.cs (12)
194throw new CryptographicException(SR.Cryptography_OverlappingBuffers); 411throw new CryptographicException(SR.Argument_PublicKeyWrongSizeForAlgorithm); 489throw new CryptographicException(SR.Argument_PrivateKeyWrongSizeForAlgorithm); 581throw new CryptographicException(SR.Format(SR.Cryptography_AlgorithmNotSupported, nameof(CompositeMLKem))); 586throw new CryptographicException(SR.Argument_PublicKeyWrongSizeForAlgorithm); 680throw new CryptographicException(SR.Format(SR.Cryptography_AlgorithmNotSupported, nameof(CompositeMLKem))); 685throw new CryptographicException(SR.Argument_PrivateKeyWrongSizeForAlgorithm); 1855throw new CryptographicException(SR.Argument_DestinationTooShort); 1860throw new CryptographicException(SR.Argument_DestinationTooShort); 1998throw new CryptographicException(SR.Argument_DestinationTooShort); 2003throw new CryptographicException(SR.Argument_DestinationTooShort); 2126throw new CryptographicException(SR.Argument_PrivateKeyWrongSizeForAlgorithm);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\CryptographicAttributeObjectCollection.cs (1)
63throw new CryptographicException(SR.Cryptography_Pkcs9_MultipleSigningTimeNotAllowed);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\CryptoThrowHelper.Windows.cs (1)
29return new CryptographicException(message)
src\runtime\src\libraries\Common\src\System\Security\Cryptography\DSACng.ImportExport.cs (2)
432throw new CryptographicException(SR.Cryptography_NotValidPrivateKey); 437throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\DSAKeyFormatHelper.cs (6)
25throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 39throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 67throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 91throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 105throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 130throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\ECCng.ImportExport.cs (2)
298throw new CryptographicException(SR.Cryptography_NotValidPrivateKey); 305throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\ECDiffieHellmanCng.ImportExport.cs (1)
122throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\ECDsaCng.ImportExport.cs (1)
162throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Helpers.cs (4)
138throw new CryptographicException(SR.Format(SR.Cryptography_UnknownHashAlgorithm, hashOid)); 154throw new CryptographicException(SR.Cryptography_HashLengthMismatch); 230throw new CryptographicException( 272throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\KeyBlobHelpers.cs (1)
52throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\KeyFormatHelper.cs (4)
53throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey); 84throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey); 126throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey); 154throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\KeyFormatHelper.Encrypted.cs (3)
173throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 417throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 453throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\MLDsa.cs (11)
322throw new CryptographicException(SR.Format(SR.Cryptography_UnknownHashAlgorithm, hashAlgorithmOid)); 327throw new CryptographicException(SR.Format( 335throw new CryptographicException(SR.Cryptography_HashLengthMismatch); 440throw new CryptographicException(SR.Cryptography_HashLengthMismatch); 1372throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 2188throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 2197throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 2209throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 2226throw new CryptographicException(SR.Cryptography_MLDsaPkcs8KeyMismatch); 2241throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 2248throw new CryptographicException(
src\runtime\src\libraries\Common\src\System\Security\Cryptography\MLDsaCng.Windows.cs (6)
61throw new CryptographicException(SR.Cryptography_ArgMLDsaRequiresMLDsaKey); 134throw new CryptographicException(SR.Argument_PrivateSeedWrongSizeForAlgorithm); 141throw new CryptographicException(SR.Cryptography_NotValidPrivateKey); 179throw new CryptographicException(SR.Argument_PrivateKeyWrongSizeForAlgorithm); 192throw new CryptographicException(SR.Argument_PrivateSeedWrongSizeForAlgorithm); 202throw new CryptographicException(SR.Cryptography_NotValidPrivateKey);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\MLDsaImplementation.Windows.cs (4)
44throw new CryptographicException(SR.Cryptography_NoPrivateKeyAvailable); 67throw new CryptographicException(SR.Cryptography_NoPrivateKeyAvailable); 185throw new CryptographicException(SR.Cryptography_NoPrivateKeyAvailable); 198throw new CryptographicException(SR.Cryptography_PqcNoSeed);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\MLDsaPkcs8.cs (1)
49throw new CryptographicException(SR.Cryptography_NotValidPrivateKey);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\MLKem.cs (9)
127throw new CryptographicException(SR.Cryptography_OverlappingBuffers); 1198throw new CryptographicException(SR.Argument_KemInvalidEncapsulationKeyLength); 1702throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 1711throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 1723throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 1740throw new CryptographicException(SR.Cryptography_KemPkcs8KeyMismatch); 1755throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 1829throw new CryptographicException(SR.Cryptography_PqcNoSeed); 1837throw new CryptographicException(SR.Cryptography_KemNoDecapsulationKey);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\MLKem.Windows.cs (2)
34throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey); 44throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\MLKemCng.Windows.cs (6)
53throw new CryptographicException(SR.Cryptography_ArgMLKemRequiresMLKemKey); 138throw new CryptographicException(SR.Cryptography_KeyNotExtractable); 154throw new CryptographicException(SR.Cryptography_KeyNotExtractable); 176throw new CryptographicException(SR.Cryptography_KeyNotExtractable); 204throw new CryptographicException(SR.Cryptography_KeyNotExtractable); 229throw new CryptographicException(SR.Cryptography_KeyNotExtractable);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\MLKemPkcs8.cs (1)
49throw new CryptographicException(SR.Cryptography_NotValidPrivateKey);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\PasswordBasedEncryption.cs (25)
107throw new CryptographicException( 170throw new CryptographicException( 270throw new CryptographicException( 302throw new CryptographicException( 545throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 552throw new CryptographicException( 604throw new CryptographicException( 633throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 656throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 674throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 681throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 692throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 711throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 733throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 749throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 768throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 777throw new CryptographicException( 786throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 795_ => throw new CryptographicException( 806throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 857throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 864throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 869throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 908throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 1137throw new CryptographicException(SR.Argument_InvalidValue);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Pkcs\Pkcs12CertBag.cs (2)
95throw new CryptographicException(SR.Argument_InvalidOidValue); 112throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Pkcs\Pkcs12Info.cs (3)
66throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 98throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 104throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Pkcs\Pkcs12SafeContents.cs (4)
70throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 231throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 239throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 244throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Pkcs\Pkcs8PrivateKeyInfo.cs (2)
192throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 223throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\RSACng.EncryptDecrypt.cs (8)
45throw new CryptographicException(SR.Cryptography_RSA_DecryptWrongSize); 52throw new CryptographicException( 75throw new CryptographicException(SR.Cryptography_UnsupportedPaddingMode); 112throw new CryptographicException(SR.Cryptography_UnsupportedPaddingMode); 127throw new CryptographicException(SR.Cryptography_RSA_DecryptWrongSize); 134throw new CryptographicException( 157throw new CryptographicException(SR.Cryptography_UnsupportedPaddingMode); 192throw new CryptographicException(SR.Cryptography_UnsupportedPaddingMode);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\RSACng.ImportExport.cs (1)
87throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\RSACng.SignVerify.cs (5)
51throw new CryptographicException(SR.Cryptography_SignHash_WrongSize); 73throw new CryptographicException(SR.Cryptography_UnsupportedPaddingMode); 94throw new CryptographicException(SR.Cryptography_SignHash_WrongSize); 111throw new CryptographicException(SR.Cryptography_UnsupportedPaddingMode); 159throw new CryptographicException(SR.Cryptography_UnsupportedPaddingMode);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\RSAKeyFormatHelper.cs (1)
25throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\RSAKeyFormatHelper.Pkcs1.cs (4)
27throw new CryptographicException( 101throw new CryptographicException(SR.Cryptography_InvalidRsaParameters); 117throw new CryptographicException(SR.Cryptography_InvalidRsaParameters); 127throw new CryptographicException(SR.Cryptography_NotValidPrivateKey);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\RsaPaddingProcessor.cs (6)
130throw new CryptographicException(SR.Cryptography_KeyTooSmall); 265throw new CryptographicException(SR.Cryptography_SignHash_WrongSize); 273throw new CryptographicException(SR.Cryptography_KeyTooSmall); 310throw new CryptographicException( 393throw new CryptographicException(SR.Cryptography_SignHash_WrongSize); 405throw new CryptographicException(SR.Cryptography_KeyTooSmall);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\SlhDsa.cs (2)
1235throw new CryptographicException(SR.Argument_PublicKeyWrongSizeForAlgorithm); 1297throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\SlhDsaAlgorithm.cs (1)
262throw new CryptographicException(
src\runtime\src\libraries\Common\src\System\Security\Cryptography\SP800108HmacCounterKdf.cs (1)
566throw new CryptographicException(SR.Format(SR.Cryptography_UnknownHashAlgorithm, hashAlgorithmName));
src\runtime\src\libraries\Common\src\System\Security\Cryptography\X25519DiffieHellman.cs (4)
1023throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 1028throw new CryptographicException(SR.Argument_PublicKeyWrongSizeForAlgorithm); 1590throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 1599throw new CryptographicException(SR.Argument_PrivateKeyWrongSizeForAlgorithm);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\X25519DiffieHellmanCng.Windows.cs (2)
245throw new CryptographicException(SR.Cryptography_NotValidPrivateKey); 255throw new CryptographicException(SR.Cryptography_NotValidPrivateKey);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\X25519DiffieHellmanImplementation.Windows.cs (1)
276throw new CryptographicException(SR.Cryptography_CSP_NoPrivateKey);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\X25519WindowsHelpers.cs (2)
44throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey); 56throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\X509Certificates\Pkcs12LoadLimitExceededException.cs (1)
20: base(SR.Format(SR.Cryptography_X509_PKCS12_LimitExceeded, propertyName))
src\runtime\src\libraries\Common\src\System\Security\Cryptography\X509Certificates\X509CertificateLoader.cs (1)
674throw new CryptographicException(message)
src\runtime\src\libraries\Common\src\System\Security\Cryptography\X509Certificates\X509CertificateLoader.Pkcs12.cs (12)
83throw new CryptographicException(SR.Cryptography_Pfx_NoCertificates); 149throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 257throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 512throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 520throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 525throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 558throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 567throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 594throw new CryptographicException( 602throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 612throw new CryptographicException( 1186throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
System\Security\Cryptography\Aes.cs (6)
143throw new CryptographicException(SR.Cryptography_OverlappingBuffers); 268throw new CryptographicException(SR.Cryptography_OverlappingBuffers); 331throw new CryptographicException(SR.Cryptography_KeyWrap_DecryptFailed); 473throw new CryptographicException(SR.Cryptography_OverlappingBuffers); 603throw new CryptographicException(SR.Cryptography_OverlappingBuffers); 728throw new CryptographicException(SR.Cryptography_KeyWrap_DecryptFailed);
System\Security\Cryptography\AesCng.Windows.cs (2)
302throw new CryptographicException(SR.Cryptography_InvalidKeySize); 330throw new CryptographicException(SR.Cryptography_InvalidCipherMode);
System\Security\Cryptography\AesImplementation.cs (1)
303throw new CryptographicException(SR.Format(SR.Cryptography_CipherModeFeedbackNotSupported, feedback, CipherMode.CFB));
System\Security\Cryptography\AsymmetricAlgorithm.cs (1)
35throw new CryptographicException(SR.Cryptography_InvalidKeySize);
System\Security\Cryptography\BasicSymmetricCipherLiteBCrypt.cs (1)
78throw new CryptographicException(SR.Cryptography_UnexpectedTransformTruncation);
System\Security\Cryptography\BasicSymmetricCipherLiteNCrypt.cs (2)
48_ => throw new CryptographicException(SR.Cryptography_InvalidCipherMode), 88throw new CryptographicException(SR.Cryptography_UnexpectedTransformTruncation);
System\Security\Cryptography\CapiHelper.DSA.Windows.cs (1)
48throw new CryptographicException(SR.Cryptography_InvalidDSASignatureSize);
System\Security\Cryptography\CapiHelper.Windows.cs (6)
540throw new CryptographicException(SR.Cryptography_OpenInvalidHandle); 755throw new CryptographicException(SR.Format(SR.Cryptography_CSP_WrongKeySpec, keyType)); 836throw new CryptographicException("Cryptography_OAEP_XPPlus_Only"); 840throw new CryptographicException("Cryptography_OAEPDecoding"); 1039throw new CryptographicException(SR.Cryptography_InvalidOID); 1284throw new CryptographicException(SR.Cryptography_PasswordDerivedBytes_InvalidIV);
System\Security\Cryptography\ChaCha20Poly1305.cs (1)
46throw new CryptographicException(SR.Cryptography_InvalidKeySize);
System\Security\Cryptography\CngHelpers.cs (12)
78throw new CryptographicException(SR.Cryptography_KeyBlobParsingError); 82throw new CryptographicException(SR.Cryptography_KeyBlobParsingError); 90throw new CryptographicException(SR.Format(SR.Cryptography_CngKeyWrongAlgorithm, algorithmName, algorithm)); 94throw new CryptographicException(SR.Cryptography_KeyBlobParsingError); 99throw new CryptographicException(SR.Cryptography_KeyBlobParsingError); 103throw new CryptographicException(SR.Cryptography_KeyBlobParsingError); 115throw new CryptographicException(SR.Cryptography_InvalidRsaParameters); 128throw new CryptographicException(SR.Cryptography_InvalidRsaParameters); 141throw new CryptographicException(SR.Cryptography_InvalidRsaParameters); 160throw new CryptographicException(SR.Cryptography_InvalidRsaParameters); 283throw new CryptographicException(SR.Cryptography_NotValidPrivateKey); 293throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey);
System\Security\Cryptography\CngSymmetricAlgorithmCore.cs (6)
47throw new CryptographicException(SR.Format(SR.Cryptography_CngKeyWrongAlgorithm, actualAlgorithm.Algorithm, algorithm)); 62throw new CryptographicException( 178throw new CryptographicException(SR.Cryptography_MissingIV); 298throw new CryptographicException(SR.Format(SR.Cryptography_CipherModeFeedbackNotSupported, feedbackSizeInBits, CipherMode.CFB)); 305throw new CryptographicException(SR.Format(SR.Cryptography_CipherModeFeedbackNotSupported, feedbackSizeInBits, CipherMode.CFB)); 321throw new CryptographicException(
System\Security\Cryptography\ConcurrencyBlock.cs (1)
19throw new CryptographicException(SR.Cryptography_ConcurrentUseNotSupported);
System\Security\Cryptography\CryptographicOperations.cs (1)
1134throw new CryptographicException(SR.Format(SR.Cryptography_UnknownHashAlgorithm, hashAlgorithm.Name));
System\Security\Cryptography\CryptographicUnexpectedOperationException.cs (3)
15: base(SR.Arg_CryptographyException) 20: base(message ?? SR.Arg_CryptographyException) 30: base(string.Format(CultureInfo.CurrentCulture, format, insert))
System\Security\Cryptography\CspKeyContainerInfo.Windows.cs (2)
211throw new CryptographicException(SR.Cryptography_CSP_NotFound); 244throw new CryptographicException(SR.Cryptography_CSP_NotFound);
System\Security\Cryptography\DES.cs (2)
69throw new CryptographicException(SR.Cryptography_InvalidKeySize); 87throw new CryptographicException(SR.Cryptography_InvalidKeySize);
System\Security\Cryptography\DESCryptoServiceProvider.Windows.cs (1)
93throw new CryptographicException(SR.Cryptography_InvalidIVSize);
System\Security\Cryptography\DesImplementation.cs (1)
237throw new CryptographicException(SR.Format(SR.Cryptography_CipherModeFeedbackNotSupported, feedback, CipherMode.CFB));
System\Security\Cryptography\DSA.Xml.cs (2)
22throw new CryptographicException( 67throw new CryptographicException(
System\Security\Cryptography\DSACryptoServiceProvider.Windows.cs (2)
485throw new CryptographicException(SR.Cryptography_CSP_NoPrivateKey); 490throw new CryptographicException(SR.Format(SR.Cryptography_InvalidHashSize, "SHA1", SHA1.HashSizeInBytes));
System\Security\Cryptography\EccKeyFormatHelper.cs (26)
108throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 120throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 127throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey); 133throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 175throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 182throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 189throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey); 195throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 223throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 239throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 253throw new CryptographicException(SR.Cryptography_ECC_NamedCurvesOnly); 287throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 292throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 313throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 333throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 346throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 367throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 374throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 395throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 426throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 487throw new CryptographicException(SR.Cryptography_CSP_NoPrivateKey); 530throw new CryptographicException( 641throw new CryptographicException(SR.Cryptography_InvalidECCharacteristic2Curve); 692throw new CryptographicException(SR.Cryptography_InvalidECCharacteristic2Curve); 705throw new CryptographicException(SR.Cryptography_InvalidECCharacteristic2Curve); 714throw new CryptographicException(SR.Cryptography_InvalidECCharacteristic2Curve);
System\Security\Cryptography\ECCurve.cs (5)
189throw new CryptographicException(SR.Cryptography_InvalidECNamedCurve); 195throw new CryptographicException(SR.Format(SR.Cryptography_InvalidCurveOid, Oid?.Value)); 223throw new CryptographicException(SR.Cryptography_InvalidECPrimeCurve); 236throw new CryptographicException(SR.Cryptography_InvalidECCharacteristic2Curve); 245throw new CryptographicException(SR.Format(SR.Cryptography_CurveNotSupported, CurveType.ToString()));
System\Security\Cryptography\ECParameters.cs (1)
58throw new CryptographicException(SR.Cryptography_InvalidCurveKeyParameters);
System\Security\Cryptography\HashAlgorithmName.cs (1)
195throw new CryptographicException(SR.Format(SR.Cryptography_InvalidHashAlgorithmOid, oidValue));
System\Security\Cryptography\Helpers.cs (10)
45throw new CryptographicException(SR.Cryptography_MissingIV); 175throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 190throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 313throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 320throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 460throw new CryptographicException(SR.Cryptography_HashAlgorithmNameNullOrEmpty); 463throw new CryptographicException(SR.Format(SR.Cryptography_UnknownAlgorithmIdentifier, exportParameters.HashAlgorithm.Name)); 473throw new CryptographicException(SR.Cryptography_HashAlgorithmNameNullOrEmpty); 475throw new CryptographicException(SR.Format(SR.Cryptography_UnknownAlgorithmIdentifier, exportParameters.HashAlgorithm.Name)); 479throw new CryptographicException(SR.Format(SR.Cryptography_UnknownAlgorithmIdentifier, exportParameters.EncryptionAlgorithm));
System\Security\Cryptography\HKDF.Windows.cs (1)
167throw new CryptographicException(SR.Format(message, s_maxCngKeyLengthInBytes));
System\Security\Cryptography\HMACCommon.cs (1)
101throw new CryptographicException(SR.Format(SR.Cryptography_UnknownHashAlgorithm, _hashAlgorithmId));
System\Security\Cryptography\KeyBlobHelpers.cs (2)
32throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 55throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey);
System\Security\Cryptography\Oid.cs (2)
46throw new CryptographicException(SR.Cryptography_Oid_InvalidName); 57throw new CryptographicException(SR.Cryptography_Oid_InvalidValue);
System\Security\Cryptography\PasswordDeriveBytes.cs (1)
263throw new CryptographicException(SR.Cryptography_PasswordDerivedBytes_TooManyBytes);
System\Security\Cryptography\PasswordDeriveBytes.Windows.cs (4)
18throw new CryptographicException(SR.Cryptography_InvalidKeySize); 22throw new CryptographicException(SR.Cryptography_PasswordDerivedBytes_InvalidAlgorithm); 26throw new CryptographicException(SR.Cryptography_PasswordDerivedBytes_InvalidAlgorithm); 29throw new CryptographicException(SR.Cryptography_PasswordDerivedBytes_InvalidIV);
System\Security\Cryptography\PKCS1MaskGenerationMethod.cs (1)
33throw new CryptographicException(SR.Format(SR.Cryptography_UnknownHashAlgorithm, _hashNameValue));
System\Security\Cryptography\RC2.cs (4)
45throw new CryptographicException(SR.Cryptography_RC2_EKSKS); 63throw new CryptographicException(SR.Cryptography_RC2_EKSKS); 67throw new CryptographicException(SR.Cryptography_RC2_EKS40); 73throw new CryptographicException(SR.Cryptography_InvalidKeySize);
System\Security\Cryptography\RC2CryptoServiceProvider.Windows.cs (1)
103throw new CryptographicException(SR.Cryptography_InvalidIVSize);
System\Security\Cryptography\RC2Implementation.cs (3)
188throw new CryptographicException(SR.Format(SR.Cryptography_CipherModeNotSupported, CipherMode.CFB)); 199throw new CryptographicException(SR.Format(SR.Cryptography_CipherModeNotSupported, CipherMode.CFB)); 205throw new CryptographicException(SR.Format(SR.Cryptography_CipherModeFeedbackNotSupported, feedback, CipherMode.CFB));
System\Security\Cryptography\Rfc2898DeriveBytes.cs (3)
251throw new CryptographicException(SR.Cryptography_HashAlgorithmNameNullOrEmpty); 263throw new CryptographicException(SR.Format(SR.Cryptography_UnknownHashAlgorithm, hashAlgorithm.Name)); 287throw new CryptographicException(SR.Cryptography_ExceedKdfExtractLimit);
System\Security\Cryptography\Rfc2898DeriveBytes.OneShot.cs (1)
348throw new CryptographicException(SR.Format(SR.Cryptography_UnknownHashAlgorithm, hashAlgorithmName));
System\Security\Cryptography\RijndaelImplementation.cs (1)
43throw new CryptographicException(SR.Cryptography_Rijndael_BlockSize);
System\Security\Cryptography\RijndaelManaged.cs (1)
39throw new CryptographicException(SR.Cryptography_Rijndael_BlockSize);
System\Security\Cryptography\RSA.cs (3)
80throw new CryptographicException(SR.Cryptography_InvalidKeySize); 1398throw new CryptographicException(SR.Argument_DestinationTooShort); 1417throw new CryptographicException(SR.Argument_DestinationTooShort);
System\Security\Cryptography\RSA.Xml.cs (1)
19throw new CryptographicException(
System\Security\Cryptography\RSABCrypt.cs (8)
192throw new CryptographicException(SR.Cryptography_RSA_DecryptWrongSize); 210throw new CryptographicException(SR.Cryptography_UnsupportedPaddingMode); 237throw new CryptographicException( 255throw new CryptographicException(SR.Cryptography_UnsupportedPaddingMode); 274throw new CryptographicException(SR.Cryptography_SignHash_WrongSize); 301throw new CryptographicException(SR.Cryptography_UnsupportedPaddingMode); 351throw new CryptographicException(SR.Cryptography_UnsupportedPaddingMode); 439throw new CryptographicException(SR.Cryptography_CSP_NoPrivateKey);
System\Security\Cryptography\RSACryptoServiceProvider.Windows.cs (3)
462throw new CryptographicException(SR.Cryptography_CSP_NoPrivateKey); 624throw new CryptographicException(SR.Cryptography_RSA_DecryptWrongSize); 684return new CryptographicException(SR.Cryptography_InvalidPaddingMode);
System\Security\Cryptography\SymmetricAlgorithm.cs (14)
36throw new CryptographicException(SR.Cryptography_InvalidFeedbackSize); 52throw new CryptographicException(SR.Cryptography_InvalidBlockSize); 76throw new CryptographicException(SR.Cryptography_InvalidIVSize); 97throw new CryptographicException(SR.Cryptography_InvalidKeySize); 115throw new CryptographicException(SR.Cryptography_InvalidKeySize); 150throw new CryptographicException(SR.Cryptography_InvalidCipherMode); 166throw new CryptographicException(SR.Cryptography_InvalidPaddingMode); 232throw new CryptographicException(SR.Cryptography_InvalidKeySize); 531throw new CryptographicException(SR.Argument_DestinationTooShort); 651throw new CryptographicException(SR.Format(SR.Cryptography_EncryptedIncorrectLength, nameof(TryEncryptEcbCore))); 781throw new CryptographicException(SR.Argument_DestinationTooShort); 938throw new CryptographicException(SR.Format(SR.Cryptography_EncryptedIncorrectLength, nameof(TryEncryptCbcCore))); 1132throw new CryptographicException(SR.Argument_DestinationTooShort); 1374throw new CryptographicException(SR.Format(SR.Cryptography_EncryptedIncorrectLength, nameof(TryEncryptCfbCore)));
System\Security\Cryptography\SymmetricPadding.cs (11)
21throw new CryptographicException(SR.Cryptography_PartialBlock); 32throw new CryptographicException(SR.Cryptography_UnknownPaddingMode); 45throw new CryptographicException(SR.Cryptography_PartialBlock); 128throw new CryptographicException(SR.Cryptography_UnknownPaddingMode); 146throw new CryptographicException(SR.Cryptography_UnknownPaddingMode); 163throw new CryptographicException(SR.Cryptography_InvalidPadding); 169throw new CryptographicException(SR.Cryptography_InvalidPadding); 180throw new CryptographicException(SR.Cryptography_InvalidPadding); 191throw new CryptographicException(SR.Cryptography_InvalidPadding); 197throw new CryptographicException(SR.Cryptography_InvalidPadding); 210throw new CryptographicException(SR.Cryptography_UnknownPaddingMode);
System\Security\Cryptography\TripleDES.cs (3)
57throw new CryptographicException(SR.Format(SR.Cryptography_InvalidKey_Weak, "TripleDES")); 66throw new CryptographicException(SR.Cryptography_InvalidKeySize); // .NET Framework compat: Strange exception for a null value, but this is what we threw in classic CLR. 69throw new CryptographicException(SR.Cryptography_InvalidKeySize);
System\Security\Cryptography\TripleDesImplementation.cs (1)
234throw new CryptographicException(SR.Format(SR.Cryptography_CipherModeFeedbackNotSupported, feedback, CipherMode.CFB));
System\Security\Cryptography\UniversalCryptoDecryptor.cs (1)
72throw new CryptographicException(SR.Cryptography_PartialBlock);
System\Security\Cryptography\UniversalCryptoOneShot.cs (2)
21throw new CryptographicException(SR.Cryptography_PartialBlock); 29throw new CryptographicException(SR.Cryptography_InvalidPadding);
System\Security\Cryptography\X509Certificates\Asn1\CertificationRequestInfoAsn.xml.cs (1)
239throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
System\Security\Cryptography\X509Certificates\Asn1\TbsCertificateAsn.manual.cs (2)
41throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 48throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
System\Security\Cryptography\X509Certificates\Asn1\TimeAsn.xml.cs (1)
122throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
System\Security\Cryptography\X509Certificates\CertificateHelpers.Windows.cs (1)
195throw new CryptographicException(SR.Format(SR.Cryptography_InvalidHandle, nameof(handle)));
System\Security\Cryptography\X509Certificates\CertificateRequest.Load.cs (9)
79throw new CryptographicException( 163throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 170throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 178throw new CryptographicException( 194throw new CryptographicException(SR.Cryptography_CertReq_SignatureVerificationFailed); 214throw new CryptographicException( 227throw new CryptographicException( 237throw new CryptographicException(SR.Cryptography_CertReq_Load_DuplicateExtensionRequests); 286throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
System\Security\Cryptography\X509Certificates\CertificateRevocationListBuilder.cs (1)
317throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
System\Security\Cryptography\X509Certificates\CertificateRevocationListBuilder.Load.cs (5)
54throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 103throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 119throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 163throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 289throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
System\Security\Cryptography\X509Certificates\FindPal.cs (3)
155throw new CryptographicException(SR.Cryptography_X509_InvalidFindType); 167throw new CryptographicException(SR.Cryptography_X509_InvalidFindValue); 205throw new CryptographicException(SR.Cryptography_X509_InvalidFindValue);
System\Security\Cryptography\X509Certificates\RSAPssX509SignatureGenerator.cs (1)
32throw new CryptographicException(SR.Cryptography_InvalidPaddingMode);
System\Security\Cryptography\X509Certificates\StorePal.Windows.cs (1)
98throw new CryptographicException(SR.Cryptography_X509_StoreNotOpen);
System\Security\Cryptography\X509Certificates\StorePal.Windows.Export.cs (1)
87throw new CryptographicException(SR.Cryptography_X509_InvalidContentType);
System\Security\Cryptography\X509Certificates\SubjectAlternativeNameBuilder.cs (1)
115throw new CryptographicException(SR.Cryptography_Invalid_IA5String);
System\Security\Cryptography\X509Certificates\X500DirectoryStringHelper.cs (4)
16throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 33throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 43throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 60throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
System\Security\Cryptography\X509Certificates\X509AuthorityKeyIdentifierExtension.cs (1)
474throw new CryptographicException(SR.Cryptography_X509_AKID_NoSKID);
System\Security\Cryptography\X509Certificates\X509Certificate.cs (2)
727throw new CryptographicException(SR.Format(SR.Cryptography_InvalidHandle, "m_safeCertContext")); // Keeping "m_safeCertContext" string for backward compat sake. 767throw new CryptographicException(SR.Cryptography_X509_InvalidContentType);
System\Security\Cryptography\X509Certificates\X509Certificate2.cs (11)
1394_ => throw new CryptographicException(SR.Format(SR.Cryptography_UnknownKeyAlgorithm, keyAlgorithm)), 1482_ => throw new CryptographicException(SR.Format(SR.Cryptography_UnknownKeyAlgorithm, keyAlgorithm)), 1539throw new CryptographicException(SR.Cryptography_X509_NoPemCertificate); 1553throw new CryptographicException(SR.Cryptography_X509_NoPemCertificate); 1563throw new CryptographicException(SR.Cryptography_X509_NoPemCertificate); 1737throw new CryptographicException(SR.Cryptography_X509_TooManySANs); 1909throw new CryptographicException(SR.Cryptography_X509_NoOrMismatchedPemKey); 1956throw new CryptographicException(SR.Cryptography_X509_NoOrMismatchedPemKey); 2057throw new CryptographicException(SR.Cryptography_X509_NoOrMismatchedPemKey); 2135throw new CryptographicException(SR.Cryptography_X509_NoOrMismatchedPemKey); 2220throw new CryptographicException(SR.Cryptography_X509_NoOrMismatchedPemKey);
System\Security\Cryptography\X509Certificates\X509Certificate2Collection.cs (4)
456throw new CryptographicException(SR.Cryptography_X509_NoPemCertificate); 468throw new CryptographicException(SR.Cryptography_X509_NoPemCertificate); 503throw new CryptographicException(SR.Cryptography_X509_ExportFailed); 530throw new CryptographicException(SR.Cryptography_X509_ExportFailed);
System\Security\Cryptography\X509Certificates\X509CertificateLoader.Windows.cs (1)
135throw new CryptographicException(SR.Cryptography_Pfx_NoCertificates);
System\Security\Cryptography\X509Certificates\X509Chain.cs (3)
106throw new CryptographicException(SR.Cryptography_CustomTrustCertsInSystemMode); 112throw new CryptographicException(SR.Cryptography_InvalidTrustCertificate); 187throw new CryptographicException(SR.Cryptography_X509_ChainBuildingFailed);
System\Security\Cryptography\X509Certificates\X509Store.cs (3)
90throw new CryptographicException(SR.Cryptography_X509_StoreNotOpen); 131throw new CryptographicException(SR.Cryptography_X509_StoreNotOpen); 169throw new CryptographicException(SR.Cryptography_X509_StoreNotOpen);
System\Security\Cryptography\X509Certificates\X509SubjectAlternativeNameExtension.cs (1)
132throw new CryptographicException(
System\Security\Cryptography\X509Certificates\X509SubjectKeyIdentifierExtension.cs (1)
114throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
System.Security.Cryptography.Cose (33)
System\Security\Cryptography\Cose\CoseHelpers.cs (3)
180=> throw new CryptographicException(SR.Format(SR.Sign1UnknownCoseAlgorithm, alg)); 183=> throw new CryptographicException(SR.Format(SR.Sign1UnknownCoseAlgorithm, BigInteger.MinusOne - new BigInteger(alg))); 193throw new CryptographicException(SR.Sign1VerifyAlgIsRequired);
System\Security\Cryptography\Cose\CoseKey.cs (9)
78_ => throw new CryptographicException(SR.Format(SR.Sign1UnknownCoseAlgorithm, untrustedAlgorithm)) 91_ => throw new CryptographicException(SR.Format(SR.Sign1UnknownCoseAlgorithm, untrustedAlgorithm)) 102_ => throw new CryptographicException(SR.Format(SR.Sign1UnknownCoseAlgorithm, untrustedAlgorithm)) 106=> key.Algorithm.Name == expected.Name ? new CoseKey(key) : throw new CryptographicException(SR.Format(SR.Sign1UnknownCoseAlgorithm, untrustedAlgorithm)); 119throw new CryptographicException(SR.Format(SR.Sign1UnknownCoseAlgorithm, alg)); 144throw new CryptographicException(SR.Format(SR.Sign1UnknownCoseAlgorithm, alg)); 168_ => throw new CryptographicException(SR.Format(SR.Sign1UnknownCoseAlgorithm, algString)) 186throw new CryptographicException(SR.Format(SR.Sign1UnsupportedKey, KeyType.ToString())); 211throw new CryptographicException(SR.Format(SR.Sign1UnsupportedKey, KeyType.ToString()));
System\Security\Cryptography\Cose\CoseMessage.cs (17)
127throw new CryptographicException(SR.Format(SR.DecodeSign1IncorrectTag, tag)); 134throw new CryptographicException(SR.Format(SR.DecodeErrorWhileDecoding, SR.DecodeMessageContainedTrailingData)); 143throw new CryptographicException(SR.Format(SR.DecodeErrorWhileDecoding, SR.DecodeSign1ArrayLengthMustBeFour)); 154throw new CryptographicException(SR.Sign1SignHeaderDuplicateLabels); 212throw new CryptographicException(SR.Format(SR.DecodeMultiSignIncorrectTag, tag)); 219throw new CryptographicException(SR.Format(SR.DecodeErrorWhileDecoding, SR.DecodeMessageContainedTrailingData)); 228throw new CryptographicException(SR.Format(SR.DecodeErrorWhileDecoding, SR.DecodeMultiSignArrayLengthMustBeFour)); 239throw new CryptographicException(SR.Sign1SignHeaderDuplicateLabels); 278throw new CryptographicException(SR.Format(SR.CriticalHeaderMissing, labelName)); 285throw new CryptographicException(SR.Format(SR.DecodeErrorWhileDecoding, SR.DecodeSign1EncodedProtectedMapIncorrect)); 312_ => throw new CryptographicException(SR.Format(SR.DecodeErrorWhileDecoding, SR.DecodeSign1MapLabelWasIncorrect)) 348throw new CryptographicException(SR.Format(SR.DecodeErrorWhileDecoding, SR.DecodeSign1PayloadWasIncorrect)); 371throw new CryptographicException(SR.Format(SR.DecodeErrorWhileDecoding, SR.MultiSignMessageMustCarryAtLeastOneSignature)); 385throw new CryptographicException(SR.Format(SR.DecodeErrorWhileDecoding, SR.DecodeCoseSignatureMustBeArrayOfThree)); 396throw new CryptographicException(SR.Sign1SignHeaderDuplicateLabels); 607_ => throw new CryptographicException(SR.CriticalHeadersLabelWasIncorrect) 619throw new CryptographicException(SR.CriticalHeadersMustBeArrayOfAtLeastOne);
System\Security\Cryptography\Cose\CoseSign1Message.cs (2)
1036throw new CryptographicException(SR.Sign1VerifyAlgHeaderWasIncorrect); 1048throw new CryptographicException(SR.Format(SR.Sign1VerifyAlgDoesNotMatchKeyAlgorithm, algorithm, key.Algorithm));
System\Security\Cryptography\Cose\CoseSignature.cs (2)
686throw new CryptographicException(SR.Sign1VerifyAlgHeaderWasIncorrect); 698throw new CryptographicException(SR.Format(SR.Sign1VerifyAlgDoesNotMatchKeyAlgorithm, algorithm, key.Algorithm));
System.Security.Cryptography.Pkcs (137)
Internal\Cryptography\Pal\AnyOS\ManagedPal.Asn.cs (1)
30throw new CryptographicException(SR.Cryptography_Cms_InvalidMessageType);
Internal\Cryptography\Pal\AnyOS\ManagedPal.cs (4)
59throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 105throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 120throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 130throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
Internal\Cryptography\Pal\AnyOS\ManagedPal.Decode.cs (1)
89throw new CryptographicException(SR.Cryptography_Cms_InvalidMessageType);
Internal\Cryptography\Pal\AnyOS\ManagedPal.Decrypt.cs (1)
51exception = new CryptographicException(SR.Cryptography_Cms_Ktri_RSARequired);
Internal\Cryptography\Pal\AnyOS\ManagedPal.Exceptions.cs (2)
13return new CryptographicException(SR.Cryptography_Cms_RecipientNotFound); 34return new CryptographicException(SR.Cryptography_Cms_InvalidMessageType);
Internal\Cryptography\Pal\AnyOS\ManagedPal.KeyTrans.cs (3)
47exception = new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 169throw new CryptographicException(SR.Cryptography_Cms_UnknownAlgorithm); 189exception = new CryptographicException(SR.Cryptography_Cms_Signing_RequiresPrivateKey);
Internal\Cryptography\Pal\Windows\DecryptorPalWindows.Decrypt.cs (2)
35exception = new CryptographicException(SR.Cryptography_Cms_Ktri_RSARequired); 246return new CryptographicException(SR.Format(SR.Cryptography_Cms_Invalid_Originator_Identifier_Choice, originatorChoice));
Internal\Cryptography\Pal\Windows\HelpersWindows.cs (2)
215throw new CryptographicException(SR.Format(SR.Cryptography_Cms_Invalid_Subject_Identifier_Type, certId.dwIdChoice)); 237throw new CryptographicException(SR.Format(SR.Cryptography_Cms_Invalid_Subject_Identifier_Type, subjectIdentifierType));
Internal\Cryptography\Pal\Windows\KeyAgreeRecipientInfoPalWindows.cs (1)
104_ => throw new CryptographicException(SR.Format(SR.Cryptography_Cms_Invalid_Originator_Identifier_Choice, originatorChoice)),
Internal\Cryptography\Pal\Windows\PkcsPalWindows.Encrypt.cs (1)
73throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
Internal\Cryptography\PkcsHelpers.cs (4)
347exception = new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 360exception = new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 368exception = new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 377exception = new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\Internal\Cryptography\PkcsHelpers.cs (7)
70throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 91throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 120throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 135throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 185throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 200throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 326throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Asn1\AttributeAsn.xml.cs (1)
204throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Asn1\Pkcs12\PfxAsn.manual.cs (2)
49throw new CryptographicException( 55throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Asn1\PssParamsAsn.manual.cs (4)
15throw new CryptographicException(SR.Cryptography_Pkcs_InvalidSignatureParameters); 27throw new CryptographicException(SR.Cryptography_Pkcs_InvalidSignatureParameters); 37throw new CryptographicException( 53throw new CryptographicException(
src\runtime\src\libraries\Common\src\System\Security\Cryptography\CryptographicAttributeObjectCollection.cs (1)
63throw new CryptographicException(SR.Cryptography_Pkcs9_MultipleSigningTimeNotAllowed);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\CryptoThrowHelper.Windows.cs (1)
29return new CryptographicException(message)
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Helpers.cs (3)
138throw new CryptographicException(SR.Format(SR.Cryptography_UnknownHashAlgorithm, hashOid)); 230throw new CryptographicException( 272throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\KeyFormatHelper.cs (4)
53throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey); 84throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey); 126throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey); 154throw new CryptographicException(SR.Cryptography_NotValidPublicOrPrivateKey);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\KeyFormatHelper.Encrypted.cs (3)
173throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 417throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 453throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\PasswordBasedEncryption.cs (25)
107throw new CryptographicException( 170throw new CryptographicException( 270throw new CryptographicException( 302throw new CryptographicException( 545throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 552throw new CryptographicException( 604throw new CryptographicException( 633throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 656throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 674throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 681throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 692throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 711throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 733throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 749throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 768throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 777throw new CryptographicException( 786throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 795_ => throw new CryptographicException( 806throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 857throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 864throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 869throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 908throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 1137throw new CryptographicException(SR.Argument_InvalidValue);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Pkcs\Pkcs12CertBag.cs (2)
95throw new CryptographicException(SR.Argument_InvalidOidValue); 112throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Pkcs\Pkcs12Info.cs (3)
66throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 98throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 104throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Pkcs\Pkcs12SafeContents.cs (4)
70throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 231throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 239throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 244throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Pkcs\Pkcs8PrivateKeyInfo.cs (2)
192throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 223throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
System\Security\Cryptography\Pkcs\CmsRecipient.cs (2)
59throw new CryptographicException(SR.Format(SR.Cryptography_Cms_Invalid_Subject_Identifier_Type, recipientIdentifierType)); 83throw new CryptographicException(SR.Cryptography_Cms_Recipient_RSARequired_RSAPaddingModeSupplied);
System\Security\Cryptography\Pkcs\CmsSignature.DSA.cs (1)
58throw new CryptographicException(
System\Security\Cryptography\Pkcs\CmsSignature.ECDsa.cs (1)
60throw new CryptographicException(
System\Security\Cryptography\Pkcs\CmsSignature.MLDsa.cs (1)
49throw new CryptographicException(
System\Security\Cryptography\Pkcs\CmsSignature.RSA.cs (4)
61throw new CryptographicException( 206throw new CryptographicException(SR.Cryptography_Pkcs_InvalidSignatureParameters); 311throw new CryptographicException(SR.Cryptography_Pkcs_PssParametersMissing); 321throw new CryptographicException(
System\Security\Cryptography\Pkcs\CmsSignature.SlhDsa.cs (1)
60throw new CryptographicException(
System\Security\Cryptography\Pkcs\CmsSigner.cs (4)
238throw new CryptographicException(SR.Cryptography_Cms_Signing_RequiresPrivateKey); 405throw new CryptographicException(SR.Cryptography_Cms_CannotDetermineSignatureAlgorithm); 429throw new CryptographicException(SR.Cryptography_Cms_CannotDetermineSignatureAlgorithm); 474throw new CryptographicException(SR.Cryptography_Cms_IncompleteCertChain);
System\Security\Cryptography\Pkcs\Rfc3161TimestampRequest.cs (7)
119throw new CryptographicException( 134throw new CryptographicException(SR.Cryptography_TimestampReq_BadResponse); 396throw new CryptographicException(SR.Cryptography_BadHashValue); 409throw new CryptographicException(SR.Cryptography_TimestampReq_BadResponse); 432throw new CryptographicException(SR.Cryptography_TimestampReq_BadNonce); 453throw new CryptographicException(SR.Cryptography_TimestampReq_NoCertFound); 468throw new CryptographicException(SR.Cryptography_TimestampReq_UnexpectedCertFound);
System\Security\Cryptography\Pkcs\Rfc3161TimestampTokenInfo.cs (2)
67throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding); 291throw new CryptographicException(SR.Cryptography_Der_Invalid_Encoding);
System\Security\Cryptography\Pkcs\SignedCms.cs (8)
221throw new CryptographicException(SR.Cryptography_Cms_InvalidMessageType); 298throw new CryptographicException(SR.Cryptography_Cms_Sign_Empty_Content); 307throw new CryptographicException(SR.Cryptography_Cms_Sign_No_Signature_First_Signer); 403throw new CryptographicException(SR.Cryptography_Cms_SignerNotFound); 610throw new CryptographicException(SR.Cryptography_Cms_NoSignerAtIndex); 636throw new CryptographicException(SR.Cryptography_Cms_NoSignerAtIndex); 670throw new CryptographicException(SR.Cryptography_Cms_CertificateAlreadyInCollection); 719throw new CryptographicException(SR.Cryptography_Cms_NoCertificateFound);
System\Security\Cryptography\Pkcs\SignerInfo.cs (22)
112throw new CryptographicException(SR.Cryptography_Cms_SignerNotFound); 130throw new CryptographicException(SR.Cryptography_Cms_NoSignerAtIndex); 138throw new CryptographicException(SR.Cryptography_Cms_NoSignerAtIndex); 174throw new CryptographicException(SR.Cryptography_Cms_NoSignerAtIndex); 243throw new CryptographicException(SR.Cryptography_Cms_NoAttributeFound); 295throw new CryptographicException(SR.Cryptography_Cms_NoCounterCounterSigner); 305throw new CryptographicException(SR.Cryptography_Cms_SignerNotFound); 363throw new CryptographicException(SR.Cryptography_Cms_SignerNotFound); 371throw new CryptographicException(SR.Cryptography_Cms_NoSignerAtIndex); 404throw new CryptographicException(SR.Cryptography_Cms_NoSignerAtIndex); 435throw new CryptographicException(SR.Cryptography_Cms_SignerNotFound); 443throw new CryptographicException(SR.Cryptography_Cms_SignerNotFound); 464throw new CryptographicException(SR.Cryptography_Cms_SignerNotFound); 475throw new CryptographicException(SR.Cryptography_Pkcs_InvalidSignatureParameters); 480throw new CryptographicException(SR.Cryptography_BadSignature); 643throw new CryptographicException(SR.Cryptography_BadHashValue); 650throw new CryptographicException(SR.Cryptography_BadHashValue); 665throw new CryptographicException(SR.Cryptography_Cms_MissingAuthenticatedAttribute); 731throw new CryptographicException(SR.Cryptography_Cms_MissingAuthenticatedAttribute); 781throw new CryptographicException(SR.Cryptography_Cms_MissingAuthenticatedAttribute); 859throw new CryptographicException(SR.Cryptography_BadSignature); 904throw new CryptographicException(SR.Cryptography_Cms_WrongKeyUsage);
System.Security.Cryptography.ProtectedData (2)
src\runtime\src\libraries\Common\src\System\Security\Cryptography\CryptoThrowHelper.Windows.cs (1)
29return new CryptographicException(message)
System\Security\Cryptography\ProtectedData.cs (1)
368throw new CryptographicException(SR.Cryptography_DpApi_ProfileMayNotBeLoaded);
System.Security.Cryptography.Xml (122)
System\Security\Cryptography\Xml\CanonicalizationDispatcher.cs (2)
21throw new CryptographicException(SR.Cryptography_Xml_MaxDepthExceeded); 58throw new CryptographicException(SR.Cryptography_Xml_MaxDepthExceeded);
System\Security\Cryptography\Xml\CipherData.cs (5)
45throw new CryptographicException(SR.Cryptography_Xml_CipherValueElementRequired); 61throw new CryptographicException(SR.Cryptography_Xml_CipherValueElementRequired); 91throw new CryptographicException(SR.Cryptography_Xml_CipherValueElementRequired); 111throw new CryptographicException(SR.Cryptography_Xml_CipherValueElementRequired); 121throw new CryptographicException(SR.Cryptography_Xml_CipherValueElementRequired);
System\Security\Cryptography\Xml\CipherReference.cs (2)
55throw new CryptographicException(SR.Cryptography_Xml_ReferenceTypeRequired); 77Uri = uri ?? throw new CryptographicException(SR.Cryptography_Xml_UriRequired);
System\Security\Cryptography\Xml\DSAKeyValue.cs (5)
155throw new CryptographicException(SR.Format(SR.WrongRootElement, KeyValueElementName, SignedXml.XmlDsigNamespaceUrl)); 165throw new CryptographicException(SR.Format(SR.MustContainChildElement, KeyValueElementName, DSAKeyValueElementName)); 170throw new CryptographicException(SR.Format(SR.ElementMissing, YElementName)); 176throw new CryptographicException(SR.Format(SR.ElementCombinationMissing, PElementName, QElementName)); 185throw new CryptographicException(SR.Format(SR.ElementCombinationMissing, SeedElementName, PgenCounterElementName));
System\Security\Cryptography\Xml\EncryptedData.cs (2)
45throw new CryptographicException(SR.Cryptography_Xml_MissingCipherData); 110throw new CryptographicException(SR.Cryptography_Xml_MissingCipherData);
System\Security\Cryptography\Xml\EncryptedKey.cs (2)
81throw new CryptographicException(SR.Cryptography_Xml_MissingCipherData); 183throw new CryptographicException(SR.Cryptography_Xml_MissingCipherData);
System\Security\Cryptography\Xml\EncryptedReference.cs (1)
90throw new CryptographicException(SR.Cryptography_Xml_ReferenceTypeRequired);
System\Security\Cryptography\Xml\EncryptedType.cs (1)
85throw new CryptographicException(SR.Cryptography_Xml_MaxDepthExceeded);
System\Security\Cryptography\Xml\EncryptedXml.cs (22)
215throw new CryptographicException(SR.Cryptography_Xml_UriNotSupported); 225throw new CryptographicException(SR.Cryptography_Xml_UriNotSupported); 229throw new CryptographicException(SR.Cryptography_Xml_NotSupportedCryptographicTransform); 241throw new CryptographicException(SR.Cryptography_Xml_UriNotSupported); 248throw new CryptographicException(SR.Cryptography_Xml_UriNotSupported); 252throw new CryptographicException(SR.Cryptography_Xml_NotSupportedCryptographicTransform); 278throw new CryptographicException(SR.Cryptography_Xml_MissingCipherData); 301throw new CryptographicException(SR.Cryptography_Xml_MissingAlgorithm); 317throw new CryptographicException(SR.Cryptography_Xml_UriNotSupported); 394throw new CryptographicException(SR.Cryptography_Xml_MissingAlgorithm); 399throw new CryptographicException(SR.Cryptography_Xml_MissingDecryptionKey); 404throw new CryptographicException(SR.Cryptography_Xml_MissingAlgorithm); 442throw new CryptographicException(SR.Cryptography_Xml_MissingAlgorithm); 466throw new CryptographicException(SR.Cryptography_Xml_MissingAlgorithm); 513throw new CryptographicException(SR.Cryptography_Xml_MissingAlgorithm); 518throw new CryptographicException(SR.Cryptography_Xml_MissingAlgorithm); 540throw new CryptographicException(SR.Cryptography_Xml_NotSupportedCryptographicTransform); 603throw new CryptographicException(SR.Cryptography_Xml_MissingEncryptionKey); 646throw new CryptographicException(SR.Cryptography_Xml_NotSupportedCryptographicTransform); 686throw new CryptographicException(SR.Cryptography_Xml_MissingDecryptionKey); 900throw new CryptographicException(SR.Cryptography_Xml_NotSupportedCryptographicTransform); 942throw new CryptographicException(SR.Cryptography_Xml_NotSupportedCryptographicTransform);
System\Security\Cryptography\Xml\EncryptionProperty.cs (3)
24throw new CryptographicException(SR.Cryptography_Xml_InvalidEncryptionProperty); 49throw new CryptographicException(SR.Cryptography_Xml_InvalidEncryptionProperty); 84throw new CryptographicException(SR.Cryptography_Xml_InvalidEncryptionProperty);
System\Security\Cryptography\Xml\KeyInfoX509Data.cs (2)
68throw new CryptographicException(SR.Cryptography_Partial_Chain); 89throw new CryptographicException(SR.Cryptography_Partial_Chain);
System\Security\Cryptography\Xml\Reference.cs (8)
187throw new CryptographicException(SR.Cryptography_Xml_DigestMethodRequired); 196throw new CryptographicException(SR.Cryptography_Xml_DigestValueRequired); 255throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform); 260throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform); 361throw new CryptographicException(SR.Cryptography_Xml_CreateHashAlgorithmFailed); 397throw new CryptographicException(SR.Format(SR.Cryptography_Xml_SelfReferenceRequiresContext, _uri)); 413throw new CryptographicException(SR.Format(SR.Cryptography_Xml_SelfReferenceRequiresContext, _uri)); 446throw new CryptographicException(SR.Cryptography_Xml_InvalidReference);
System\Security\Cryptography\Xml\RSAKeyValue.cs (2)
110throw new CryptographicException(SR.Format(SR.WrongRootElement, KeyValueElementName, SignedXml.XmlDsigNamespaceUrl)); 120throw new CryptographicException(SR.Format(SR.MustContainChildElement, KeyValueElementName, RSAKeyValueElementName));
System\Security\Cryptography\Xml\Signature.cs (2)
101throw new CryptographicException(SR.Cryptography_Xml_SignedInfoRequired); 107throw new CryptographicException(SR.Cryptography_Xml_SignatureValueRequired);
System\Security\Cryptography\Xml\SignedInfo.cs (3)
103throw new CryptographicException(SR.Format(SR.Cryptography_Xml_CreateTransformFailed, CanonicalizationMethod)); 177throw new CryptographicException(SR.Cryptography_Xml_SignatureMethodRequired); 194throw new CryptographicException(SR.Cryptography_Xml_ReferenceElementRequired);
System\Security\Cryptography\Xml\SignedXml.cs (18)
391throw new CryptographicException(SR.Cryptography_Xml_LoadKeyFailed); 407throw new CryptographicException(SR.Cryptography_Xml_CreatedKeyFailed); 414throw new CryptographicException(SR.Cryptography_Xml_SignatureDescriptionNotCreated); 417throw new CryptographicException(SR.Cryptography_Xml_CreateHashAlgorithmFailed); 435throw new CryptographicException(SR.Cryptography_Xml_SignatureMethodKeyMismatch); 444throw new CryptographicException(SR.Cryptography_Xml_InvalidSignatureLength); 446throw new CryptographicException(SR.Cryptography_Xml_InvalidSignatureLength2); 457_ => throw new CryptographicException(SR.Cryptography_Xml_SignatureMethodKeyMismatch), 473throw new CryptographicException(SR.Cryptography_Xml_KeyInfoRequired); 587throw new CryptographicException( 843throw new CryptographicException(SR.Cryptography_Xml_InvalidReference); 1016throw new CryptographicException(SR.Cryptography_Xml_SignatureDescriptionNotCreated); 1025throw new CryptographicException(SR.Cryptography_Xml_CreateHashAlgorithmFailed); 1053throw new CryptographicException(SR.Cryptography_Xml_InvalidSignatureLength); 1055throw new CryptographicException(SR.Cryptography_Xml_InvalidSignatureLength2); 1057throw new CryptographicException(SR.Cryptography_Xml_SignatureValueRequired); 1059throw new CryptographicException(SR.Cryptography_Xml_InvalidSignatureLength); 1095throw new CryptographicException(SR.Cryptography_Xml_InvalidReference);
System\Security\Cryptography\Xml\SymmetricKeyWrap.cs (6)
76throw new CryptographicException(SR.Cryptography_Xml_KW_BadKeySize); 108throw new CryptographicException(SR.Cryptography_Xml_BadWrappedKeySize); 126throw new CryptographicException(SR.Cryptography_Xml_KW_BadKeySize); 188throw new CryptographicException(SR.Cryptography_Xml_KW_BadKeySize); 210throw new CryptographicException(SR.Cryptography_Xml_BadWrappedKeySize); 241throw new CryptographicException(SR.Cryptography_Xml_BadWrappedKeySize);
System\Security\Cryptography\Xml\TransformChain.cs (6)
97throw new CryptographicException(SR.Cryptography_Xml_TransformIncorrectInputType); 114throw new CryptographicException(SR.Cryptography_Xml_TransformIncorrectInputType); 131throw new CryptographicException(SR.Cryptography_Xml_TransformIncorrectInputType); 134throw new CryptographicException(SR.Cryptography_Xml_TransformIncorrectInputType); 155throw new CryptographicException(SR.Cryptography_Xml_TransformIncorrectInputType); 198throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform);
System\Security\Cryptography\Xml\Utils.cs (3)
321throw new CryptographicException(SR.Cryptography_Xml_InvalidReference); 333throw new CryptographicException(SR.Cryptography_Xml_UriRequired); 343throw new CryptographicException(SR.Cryptography_Xml_InvalidReference);
System\Security\Cryptography\Xml\XmlDecryptionTransform.cs (7)
90throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform); 102throw new CryptographicException(SR.Cryptography_Xml_UriRequired); 105throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform); 112throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform); 208throw new CryptographicException(SR.Cryptography_Xml_MissingDecryptionKey); 240throw new CryptographicException(SR.Cryptography_Xml_MaxDecryptableDataElementsExceeded); 258throw new CryptographicException(SR.Cryptography_Xml_MaxDepthExceeded);
System\Security\Cryptography\Xml\XmlDsigC14NTransform.cs (1)
40throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform);
System\Security\Cryptography\Xml\XmlDsigEnvelopedSignatureTransform.cs (4)
50throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform); 87throw new CryptographicException(SR.Cryptography_Xml_EnvelopedSignatureRequiresContext); 98throw new CryptographicException(SR.Cryptography_Xml_EnvelopedSignatureRequiresContext); 117throw new CryptographicException(SR.Cryptography_Xml_EnvelopedSignatureRequiresContext);
System\Security\Cryptography\Xml\XmlDsigExcC14NTransform.cs (2)
61throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform); 68throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform);
System\Security\Cryptography\Xml\XmlDsigXPathTransform.cs (4)
39throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform); 56throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform); 77throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform); 83throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform);
System\Security\Cryptography\Xml\XmlDsigXsltTransform.cs (3)
52throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform); 63throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform); 72throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform);
System\Security\Cryptography\Xml\XmlLicenseTransform.cs (6)
85throw new CryptographicException(SR.Cryptography_Xml_XrmlUnableToDecryptGrant); 132throw new CryptographicException(SR.Cryptography_Xml_UnknownTransform); 139throw new CryptographicException(SR.Cryptography_Xml_XrmlMissingContext); 155throw new CryptographicException(SR.Cryptography_Xml_XrmlMissingIssuer); 163throw new CryptographicException(SR.Cryptography_Xml_XrmlMissingLicence); 183throw new CryptographicException(SR.Cryptography_Xml_XrmlMissingIRelDecryptor);
System.ServiceModel.Primitives (3)
System\IdentityModel\Tokens\X509AsymmetricSecurityKey.cs (3)
211throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new CryptographicException(SRP.Format(SRP.UnsupportedAlgorithmForCryptoOperation, 261throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new CryptographicException(SRP.Format(SRP.UnsupportedAlgorithmForCryptoOperation, 336throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new CryptographicException(SRP.Format(SRP.UnsupportedAlgorithmForCryptoOperation,
System.Windows.Extensions (1)
System\Security\Cryptography\X509Certificates\X509Certificate2UI.cs (1)
50throw new CryptographicException(SR.Format(SR.Cryptography_InvalidHandle, nameof(safeCertContext)));