mirror of
				https://github.com/ruby/ruby.git
				synced 2022-11-09 12:17:21 -05:00 
			
		
		
		
	* add test for SHA224, SHA256, SHA384 and SHA512.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@9023 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
		
							parent
							
								
									bfb1ed598c
								
							
						
					
					
						commit
						60106097ce
					
				
					 2 changed files with 11 additions and 0 deletions
				
			
		| 
						 | 
				
			
			@ -4,6 +4,8 @@ Tue Aug 23 06:07:02 2005  GOTOU Yuuzou  <gotoyuzo@notwork.org>
 | 
			
		|||
	  these features are enabled if this library is compiled with
 | 
			
		||||
	  OpenSSL 0.9.8 or later.
 | 
			
		||||
 | 
			
		||||
	* test/openssl/test_digest.rb: add test for new digests.
 | 
			
		||||
 | 
			
		||||
Tue Aug 23 05:47:04 2005  GOTOU Yuuzou  <gotoyuzo@notwork.org>
 | 
			
		||||
 | 
			
		||||
	* ext/openssl/ossl_ns_spki.c (ossl_spki_initialize): try to decode
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -60,6 +60,15 @@ class OpenSSL::TestDigest < Test::Unit::TestCase
 | 
			
		|||
    dig2 = @d1.digest
 | 
			
		||||
    assert_equal(dig1, dig2, "reset")
 | 
			
		||||
  end
 | 
			
		||||
 | 
			
		||||
  if OpenSSL::OPENSSL_VERSION_NUMBER > 0x00908000
 | 
			
		||||
    def test_098_features
 | 
			
		||||
      assert_equal("abd37534c7d9a2efb9465de931cd7055ffdb8879563ae98078d6d6d5", OpenSSL::Digest::SHA224.hexdigest("a"))
 | 
			
		||||
      assert_equal("ca978112ca1bbdcafac231b39a23dc4da786eff8147c4e72b9807785afee48bb", OpenSSL::Digest::SHA256.hexdigest("a"))
 | 
			
		||||
      assert_equal("54a59b9f22b0b80880d8427e548b7c23abd873486e1f035dce9cd697e85175033caa88e6d57bc35efae0b5afd3145f31", OpenSSL::Digest::SHA384.hexdigest("a"))
 | 
			
		||||
      assert_equal("1f40fc92da241694750979ee6cf582f2d5d7d28e18335de05abc54d0560e0f5302860c652bf08d560252aa5e74210546f369fbbbce8c12cfc7957b2652fe9a75", OpenSSL::Digest::SHA512.hexdigest("a"))
 | 
			
		||||
    end
 | 
			
		||||
  end
 | 
			
		||||
end
 | 
			
		||||
 | 
			
		||||
end
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue