diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 350c9517c..a137877d3 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -64,20 +64,24 @@ jobs: os: [ ubuntu-latest ] ruby: [ "3.0" ] openssl: + # https://www.openssl.org/source/ - openssl-1.0.2u # EOL - openssl-1.1.0l # EOL - - openssl-1.1.1t - - openssl-3.0.8 + - openssl-1.1.1u + - openssl-3.0.9 + - openssl-3.1.1 + # http://www.libressl.org/releases.html - libressl-3.1.5 # EOL - libressl-3.2.7 # EOL - libressl-3.3.6 # EOL - libressl-3.4.3 # EOL - - libressl-3.5.3 - - libressl-3.6.1 - - libressl-3.7.0 # Development release + - libressl-3.5.3 # EOL + - libressl-3.6.3 + - libressl-3.7.3 + - libressl-3.8.0 # Development release fips-enabled: [ false ] include: - - { os: ubuntu-latest, ruby: "3.0", openssl: openssl-3.0.8, fips-enabled: true, append-configure: 'enable-fips', name-extra: 'fips' } + - { os: ubuntu-latest, ruby: "3.0", openssl: openssl-3.0.9, fips-enabled: true, append-configure: 'enable-fips', name-extra: 'fips' } steps: - name: repo checkout uses: actions/checkout@v3 diff --git a/test/openssl/test_bn.rb b/test/openssl/test_bn.rb index 77af14091..ea88ff06c 100644 --- a/test/openssl/test_bn.rb +++ b/test/openssl/test_bn.rb @@ -175,7 +175,9 @@ def test_mod_sqr end def test_mod_sqrt - assert_equal(3, 4.to_bn.mod_sqrt(5)) + assert_equal(4, 4.to_bn.mod_sqrt(5).mod_sqr(5)) + # One of 189484 or 326277 is returned as a square root of 2 (mod 515761). + assert_equal(2, 2.to_bn.mod_sqrt(515761).mod_sqr(515761)) assert_equal(0, 5.to_bn.mod_sqrt(5)) assert_raise(OpenSSL::BNError) { 3.to_bn.mod_sqrt(5) } end