Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Desktop: System.Security.Cryptography.Rsa.Tests.KeyGeneration.GenerateKey_4096 failed with "Xunit.Sdk.EqualException" #21300

Closed
KristinXie1 opened this issue Apr 24, 2017 · 5 comments
Assignees
Labels
area-System.Security test-run-desktop Test failures in .NET Framework "Desktop" test runs (running CoreFX test assets)
Milestone

Comments

@KristinXie1
Copy link

Failed test; System.Security.Cryptography.Rsa.Tests.KeyGeneration.GenerateKey_4096

Detail: https://ci.dot.net/job/dotnet_corefx/job/master/job/outerloop_netfx_windows_nt_debug/29/testReport/System.Security.Cryptography.Rsa.Tests/KeyGeneration/GenerateKey_4096/

MESSAGE:

Assert.Equal() Failure
    Expected: 4096
    Actual: 1024

STACK TRACE:

at System.Security.Cryptography.Rsa.Tests.KeyGeneration.GenerateKey(Func`2 getSize) 
in D:\j\workspace\outerloop_net---903ddde6\src\Common\tests\System\Security\Cryptography\AlgorithmImplementations\RSA\KeyGeneration.cs:line 57 
at System.Security.Cryptography.Rsa.Tests.KeyGeneration.GenerateKey(Int32 size) 
in D:\j\workspace\outerloop_net---903ddde6\src\Common\tests\System\Security\Cryptography\AlgorithmImplementations\RSA\KeyGeneration.cs:line 43 
at System.Security.Cryptography.Rsa.Tests.KeyGeneration.GenerateKey_4096() 
in D:\j\workspace\outerloop_net---903ddde6\src\Common\tests\System\Security\Cryptography\AlgorithmImplementations\RSA\KeyGeneration.cs:line 38
@krwq krwq self-assigned this Apr 26, 2017
@krwq
Copy link
Member

krwq commented Apr 26, 2017

netfx tiny repro:

            using (RSA rsa = RSA.Create()) // CSP impl
            {
                rsa.KeySize = 4096;
                Console.WriteLine(rsa.KeySize); // =>1024
            } 

This is clearly incorrect. @bartonjs, is it ok to disable this for now on netfx and port this change later? This is clearly not .NET Core related and needs some change ported.

@krwq
Copy link
Member

krwq commented Apr 26, 2017

@krwq
Copy link
Member

krwq commented Apr 26, 2017

Ok this is apparently by design according to that - I'm disabling those on netfx

@bartonjs
Copy link
Member

Yep, I've finally come over to @morganbr's way of thinking and think we should fix RSACryptoServiceProvider; probably with a retargeting quirk. It's pretty interesting watching how far one way or the other I go down the feature vs compat arguments in my head.

@msftgits msftgits transferred this issue from dotnet/corefx Jan 31, 2020
@msftgits msftgits added this to the 2.0.0 milestone Jan 31, 2020
@ghost ghost locked as resolved and limited conversation to collaborators Dec 24, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-System.Security test-run-desktop Test failures in .NET Framework "Desktop" test runs (running CoreFX test assets)
Projects
None yet
Development

No branches or pull requests

4 participants