Open danmoseley opened 5 years ago
Correction, 0xC0000001 (STATUS_UNSUCCESSFUL) not an AV.
Oh, the joys of status codes. What's wrong? (UNSUCCESSFUL.) Where? Beats me.
Without a stable (or "try this in a loop 30 times") repro or a TTT trace it's hard to bring this up with Windows. Since it's not really actionable right now, marking as Future.
Windows.10.Amd64.ClientRS4.ES.Open-x64-Debug
Get Repro environment
Unhandled Exception of Type Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException
Message :
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack Trace :
at System.Security.Cryptography.RSACng.TryEncryptOrDecrypt(SafeNCryptKeyHandle key, ReadOnlySpan`1 input, Span`1 output, AsymmetricPaddingMode paddingMode, Void* paddingInfo, Boolean encrypt, Int32& bytesWritten) in /_/src/Common/src/System/Security/Cryptography/RSACng.EncryptDecrypt.cs:line 268
at System.Security.Cryptography.RSACng.TryEncryptOrDecrypt(ReadOnlySpan`1 data, Span`1 destination, RSAEncryptionPadding padding, Boolean encrypt, Int32& bytesWritten) in /_/src/Common/src/System/Security/Cryptography/RSACng.EncryptDecrypt.cs:line 205
at System.Security.Cryptography.RSACng.TryDecrypt(ReadOnlySpan`1 data, Span`1 destination, RSAEncryptionPadding padding, Int32& bytesWritten) in /_/src/Common/src/System/Security/Cryptography/RSACng.EncryptDecrypt.cs:line 38
at System.Security.Cryptography.Rsa.Tests.EncryptDecrypt_Span.<>c__DisplayClass1_0.<Decrypt>b__0(Byte[] dest) in /_/src/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/EncryptDecrypt.netcoreapp.cs:line 16
at System.Security.Cryptography.Rsa.Tests.EncryptDecrypt_Span.TryWithOutputArray(Func`2 func) in /_/src/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/EncryptDecrypt.netcoreapp.cs:line 23
at System.Security.Cryptography.Rsa.Tests.EncryptDecrypt_Span.Decrypt(RSA rsa, Byte[] data, RSAEncryptionPadding padding) in /_/src/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/EncryptDecrypt.netcoreapp.cs:line 16
at System.Security.Cryptography.Rsa.Tests.EncryptDecrypt.RsaCryptRoundtrip(RSAEncryptionPadding paddingMode, Boolean expectSuccess) in /_/src/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/EncryptDecrypt.cs:line 332
at System.Security.Cryptography.Rsa.Tests.EncryptDecrypt.RsaCryptRoundtrip_OaepSHA512() in /_/src/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/EncryptDecrypt.cs:line 314
We've hit this issue in several NuGet CI test runs.
Configuration: netcoreapp-Windows_NT-Debug-x64-(Windows.Nano.1809.Amd64.Open)windows.10.amd64.serverrs5.open@mcr.microsoft.com/dotnet-buildtools/prereqs:nanoserver-1809-helix-amd64-61052b7-20190723211353
System.Security.Cryptography.Rsa.Tests.EncryptDecrypt_Span.RsaCryptRoundtrip_OaepSHA1 [FAIL]
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack Trace:
/_/src/Common/src/System/Security/Cryptography/RSACng.EncryptDecrypt.cs(268,0): at System.Security.Cryptography.RSACng.TryEncryptOrDecrypt(SafeNCryptKeyHandle key, ReadOnlySpan`1 input, Span`1 output, AsymmetricPaddingMode paddingMode, Void* paddingInfo, Boolean encrypt, Int32& bytesWritten)
/_/src/Common/src/System/Security/Cryptography/RSACng.EncryptDecrypt.cs(205,0): at System.Security.Cryptography.RSACng.TryEncryptOrDecrypt(ReadOnlySpan`1 data, Span`1 destination, RSAEncryptionPadding padding, Boolean encrypt, Int32& bytesWritten)
/_/src/Common/src/System/Security/Cryptography/RSACng.EncryptDecrypt.cs(38,0): at System.Security.Cryptography.RSACng.TryDecrypt(ReadOnlySpan`1 data, Span`1 destination, RSAEncryptionPadding padding, Int32& bytesWritten)
/_/src/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/EncryptDecrypt.netcoreapp.cs(16,0): at System.Security.Cryptography.Rsa.Tests.EncryptDecrypt_Span.<>c__DisplayClass1_0.<Decrypt>b__0(Byte[] dest)
/_/src/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/EncryptDecrypt.netcoreapp.cs(23,0): at System.Security.Cryptography.Rsa.Tests.EncryptDecrypt_Span.TryWithOutputArray(Func`2 func)
/_/src/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/EncryptDecrypt.netcoreapp.cs(16,0): at System.Security.Cryptography.Rsa.Tests.EncryptDecrypt_Span.Decrypt(RSA rsa, Byte[] data, RSAEncryptionPadding padding)
/_/src/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/EncryptDecrypt.cs(332,0): at System.Security.Cryptography.Rsa.Tests.EncryptDecrypt.RsaCryptRoundtrip(RSAEncryptionPadding paddingMode, Boolean expectSuccess)
/_/src/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/EncryptDecrypt.cs(302,0): at System.Security.Cryptography.Rsa.Tests.EncryptDecrypt.RsaCryptRoundtrip_OaepSHA1()
@bartonjs can you please take a look? A dump is available.
@ViktorHofer I don't see a dump... the test simply failed.
Looking at history on the message over the past 90 days, it looks like one pops up every week or so (sometimes sooner); but there's no real trend (other than it's private key operations (decrypt, sign)).
I think I'm willing to do an experimental retry-once on this error and see if problems go away, now that there's longer to measure it and decide it didn't work or was otherwise a bad idea.
Oh I must have mixed two builds up, you are right, there's no dump :(
I think I'm willing to do an experimental retry-once on this error and see if problems go away
You mean retrying that operation with the RetryHelper?
You mean retrying that operation with the RetryHelper?
No. Making the product code call the Win32 function again if it returns STATUS_UNSUCCESSFUL.
Trying that out doesn't sound like a bad idea.
Sounds like we'll be reverting the retry, then, and that there's very little we can do about it.
Again here: https://dev.azure.com/dnceng/public/_build/results?buildId=725147&view=ms.vss-test-web.build-test-results-tab&runId=22467048&resultId=166891&paneView=debug in https://github.com/dotnet/runtime/pull/39101
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 41
at System.Security.Cryptography.RSAImplementation.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 82
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 175
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 153
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 690
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, Byte[] serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 577
at System.Security.Cryptography.X509Certificates.CertificateRequest.CreateSelfSigned(DateTimeOffset notBefore, DateTimeOffset notAfter) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 314
at System.Security.Cryptography.X509Certificates.Tests.CertificateCreation.CertificateRequestChainTests.CreateAndTestChain(AsymmetricAlgorithm rootPrivKey, AsymmetricAlgorithm intermed1PrivKey, AsymmetricAlgorithm intermed2PrivKey, AsymmetricAlgorithm leafPubKey) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/CertificateCreation/CertificateRequestChainTests.cs:line 391
at System.Security.Cryptography.X509Certificates.Tests.CertificateCreation.CertificateRequestChainTests.CreateChain_RSA() in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/CertificateCreation/CertificateRequestChainTests.cs:line 42
failed again in job: runtime-libraries outerloop 20200713.2
Error message
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 44
at System.Security.Cryptography.RSAImplementation.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 67
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 170
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 150
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 690
at System.Security.Cryptography.X509Certificates.CertificateRequest.CreateSelfSigned(DateTimeOffset notBefore, DateTimeOffset notAfter) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 337
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 919
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1269
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntity_RootRevocationOffline(PkiOptions pkiOptions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 644
@bartonjs Given this failure is occurring now, should it still be in milestone "Future"?
@BruceForstall There's nothing we can do about it, it's a problem in the OS (possibly resource exhaustion?).
failed again in job: runtime-libraries outerloop 20200819.2
failed test: System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeRoot(pkiOptions: IssuerRevocationViaOcsp | AllEndEntityRevocation | IssuerAuthorityHasDesignatedOcspResponder | RootAuthorityHasDesignatedOcspResponder)
net5.0-Windows_NT-Release-x64-CoreCLR_release-(Windows.Nano.1809.Amd64.Open)windows.10.amd64.serverrs5.open@mcr.microsoft.com/dotnet-buildtools/prereqs:nanoserver-1809-helix-amd64-08e8e40-20200107182504
Error message
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 44
at System.Security.Cryptography.RSAImplementation.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 98
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 170
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 150
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 692
at System.Security.Cryptography.X509Certificates.CertificateRequest.CreateSelfSigned(DateTimeOffset notBefore, DateTimeOffset notAfter) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 338
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 926
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1344
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.SimpleTest(PkiOptions pkiOptions, RunSimpleTest callback, String callerName, Boolean pkiOptionsInTestName) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1292
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeRoot(PkiOptions pkiOptions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 175
failed again in job: runtime-libraries outerloop 20200830.4
net5.0-Windows_NT-Release-x86-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
Error message
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 44
at System.Security.Cryptography.RSAImplementation.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 67
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 170
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 150
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 692
at System.Security.Cryptography.X509Certificates.CertificateRequest.CreateSelfSigned(DateTimeOffset notBefore, DateTimeOffset notAfter) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 337
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 926
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1344
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.SimpleTest(PkiOptions pkiOptions, RunSimpleTest callback, String callerName, Boolean pkiOptionsInTestName) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1292
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEverything(PkiOptions pkiOptions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 283
failed again in job: runtime-libraries-coreclr outerloop 20200909.3
failed test: System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeRoot(pkiOptions: AllRevocation | IssuerAuthorityHasDesignatedOcspResponder | RootAuthorityHasDesignatedOcspResponder)
net5.0-Windows_NT-Release-x86-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
Error message
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 44
at System.Security.Cryptography.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 67
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 170
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 150
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 692
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X509Certificate2 issuerCertificate, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 500
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.CreateCertificate(String subject, RSA publicKey, TimeSpan nestingBuffer, X509ExtensionCollection extensions, Boolean ocspResponder) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 287
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 926
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1344
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.SimpleTest(PkiOptions pkiOptions, RunSimpleTest callback, String callerName, Boolean pkiOptionsInTestName) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1292
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeRoot(PkiOptions pkiOptions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 175
Is it worth adding windows code owner what the cause might be for such a code? It may be familiar to them.
failed again in job: runtime-libraries-coreclr outerloop 20200926.4
failed test: System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEverything(pkiOptions: IssuerRevocationViaCrl | OcspEverywhere | IssuerAuthorityHasDesignatedOcspResponder)
net5.0-Windows_NT-Release-x64-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
Error message
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 44
at System.Security.Cryptography.RSAImplementation.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 98
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 172
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 152
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 692
at System.Security.Cryptography.X509Certificates.CertificateRequest.CreateSelfSigned(DateTimeOffset notBefore, DateTimeOffset notAfter) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 338
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 926
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1344
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.SimpleTest(PkiOptions pkiOptions, RunSimpleTest callback, String callerName, Boolean pkiOptionsInTestName) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1292
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEverything(PkiOptions pkiOptions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 283
failed again in job: runtime-libraries-coreclr outerloop 20201019.3
failed test: System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.NothingRevoked(pkiOptions: IssuerRevocationViaCrl | AllEndEntityRevocation)
net6.0-Windows_NT-Release-x64-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
Error message
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 44
at System.Security.Cryptography.RSAImplementation.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 98
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 172
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 152
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 692
at System.Security.Cryptography.X509Certificates.CertificateRequest.CreateSelfSigned(DateTimeOffset notBefore, DateTimeOffset notAfter) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 338
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 926
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1438
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.SimpleTest(PkiOptions pkiOptions, RunSimpleTest callback, String callerName, Boolean pkiOptionsInTestName) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1386
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.NothingRevoked(PkiOptions pkiOptions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 82
failed again in job: runtime 20201028.64
failed test: System.Security.Cryptography.X509Certificates.Tests.DynamicChainTests.BasicConstraints_ViolatesCaFalse
net6.0-Windows_NT-Release-x64-CoreCLR_release-(Windows.Nano.1809.Amd64.Open)windows.10.amd64.serverrs5.open@mcr.microsoft.com/dotnet-buildtools/prereqs:nanoserver-1809-helix-amd64-08e8e40-20200107182504
Error message
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 44
at System.Security.Cryptography.RSAImplementation.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 82
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 177
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 155
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 692
at System.Security.Cryptography.X509Certificates.Tests.TestDataGenerator.MakeTestChain(ReadOnlySpan`1 keys, Span`1 certs, IEnumerable`1 endEntityExtensions, IEnumerable`1 intermediateExtensions, IEnumerable`1 rootExtensions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/TestDataGenerator.cs:line 87
at System.Security.Cryptography.X509Certificates.Tests.TestDataGenerator.MakeTestChain3(X509Certificate2& endEntityCert, X509Certificate2& intermediateCert, X509Certificate2& rootCert, IEnumerable`1 endEntityExtensions, IEnumerable`1 intermediateExtensions, IEnumerable`1 rootExtensions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/TestDataGenerator.cs:line 30
at System.Security.Cryptography.X509Certificates.Tests.DynamicChainTests.BasicConstraints_ViolatesCaFalse() in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/DynamicChainTests.cs:line 260
failed again in job: runtime-libraries-coreclr outerloop 20201103.2
failed test: System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeIntermediateWithExpiredRevocation(pkiOptions: AllRevocation)
net6.0-windows-Release-x64-CoreCLR_release-(Windows.Nano.1809.Amd64.Open)windows.10.amd64.serverrs5.open@mcr.microsoft.com/dotnet-buildtools/prereqs:nanoserver-1809-helix-amd64-08e8e40-20200107182504
Error message
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 44
at System.Security.Cryptography.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 98
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 172
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 152
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 692
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X509Certificate2 issuerCertificate, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 537
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.CreateCertificate(String subject, RSA publicKey, TimeSpan nestingBuffer, X509ExtensionCollection extensions, Boolean ocspResponder) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 287
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 926
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1438
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.SimpleTest(PkiOptions pkiOptions, RunSimpleTest callback, String callerName, Boolean pkiOptionsInTestName) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1386
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeIntermediateWithExpiredRevocation(PkiOptions pkiOptions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 893
failed again in job: 20201201.66 runtime
failed test: System.Security.Cryptography.Rsa.Tests.EncryptDecrypt_Span.RsaDecryptAfterExport
Error message
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at System.Security.Cryptography.RSAImplementation.RSACng.TryEncryptOrDecrypt(SafeNCryptKeyHandle key, ReadOnlySpan`1 input, Span`1 output, AsymmetricPaddingMode paddingMode, Void* paddingInfo, Boolean encrypt, Int32& bytesWritten) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.EncryptDecrypt.cs:line 297
at System.Security.Cryptography.RSAImplementation.RSACng.TryEncryptOrDecrypt(ReadOnlySpan`1 data, Span`1 destination, RSAEncryptionPadding padding, Boolean encrypt, Int32& bytesWritten) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.EncryptDecrypt.cs:line 204
at System.Security.Cryptography.RSAImplementation.RSACng.TryDecrypt(ReadOnlySpan`1 data, Span`1 destination, RSAEncryptionPadding padding, Int32& bytesWritten) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.EncryptDecrypt.cs:line 37
at System.Security.Cryptography.Rsa.Tests.EncryptDecrypt_Span.<>c__DisplayClass1_0.<Decrypt>b__0(Byte[] dest) in /_/src/libraries/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/EncryptDecrypt.netcoreapp.cs:line 16
at System.Security.Cryptography.Rsa.Tests.EncryptDecrypt_Span.TryWithOutputArray(Func`2 func) in /_/src/libraries/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/EncryptDecrypt.netcoreapp.cs:line 23
at System.Security.Cryptography.Rsa.Tests.EncryptDecrypt_Span.Decrypt(RSA rsa, Byte[] data, RSAEncryptionPadding padding) in /_/src/libraries/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/EncryptDecrypt.netcoreapp.cs:line 16
at System.Security.Cryptography.Rsa.Tests.EncryptDecrypt.RsaDecryptAfterExport() in /_/src/libraries/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/EncryptDecrypt.cs:line 615
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) in /_/src/mono/netcore/System.Private.CoreLib/src/System/Reflection/RuntimeMethodInfo.cs:line 378
failed again in job: runtime-libraries-coreclr outerloop 20201207.1
failed test: System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntityWithInvalidRevocationSignature(pkiOptions: OcspEverywhere | IssuerAuthorityHasDesignatedOcspResponder | RootAuthorityHasDesignatedOcspResponder)
net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
Error message
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 44
at System.Security.Cryptography.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 67
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 172
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 152
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 692
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X509Certificate2 issuerCertificate, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 500
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.CreateCertificate(String subject, RSA publicKey, TimeSpan nestingBuffer, X509ExtensionCollection extensions, Boolean ocspResponder) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 287
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 926
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1438
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.SimpleTest(PkiOptions pkiOptions, RunSimpleTest callback, String callerName, Boolean pkiOptionsInTestName) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1386
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntityWithInvalidRevocationSignature(PkiOptions pkiOptions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 811
failed again in job: runtime-libraries-coreclr outerloop 20201217.2
failed test: System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntityWithExpiredRevocation(pkiOptions: IssuerRevocationViaOcsp | AllEndEntityRevocation | IssuerAuthorityHasDesignatedOcspResponder) System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.NothingRevoked_RootRevocationOffline(pkiOptions: AllRevocation | IssuerAuthorityHasDesignatedOcspResponder)
net6.0-windows-Release-x64-CoreCLR_release-(Windows.Nano.1809.Amd64.Open)windows.10.amd64.serverrs5.open@mcr.microsoft.com/dotnet-buildtools/prereqs:nanoserver-1809-helix-amd64-08e8e40-20200107182504
Error message
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 44
at System.Security.Cryptography.RSAImplementation.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 98
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 172
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 152
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 692
at System.Security.Cryptography.X509Certificates.CertificateRequest.CreateSelfSigned(DateTimeOffset notBefore, DateTimeOffset notAfter) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 338
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 926
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1438
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.SimpleTest(PkiOptions pkiOptions, RunSimpleTest callback, String callerName, Boolean pkiOptionsInTestName) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1386
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntityWithExpiredRevocation(PkiOptions pkiOptions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 869
failed again in job: runtime-libraries-coreclr outerloop 20210105.1
failed test: System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntityWithInvalidRevocationSignature(pkiOptions: IssuerRevocationViaCrl | OcspEverywhere | IssuerAuthorityHasDesignatedOcspResponder)
net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
Error message
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 44
at System.Security.Cryptography.RSAImplementation.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 67
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 172
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 152
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 692
at System.Security.Cryptography.X509Certificates.CertificateRequest.CreateSelfSigned(DateTimeOffset notBefore, DateTimeOffset notAfter) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 337
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 926
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1438
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.SimpleTest(PkiOptions pkiOptions, RunSimpleTest callback, String callerName, Boolean pkiOptionsInTestName) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1386
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntityWithInvalidRevocationSignature(PkiOptions pkiOptions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 811
@bartonjs would it make sense to have the tests ignore 0xc0000001 on Windows? It seems it's not useful to have them fail for it.
Failed again in job runtime 20210113.58
Failed test : System.Security.Cryptography.Rsa.Tests.SignVerify_Array.InvalidKeySize_DoesNotInvalidateKey
net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
Error message:
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 41
at System.Security.Cryptography.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 82
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 177
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 155
at System.Security.Cryptography.Rsa.Tests.SignVerify_Array.SignData(RSA rsa, Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/SignVerify.cs:line 16
at System.Security.Cryptography.Rsa.Tests.SignVerify.InvalidKeySize_DoesNotInvalidateKey() in /_/src/libraries/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/SignVerify.cs:line 114
Failed in job : runtime 20210119.71
Failed test : System.Security.Cryptography.X509Certificates.Tests.CertificateCreation.CertificateRequestUsageTests.RSACertificateNoPaddingMode
net6.0-windows-Release-x64-CoreCLR_release-(Windows.Nano.1809.Amd64.Open)windows.10.amd64.serverrs5.open@mcr.microsoft.com/dotnet-buildtools/prereqs:nanoserver-1809-helix-amd64-08e8e40-20200107182504
Error message:
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 41
at System.Security.Cryptography.RSAImplementation.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 82
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 177
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 155
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 692
at System.Security.Cryptography.X509Certificates.CertificateRequest.CreateSelfSigned(DateTimeOffset notBefore, DateTimeOffset notAfter) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 314
at System.Security.Cryptography.X509Certificates.Tests.CertificateCreation.CertificateRequestUsageTests.RSACertificateNoPaddingMode() in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/CertificateCreation/CertificateRequestUsageTests.cs:line 843
Same exception in run runtime 20210207.5
Failed test:
net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
-System.Security.Cryptography.Pkcs.Tests.SignedCmsTests.SignCmsUsingRSACertWithNotMatchingKeyThrows
Error message:
Assert.Throws() Failure
Expected: typeof(System.Security.Cryptography.CryptographicException)
Actual: typeof(Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException): Unknown error (0xc0000001)
---- Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.TrySignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, Span`1 signature, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32& bytesWritten) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 49
at System.Security.Cryptography.RSAImplementation.RSACng.TrySignHash(ReadOnlySpan`1 hash, Span`1 destination, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding, Int32& bytesWritten) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 126
at System.Security.Cryptography.Pkcs.CmsSignature.RSAPkcs1CmsSignature.Sign(ReadOnlySpan`1 dataHash, HashAlgorithmName hashAlgorithmName, X509Certificate2 certificate, AsymmetricAlgorithm key, Boolean silent, String& signatureAlgorithm, Byte[]& signatureValue) in /_/src/libraries/System.Security.Cryptography.Pkcs/src/System/Security/Cryptography/Pkcs/CmsSignature.RSA.cs:line 157
at System.Security.Cryptography.Pkcs.CmsSignature.Sign(ReadOnlySpan`1 dataHash, HashAlgorithmName hashAlgorithmName, X509Certificate2 certificate, AsymmetricAlgorithm key, Boolean silent, String& oid, ReadOnlyMemory`1& signatureValue) in /_/src/libraries/System.Security.Cryptography.Pkcs/src/System/Security/Cryptography/Pkcs/CmsSignature.cs:line 94
at System.Security.Cryptography.Pkcs.CmsSigner.Sign(ReadOnlyMemory`1 data, String contentTypeOid, Boolean silent, X509Certificate2Collection& chainCerts) in /_/src/libraries/System.Security.Cryptography.Pkcs/src/System/Security/Cryptography/Pkcs/CmsSigner.cs:line 229
at System.Security.Cryptography.Pkcs.SignedCms.ComputeSignature(CmsSigner signer, Boolean silent) in /_/src/libraries/System.Security.Cryptography.Pkcs/src/System/Security/Cryptography/Pkcs/SignedCms.cs:line 340
at System.Security.Cryptography.Pkcs.SignedCms.ComputeSignature(CmsSigner signer) in /_/src/libraries/System.Security.Cryptography.Pkcs/src/System/Security/Cryptography/Pkcs/SignedCms.cs:line 291
at System.Security.Cryptography.Pkcs.Tests.SignedCmsTests.<>c__DisplayClass76_0.<SignCmsUsingRSACertWithNotMatchingKeyThrows>b__0() in /_/src/libraries/System.Security.Cryptography.Pkcs/tests/SignedCms/SignedCmsTests.netcoreapp.cs:line 200
----- Inner Stack Trace -----
at Internal.Cryptography.CngCommon.TrySignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, Span`1 signature, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32& bytesWritten) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 49
at System.Security.Cryptography.RSAImplementation.RSACng.TrySignHash(ReadOnlySpan`1 hash, Span`1 destination, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding, Int32& bytesWritten) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 126
at System.Security.Cryptography.Pkcs.CmsSignature.RSAPkcs1CmsSignature.Sign(ReadOnlySpan`1 dataHash, HashAlgorithmName hashAlgorithmName, X509Certificate2 certificate, AsymmetricAlgorithm key, Boolean silent, String& signatureAlgorithm, Byte[]& signatureValue) in /_/src/libraries/System.Security.Cryptography.Pkcs/src/System/Security/Cryptography/Pkcs/CmsSignature.RSA.cs:line 157
at System.Security.Cryptography.Pkcs.CmsSignature.Sign(ReadOnlySpan`1 dataHash, HashAlgorithmName hashAlgorithmName, X509Certificate2 certificate, AsymmetricAlgorithm key, Boolean silent, String& oid, ReadOnlyMemory`1& signatureValue) in /_/src/libraries/System.Security.Cryptography.Pkcs/src/System/Security/Cryptography/Pkcs/CmsSignature.cs:line 94
at System.Security.Cryptography.Pkcs.CmsSigner.Sign(ReadOnlyMemory`1 data, String contentTypeOid, Boolean silent, X509Certificate2Collection& chainCerts) in /_/src/libraries/System.Security.Cryptography.Pkcs/src/System/Security/Cryptography/Pkcs/CmsSigner.cs:line 229
at System.Security.Cryptography.Pkcs.SignedCms.ComputeSignature(CmsSigner signer, Boolean silent) in /_/src/libraries/System.Security.Cryptography.Pkcs/src/
would it make sense to have the tests ignore 0xc0000001 on Windows? It seems it's not useful to have them fail for it.
Ultimately, that means wrapping every crypto test (or, at least all of the ones doing asymmetric cryptography) in a try/catch to exempt this e.HResult value on Windows... unless there's some sort of xunit top-level filter that can be registered.
Failed in runtime-libraries-coreclr outerloop 20210308.4
Failed test:
net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
-System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntity_RootRevocationOffline(pkiOptions: OcspEverywhere | RootAuthorityHasDesignatedOcspResponder)
Error message:
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 44
at System.Security.Cryptography.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 66
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 174
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 154
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 692
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X509Certificate2 issuerCertificate, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 500
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.CreateCertificate(String subject, RSA publicKey, TimeSpan nestingBuffer, X509ExtensionCollection extensions, Boolean ocspResponder) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 287
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority[]& intermediateAuthorities, X509Certificate2& endEntityCert, Int32 intermediateAuthorityCount, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 917
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1460
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntity_RootRevocationOffline(PkiOptions pkiOptions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 687
Failed in runtime-libraries-coreclr outerloop 20210324.3
Failed test:
net6.0-windows-Release-x64-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
-System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.NothingRevoked_RootRevocationOffline(pkiOptions: IssuerRevocationViaCrl | OcspEverywhere)
Error message:
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 44
at System.Security.Cryptography.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 97
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 174
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 154
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 692
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X509Certificate2 issuerCertificate, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 537
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.CreateCertificate(String subject, RSA publicKey, TimeSpan nestingBuffer, X509ExtensionCollection extensions, Boolean ocspResponder) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 287
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority[]& intermediateAuthorities, X509Certificate2& endEntityCert, Int32 intermediateAuthorityCount, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 918
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1590
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.NothingRevoked_RootRevocationOffline(PkiOptions pkiOptions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 803
Failed in runtime 20210510.71
Failed tests:
net6.0-windows-Release-x64-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
- System.Net.Security.Tests.SslStreamNetworkStreamTest.SslStream_ClientCertificate_SendsChain
- System.Net.Security.Tests.SslStreamNetworkStreamTest.SslStream_NestedAuth_Throws
- System.Net.Security.Tests.SslStreamNetworkStreamTest.SslStream_TargetHostName_Succeeds(useEmptyName: True)
- System.Net.Security.Tests.SslStreamNetworkStreamTest.SslStream_TargetHostName_Succeeds(useEmptyName: False)
- System.Net.Security.Tests.SslStreamNetworkStreamTest.SslStream_UntrustedCaWithCustomCallback_OK(usePartialChain: False)
- System.Net.Security.Tests.SslStreamNetworkStreamTest.SslStream_UntrustedCaWithCustomCallback_OK(usePartialChain: True)
Error message:
System.AggregateException : One or more errors occurred. (Unknown error (0xc0000001)) (The following constructor parameters did not have matching fixture data: CertificateSetup setup)
---- Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
---- The following constructor parameters did not have matching fixture data: CertificateSetup setup
Stack trace
----- Inner Stack Trace #1 (Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException) -----
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 41
at System.Security.Cryptography.RSAImplementation.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 81
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 179
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 157
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 692
at System.Security.Cryptography.X509Certificates.CertificateRequest.CreateSelfSigned(DateTimeOffset notBefore, DateTimeOffset notAfter) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 314
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority[]& intermediateAuthorities, X509Certificate2& endEntityCert, Int32 intermediateAuthorityCount, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 866
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 951
at System.Net.Security.Tests.TestHelper.GenerateCertificates(String targetName, String testName, Boolean longChain, Boolean serverCertificate) in /_/src/libraries/System.Net.Security/tests/FunctionalTests/TestHelper.cs:line 138
at System.Net.Security.Tests.CertificateSetup..ctor() in /_/src/libraries/System.Net.Security/tests/FunctionalTests/SslStreamNetworkStreamTest.cs:line 29
----- Inner Stack Trace #2 (Xunit.Sdk.TestClassException) -----
This issue seems to be Windows specific, however opening the runfo link https://runfo.azurewebsites.net/tracking/issue/124, recent failures seem to happen on Mac. Opened #53597 to track the Mac cases.
Failed again in runtime 20210602.73
Failed test:
net6.0-OSX-Release-x64-CoreCLR_release-OSX.1013.Amd64.Open
- System.Net.Security.Tests.SslStreamNetworkStreamTest.SslStream_NestedAuth_Throws
- System.Net.Security.Tests.SslStreamNetworkStreamTest.SslStream_RandomSizeWrites_OK
- System.Net.Security.Tests.SslStreamNetworkStreamTest.SslStream_TargetHostName_Succeeds
Error message:
System.AggregateException : One or more errors occurred. (UNIX[Undefined error: 0]) (The following constructor parameters did not have matching fixture data: CertificateSetup setup)
---- Interop+AppleCrypto+AppleCommonCryptoCryptographicException : UNIX[Undefined error: 0]
---- The following constructor parameters did not have matching fixture data: CertificateSetup setup
Stack trace
----- Inner Stack Trace #1 (Interop+AppleCrypto+AppleCommonCryptoCryptographicException) -----
at Interop.AppleCrypto.X509CopyWithPrivateKey(SafeSecCertificateHandle certHandle, SafeSecKeyRefHandle privateKeyHandle, SafeKeychainHandle targetKeychain) in /_/src/libraries/Common/src/Interop/OSX/System.Security.Cryptography.Native.Apple/Interop.X509.macOS.cs:line 277
at Internal.Cryptography.Pal.AppleCertificatePal.CopyWithPrivateKey(SafeSecKeyRefHandle privateKey) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/Internal/Cryptography/Pal.OSX/AppleCertificatePal.Keys.cs:line 167
at Internal.Cryptography.Pal.AppleCertificatePal.CopyWithPrivateKey(RSA privateKey) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/Internal/Cryptography/Pal.OSX/AppleCertificatePal.Keys.cs:line 99
at System.Security.Cryptography.X509Certificates.RSACertificateExtensions.CopyWithPrivateKey(X509Certificate2 certificate, RSA privateKey) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSACertificateExtensions.cs:line 56
at System.Net.Security.Tests.TestHelper.GenerateCertificates(String targetName, String testName, Boolean longChain, Boolean serverCertificate) in /_/src/libraries/System.Net.Security/tests/FunctionalTests/TestHelper.cs:line 177
at System.Net.Security.Tests.CertificateSetup..ctor() in /_/src/libraries/System.Net.Security/tests/FunctionalTests/SslStreamNetworkStreamTest.cs:line 30
----- Inner Stack Trace #2 (Xunit.Sdk.TestClassException) -----
@VincentBu that is a case of #53597
Failed again in: runtime-libraries-coreclr outerloop 20210906.5
Failed test:
net6.0-windows-Release-x64-CoreCLR_release-(Windows.Nano.1809.Amd64.Open)windows.10.amd64.serverrs5.open@mcr.microsoft.com/dotnet-buildtools/prereqs:nanoserver-1809-helix-amd64-08e8e40-20200107182504
- System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntityWithInvalidRevocationSignature(pkiOptions: IssuerRevocationViaCrl | OcspEverywhere)
Error message:
Internal.Cryptography.CryptoThrowHelper+WindowsCryptographicException : Unknown error (0xc0000001)
Stack trace
at Internal.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/Common/src/Internal/Cryptography/CngCommon.SignVerify.cs:line 20
at System.Security.Cryptography.RSAImplementation.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 97
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 174
at System.Security.Cryptography.RSA.SignData(Byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography.Algorithms/src/System/Security/Cryptography/RSA.cs:line 154
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 692
at System.Security.Cryptography.X509Certificates.CertificateRequest.CreateSelfSigned(DateTimeOffset notBefore, DateTimeOffset notAfter) in /_/src/libraries/System.Security.Cryptography.X509Certificates/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 338
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority[]& intermediateAuthorities, X509Certificate2& endEntityCert, Int32 intermediateAuthorityCount, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 834
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1595
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.SimpleTest(PkiOptions pkiOptions, RunSimpleTest callback, String callerName, Boolean pkiOptionsInTestName) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1544
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntityWithInvalidRevocationSignature(PkiOptions pkiOptions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 880
We have precedent for essentially adding retries to a whole category of tests -- see Event Log tests for example. there is even a common utility -- https://github.com/dotnet/runtime/blob/03e90a540cb2dfe5cab4086ea54ad5dd1f655749/src/libraries/Common/tests/TestUtilities/System/RetryHelper.cs#L10
Another option is the new test retries feature -- it works on a regex pattern matching on the test name, so it would blindly retry no matter what the failure was. The networking tests are using this now and are much more stable. It requires some diligence to check the data from time to time to ensure we haven't made the product sporadic in new ways.
The retry helper takes a predicate that could filter for 0xc0000001.
Anyone identified root cause of the issue? Can anyone help with fix for this ?
@bartonjs Might this, #25979, and #68590 all be the same underlying issue? Should we track them here only?
Failed again in: runtime-libraries-coreclr outerloop 20220526.3
Failed test:
net7.0-windows-Release-x64-CoreCLR_release-(Windows.Nano.1809.Amd64.Open)windows.10.amd64.serverrs5.open@mcr.microsoft.com/dotnet-buildtools/prereqs:nanoserver-1809-helix-amd64-08e8e40-20200107182504
- System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeIntermediateWithInvalidRevocationSignature(pkiOptions: IssuerRevocationViaOcsp | AllEndEntityRevocation | RootAuthorityHasDesignatedOcspResponder)
Error message:
at System.Security.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/System.Security.Cryptography/src/System/Security/Cryptography/CngCommon.SignVerify.cs:line 42
at System.Security.Cryptography.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 83
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography/src/System/Security/Cryptography/RSA.cs:line 185
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 685
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X509Certificate2 issuerCertificate, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 521
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.CreateCertificate(String subject, RSA publicKey, TimeSpan nestingBuffer, X509ExtensionCollection extensions, Boolean ocspResponder) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 287
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority[]& intermediateAuthorities, X509Certificate2& endEntityCert, Int32 intermediateAuthorityCount, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 914
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1594
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.SimpleTest(PkiOptions pkiOptions, RunSimpleTest callback, String callerName, Boolean pkiOptionsInTestName) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1543
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeIntermediateWithInvalidRevocationSignature(PkiOptions pkiOptions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 894
at InvokeStub_DynamicRevocationTests.RevokeIntermediateWithInvalidRevocationSignature(Object, Object, IntPtr*)
at System.Reflection.MethodInvoker.Invoke(Object obj, IntPtr* args, BindingFlags invokeAttr)
Failed again in: runtime-libraries-coreclr outerloop 20220621.1
Failed test:
net7.0-windows-Release-x64-CoreCLR_release-(Windows.Nano.1809.Amd64.Open)windows.10.amd64.serverrs5.open@mcr.microsoft.com/dotnet-buildtools/prereqs:nanoserver-1809-helix-amd64-08e8e40-20200107182504
- System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeLeafWithAiaFetchingDisabled(pkiOptions: IssuerRevocationViaCrl | EndEntityRevocationViaOcsp | IssuerAuthorityHasDesignatedOcspResponder)
Error message:
System.Security.Cryptography.CryptographicException : Unknown error (0xc0000001)
Stack trace
at System.Security.Cryptography.CngCommon.SignHash(SafeNCryptKeyHandle keyHandle, ReadOnlySpan`1 hash, AsymmetricPaddingMode paddingMode, Void* pPaddingInfo, Int32 estimatedSize) in /_/src/libraries/System.Security.Cryptography/src/System/Security/Cryptography/CngCommon.SignVerify.cs:line 42
at System.Security.Cryptography.RSACng.SignHash(Byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/Common/src/System/Security/Cryptography/RSACng.SignVerify.cs:line 83
at System.Security.Cryptography.RSA.SignData(Byte[] data, Int32 offset, Int32 count, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding) in /_/src/libraries/System.Security.Cryptography/src/System/Security/Cryptography/RSA.cs:line 183
at System.Security.Cryptography.X509Certificates.RSAPkcs1X509SignatureGenerator.SignData(Byte[] data, HashAlgorithmName hashAlgorithm) in /_/src/libraries/System.Security.Cryptography/src/System/Security/Cryptography/X509Certificates/RSAPkcs1X509SignatureGenerator.cs:line 22
at System.Security.Cryptography.X509Certificates.CertificateRequest.Create(X500DistinguishedName issuerName, X509SignatureGenerator generator, DateTimeOffset notBefore, DateTimeOffset notAfter, ReadOnlySpan`1 serialNumber) in /_/src/libraries/System.Security.Cryptography/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 685
at System.Security.Cryptography.X509Certificates.CertificateRequest.CreateSelfSigned(DateTimeOffset notBefore, DateTimeOffset notAfter) in /_/src/libraries/System.Security.Cryptography/src/System/Security/Cryptography/X509Certificates/CertificateRequest.cs:line 322
at System.Security.Cryptography.X509Certificates.Tests.Common.CertificateAuthority.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority[]& intermediateAuthorities, X509Certificate2& endEntityCert, Int32 intermediateAuthorityCount, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject, String subjectName, Int32 keySize, X509ExtensionCollection extensions) in /_/src/libraries/Common/tests/System/Security/Cryptography/X509Certificates/CertificateAuthority.cs:line 914
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.BuildPrivatePki(PkiOptions pkiOptions, RevocationResponder& responder, CertificateAuthority& rootAuthority, CertificateAuthority& intermediateAuthority, X509Certificate2& endEntityCert, String testName, Boolean registerAuthorities, Boolean pkiOptionsInSubject) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1594
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.SimpleTest(PkiOptions pkiOptions, RunSimpleTest callback, String callerName, Boolean pkiOptionsInTestName) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1543
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeLeafWithAiaFetchingDisabled(PkiOptions pkiOptions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 175
at InvokeStub_DynamicRevocationTests.RevokeLeafWithAiaFetchingDisabled(Object, Object, IntPtr*)
at System.Reflection.MethodInvoker.Invoke(Object obj, IntPtr* args, BindingFlags invokeAttr)
No hit in last 10 days (runfo says 2 hits per month), removing blocking-clean-ci label.
Failed again in: runtime-libraries-coreclr outerloop 20220705.5
Failed test:
net7.0-Linux-Release-x64-CoreCLR_release-(Ubuntu.2204.Amd64.Open)Ubuntu.1804.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-22.04-helix-amd64-20220504035722-1b9461f
- System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntity_IssuerUnrelatedOcsp(pkiOptions: IssuerRevocationViaCrl | EndEntityRevocationViaOcsp)
- System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntity_IssuerUnrelatedOcsp(pkiOptions: IssuerRevocationViaCrl | OcspEverywhere)
- System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntity_IssuerUnrelatedOcsp(pkiOptions: OcspEverywhere)
- System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntity_RootUnrelatedOcsp(pkiOptions: IssuerRevocationViaOcsp | AllEndEntityRevocation)
- System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntity_RootUnrelatedOcsp(pkiOptions: OcspEverywhere)
Error message:
System.AggregateException : One or more errors occurred. (Assert.Equal() Failure
↓ (pos 2)
Expected: [NoError, NoError, RevocationStatusUnknown | OfflineRevocati···
Actual: [NoError, NoError, Revoked]
↑ (pos 2)) (Assert.Equal() Failure
↓ (pos 2)
Expected: [NoError, NoError, RevocationStatusUnknown | OfflineRevocati···
Actual: [NoError, NoError, Revoked]
↑ (pos 2)) (Assert.Equal() Failure
↓ (pos 2)
Expected: [NoError, NoError, RevocationStatusUnknown | OfflineRevocati···
Actual: [NoError, NoError, Revoked]
↑ (pos 2)) (Assert.Equal() Failure
↓ (pos 2)
Expected: [NoError, NoError, RevocationStatusUnknown | OfflineRevocati···
Actual: [NoError, NoError, Revoked]
↑ (pos 2)) (Assert.Equal() Failure
↓ (pos 2)
Expected: [NoError, NoError, RevocationStatusUnknown | OfflineRevocati···
Actual: [NoError, NoError, Revoked]
↑ (pos 2))
---- Assert.Equal() Failure
↓ (pos 2)
Expected: [NoError, NoError, RevocationStatusUnknown | OfflineRevocati···
Actual: [NoError, NoError, Revoked]
↑ (pos 2)
---- Assert.Equal() Failure
↓ (pos 2)
Expected: [NoError, NoError, RevocationStatusUnknown | OfflineRevocati···
Actual: [NoError, NoError, Revoked]
↑ (pos 2)
---- Assert.Equal() Failure
↓ (pos 2)
Expected: [NoError, NoError, RevocationStatusUnknown | OfflineRevocati···
Actual: [NoError, NoError, Revoked]
↑ (pos 2)
---- Assert.Equal() Failure
↓ (pos 2)
Expected: [NoError, NoError, RevocationStatusUnknown | OfflineRevocati···
Actual: [NoError, NoError, Revoked]
↑ (pos 2)
---- Assert.Equal() Failure
↓ (pos 2)
Expected: [NoError, NoError, RevocationStatusUnknown | OfflineRevocati···
Actual: [NoError, NoError, Revoked]
↑ (pos 2)
Stack trace
at System.RetryHelper.Execute(Action test, Int32 maxAttempts, Func`2 backoffFunc, Predicate`1 retryWhen, String testName) in /_/src/libraries/Common/tests/TestUtilities/System/RetryHelper.cs:line 67
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.SimpleTest(PkiOptions pkiOptions, RunSimpleTest callback, String callerName, Boolean pkiOptionsInTestName) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1543
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.RevokeEndEntity_IssuerUnrelatedOcsp(PkiOptions pkiOptions) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 373
at InvokeStub_DynamicRevocationTests.RevokeEndEntity_IssuerUnrelatedOcsp(Object, Object, IntPtr*)
at System.Reflection.MethodInvoker.Invoke(Object obj, IntPtr* args, BindingFlags invokeAttr)
----- Inner Stack Trace #1 (Xunit.Sdk.EqualException) -----
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.AssertChainStatus(X509Chain chain, X509ChainStatusFlags rootStatus, X509ChainStatusFlags issrStatus, X509ChainStatusFlags leafStatus) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1572
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.<>c__DisplayClass19_0.<RevokeEndEntity_IssuerUnrelatedOcsp>b__0(CertificateAuthority root, CertificateAuthority intermediate, X509Certificate2 endEntity, ChainHolder holder, RevocationResponder responder) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 429
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.<>c__DisplayClass46_0.<SimpleTest>b__0() in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1541
at System.RetryHelper.Execute(Action test, Int32 maxAttempts, Func`2 backoffFunc, Predicate`1 retryWhen, String testName) in /_/src/libraries/Common/tests/TestUtilities/System/RetryHelper.cs:line 67
----- Inner Stack Trace #2 (Xunit.Sdk.EqualException) -----
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.AssertChainStatus(X509Chain chain, X509ChainStatusFlags rootStatus, X509ChainStatusFlags issrStatus, X509ChainStatusFlags leafStatus) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1572
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.<>c__DisplayClass19_0.<RevokeEndEntity_IssuerUnrelatedOcsp>b__0(CertificateAuthority root, CertificateAuthority intermediate, X509Certificate2 endEntity, ChainHolder holder, RevocationResponder responder) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 429
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.<>c__DisplayClass46_0.<SimpleTest>b__0() in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1541
at System.RetryHelper.Execute(Action test, Int32 maxAttempts, Func`2 backoffFunc, Predicate`1 retryWhen, String testName) in /_/src/libraries/Common/tests/TestUtilities/System/RetryHelper.cs:line 67
----- Inner Stack Trace #3 (Xunit.Sdk.EqualException) -----
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.AssertChainStatus(X509Chain chain, X509ChainStatusFlags rootStatus, X509ChainStatusFlags issrStatus, X509ChainStatusFlags leafStatus) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1572
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.<>c__DisplayClass19_0.<RevokeEndEntity_IssuerUnrelatedOcsp>b__0(CertificateAuthority root, CertificateAuthority intermediate, X509Certificate2 endEntity, ChainHolder holder, RevocationResponder responder) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 429
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.<>c__DisplayClass46_0.<SimpleTest>b__0() in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1541
at System.RetryHelper.Execute(Action test, Int32 maxAttempts, Func`2 backoffFunc, Predicate`1 retryWhen, String testName) in /_/src/libraries/Common/tests/TestUtilities/System/RetryHelper.cs:line 67
----- Inner Stack Trace #4 (Xunit.Sdk.EqualException) -----
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.AssertChainStatus(X509Chain chain, X509ChainStatusFlags rootStatus, X509ChainStatusFlags issrStatus, X509ChainStatusFlags leafStatus) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1572
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.<>c__DisplayClass19_0.<RevokeEndEntity_IssuerUnrelatedOcsp>b__0(CertificateAuthority root, CertificateAuthority intermediate, X509Certificate2 endEntity, ChainHolder holder, RevocationResponder responder) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 429
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.<>c__DisplayClass46_0.<SimpleTest>b__0() in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1541
at System.RetryHelper.Execute(Action test, Int32 maxAttempts, Func`2 backoffFunc, Predicate`1 retryWhen, String testName) in /_/src/libraries/Common/tests/TestUtilities/System/RetryHelper.cs:line 67
----- Inner Stack Trace #5 (Xunit.Sdk.EqualException) -----
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.AssertChainStatus(X509Chain chain, X509ChainStatusFlags rootStatus, X509ChainStatusFlags issrStatus, X509ChainStatusFlags leafStatus) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1572
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.<>c__DisplayClass19_0.<RevokeEndEntity_IssuerUnrelatedOcsp>b__0(CertificateAuthority root, CertificateAuthority intermediate, X509Certificate2 endEntity, ChainHolder holder, RevocationResponder responder) in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 429
at System.Security.Cryptography.X509Certificates.Tests.RevocationTests.DynamicRevocationTests.<>c__DisplayClass46_0.<SimpleTest>b__0() in /_/src/libraries/System.Security.Cryptography.X509Certificates/tests/RevocationTests/DynamicRevocationTests.cs:line 1541
Not actionable as is. https://mc.dot.net/#/user/dotnet-bot/pr~2Fdotnet~2Fcorefx~2Frefs~2Fpull~2F37960~2Fmerge/test~2Ffunctional~2Fcli~2Finnerloop~2F/20190528.20/workItem/System.Security.Cryptography.Cng.Tests/analysis/xunit/System.Security.Cryptography.Rsa.Tests.EncryptDecrypt_Span~2FRsaCryptRoundtrip_OaepSHA1
UPD by @CarnaViire: I went ahead and added Build Information below, from the last occurrence on my PR -- in hopes that known-issues infra would be able to validate and attach the failures not attached yet.
Build Information
Build: https://dev.azure.com/dnceng-public/public/_build/results?buildId=565017&view=results Build error leg or test failing: System.Security.Cryptography.Rsa.Tests.EncryptDecrypt_Span.RsaCryptRoundtrip_OaepSHA512 Pull request:
Error Message
Fill the error message using step by step known issues guidance.
Report
Summary
Known issue validation
Build: :mag_right: https://dev.azure.com/dnceng-public/public/_build/results?buildId=565017 Error message validated:
[CryptographicException : Unknown error (0x
] Result validation: :white_check_mark: Known issue matched with the provided build. Validation performed at: 2/19/2024 11:07:21 AM UTC