Skip to content

System.Security.Cryptography.Pkcs test Decrypt_512_CekDoesNotDecrypt_FixedValue fails on Fedora 38 #95115

Closed

Description

@akoeplinger

Outerloop runs fail on Fedora 38:

https://helix.dot.net/api/2019-06-17/jobs/037f28b7-637f-4634-8ab1-3b4527ffc077/workitems/System.Security.Cryptography.Pkcs.Tests/console

  Discovering: System.Security.Cryptography.Tests (method display = ClassAndMethod, method display options = None)
  Discovered:  System.Security.Cryptography.Tests (found 56 of 4203 test cases)
  Starting:    System.Security.Cryptography.Pkcs.Tests (parallel test collections = on, max threads = 2)
    System.Security.Cryptography.Pkcs.EnvelopedCmsTests.Tests.DecryptTestsUsingCertWithPrivateKey.Decrypt_512_CekDoesNotDecrypt_FixedValue [FAIL]
      Assert.ThrowsAny() Failure: No exception was thrown
      Expected: typeof(System.Security.Cryptography.CryptographicException)
      Stack Trace:
        /_/src/libraries/System.Security.Cryptography.Pkcs/tests/EnvelopedCms/DecryptTests.cs(148,0): at System.Security.Cryptography.Pkcs.EnvelopedCmsTests.Tests.DecryptTests.Decrypt_512_CekDoesNotDecrypt_FixedValue()
           at System.RuntimeMethodHandle.InvokeMethod(Object target, Void** arguments, Signature sig, Boolean isConstructor)
        /_/src/libraries/System.Private.CoreLib/src/System/Reflection/MethodBaseInvoker.cs(57,0): at System.Reflection.MethodBaseInvoker.InvokeWithNoArgs(Object obj, BindingFlags invokeAttr)

Activity

  1. added
    os-linux
    on Nov 22, 2023
  2. ghost added
    untriaged
    on Nov 22, 2023
  3. changed the title [-]System.Security.Cryptography.Pkcs.EnvelopedCmsTests.Tests.Decrypt_512_CekDoesNotDecrypt_FixedValue fails on Fedora 38[/-] [+]System.Security.Cryptography.Pkcs test Decrypt_512_CekDoesNotDecrypt_FixedValue fails on Fedora 38[/+] on Nov 22, 2023
  4. bartonjs commented on Nov 22, 2023

    @bartonjs
    Member

    Weird. This is about as deterministic as a crypto test gets (it uses a known key to decrypt a known value), and it clearly succeeded on retry since the log linked above shows success.

    This feels like one of those "the computer said 2 + 2 = 5" never-reproducible bugs... but let's see if we get some more hits to try and force a repro.

  5. added this to the Future milestone on Nov 22, 2023
  6. ghost removed
    untriaged
    on Nov 22, 2023
  7. akoeplinger commented on Nov 22, 2023

    @akoeplinger
    MemberAuthor

    @bartonjs where are you seeing this succeed? It fails on every outerloop run on Fedora 38 across both mono and coreclr.

  8. bartonjs commented on Nov 22, 2023

    @bartonjs
    Member

    where are you seeing this succeed?

    The log you linked to says no failures...

  9. bartonjs commented on Nov 22, 2023

    @bartonjs
    Member

    Ah. The log you originally linked to, which is what I got in the email notification. I see the current link has a failure.

  10. modified the milestones: Future, 9.0.0 on Nov 22, 2023
  11. akoeplinger commented on Nov 22, 2023

    @akoeplinger
    MemberAuthor

    Yeah sorry, that was a copy-paste mistake :D

  12. vcsjones commented on Nov 22, 2023

    @vcsjones
    Member

    I can reproduce it on Fedora 39 but not Ubuntu 23.04. Odd.

  13. vcsjones commented on Nov 22, 2023

    @vcsjones
    Member

    Okay. @bartonjs and I tracked it down to openssl/openssl#13817. This is a change in OpenSSL 3.2 that Fedora / Red Hat back ported.

    We are going to disable the implicit rejection so the APIs work as they have always worked.

  14. self-assigned this
    on Nov 22, 2023
  15. ghost added
    in-pr
    on Nov 23, 2023
  16. ghost removed
    in-pr
    on Nov 24, 2023
  17. vcsjones commented on Nov 24, 2023

    @vcsjones
    Member

    Re-opening because we probably need to backport this.

  18. tomato42 commented on Dec 6, 2023

    @tomato42

    @vcsjones We have implemented it in OpenSSL specifically to protect users of such broken API as the one provided by C# and VB.NET.

    By disabling implicit rejection you are MAKING them vulnerable

    Please, see https://people.redhat.com/~hkario/marvin/ and read it whole, including both of the papers.

  19. locked and limited conversation to collaborators on Apr 4, 2024
  20. added
    in-pr
    on Aug 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area-System.Securityin-pros-linux

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions