runner icon indicating copy to clipboard operation
runner copied to clipboard

Enable-TlsCipherSuite Fails Without Error in Hosted Runner

Open s-nix opened this issue 1 year ago • 0 comments

Describe the bug When running a Pester test to validate if a TLS cipher suite can be validated to be enabled, my test is consistently failing when it succeeds locally on my workstation.

Context "When the system is vulnerable to CVE-2016-2183" {
        BeforeAll {
            Enable-TlsCipherSuite -Name "TLS_RSA_WITH_3DES_EDE_CBC_SHA"
        }
        
        It "Returns $true if the system is vulnerable to CVE-2016-2183" {
            [bool](Get-TlsCipherSuite -Name "TLS_RSA_WITH_3DES_EDE_CBC_SHA") | Should -BeTrue
        }

        AfterAll {
            Disable-TlsCipherSuite -Name "TLS_RSA_WITH_3DES_EDE_CBC_SHA"
        }
    }

To Reproduce Steps to reproduce the behavior:

  1. Create a GitHub workflow that runs the specified test.
  2. Run the workflow and review results.
  3. Note that the test will always fail.

Expected behavior The test should succeed as the TlsCipherSuite should be enabled at the time of the Should -BeTrue

Runner Version and Platform

Latest Version

Windows

What's not working?

image

Job Log Output

Starting discovery in 2 files.
Discovery found 3 tests in 39[6](https://github.com/ProVal-Tech/CVE-2016-2183/actions/runs/9977039129/job/27570691744#step:3:7)ms.
Running tests.
Error: [-] Find-CVE20162183.When the system is vulnerable to CVE-2016-21[8](https://github.com/ProVal-Tech/CVE-2016-2183/actions/runs/9977039129/job/27570691744#step:3:9)3.Returns True 556ms (533ms|23ms)
Message
  Expected $true, but got $false.
  at Find-CVE20162183 | Should -BeTrue, D:\a\CVE-2016-2183\CVE-2016-2183\Tests\Public\Find-CVE20162183.Tests.ps1:12
  at <ScriptBlock>, D:\a\CVE-2016-2183\CVE-2016-2183\Tests\Public\Find-CVE20162183.Tests.ps1:[12](https://github.com/ProVal-Tech/CVE-2016-2183/actions/runs/9977039129/job/27570691744#step:3:13)
  
[+] D:\a\CVE-2016-2183\CVE-2016-2183\Tests\Public\Resolve-CVE20162183.Tests.ps1 125ms (86ms|33ms)
Tests completed in 2.85s
Tests Passed: 2, Failed: 1, Skipped: 0, Inconclusive: 0, NotRun: 0

Runner and Worker's Diagnostic Logs

logs_26114792393.zip

s-nix avatar Jul 17 '24 15:07 s-nix