From 5a203d0fd93b71b768396fcb51b12b243760e52e Mon Sep 17 00:00:00 2001 From: Benoit Daloze Date: Mon, 27 Nov 2023 17:01:19 +0100 Subject: [PATCH] Remove the test since it seems unspecified and fixed in later versions --- library/openssl/kdf/pbkdf2_hmac_spec.rb | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/library/openssl/kdf/pbkdf2_hmac_spec.rb b/library/openssl/kdf/pbkdf2_hmac_spec.rb index 50cb23062..40f859727 100644 --- a/library/openssl/kdf/pbkdf2_hmac_spec.rb +++ b/library/openssl/kdf/pbkdf2_hmac_spec.rb @@ -154,24 +154,6 @@ }.should raise_error(ArgumentError, 'missing keywords: :salt, :iterations, :length, :hash') end - - quarantine! do - guard -> { OpenSSL::OPENSSL_VERSION_NUMBER < 0x30000000 } do - it "treats 0 or less iterations as a single iteration" do - salt = "\x00".b * 16 - length = 16 - hash = "sha1" - - # "Any iter less than 1 is treated as a single iteration." - key0 = OpenSSL::KDF.pbkdf2_hmac("secret", **@defaults, iterations: 0) - key_negative = OpenSSL::KDF.pbkdf2_hmac("secret", **@defaults, iterations: -1) - key1 = OpenSSL::KDF.pbkdf2_hmac("secret", **@defaults, iterations: 1) - key0.should == key1 - key_negative.should == key1 - end - end - end - guard -> { OpenSSL::OPENSSL_VERSION_NUMBER >= 0x30000000 } do it "raises an OpenSSL::KDF::KDFError for 0 or less iterations" do -> {