mirror of
				https://github.com/ruby/ruby.git
				synced 2022-11-09 12:17:21 -05:00 
			
		
		
		
	* ext/openssl/ossl_hmac.c: Revert checking return type of
HMAC_Init_ex as it is not compatible with OpenSSL < 1.0.0. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32609 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
		
							parent
							
								
									afd3a18fc3
								
							
						
					
					
						commit
						af01784150
					
				
					 2 changed files with 8 additions and 7 deletions
				
			
		| 
						 | 
				
			
			@ -1,3 +1,8 @@
 | 
			
		|||
Fri Jul 22 13:03:12 2011  Martin Bosslet  <Martin.Bosslet@googlemail.com>
 | 
			
		||||
 | 
			
		||||
	* ext/openssl/ossl_hmac.c: Revert checking return type of
 | 
			
		||||
	  HMAC_Init_ex as it is not compatible with OpenSSL < 1.0.0.
 | 
			
		||||
 | 
			
		||||
Fri Jul 22 12:10:21 2011  Eric Hodel  <drbrain@segment7.net>
 | 
			
		||||
 | 
			
		||||
	* tool/rbinstall.rb (default gems):  Install executables into the fake
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -70,10 +70,8 @@ ossl_hmac_initialize(VALUE self, VALUE key, VALUE digest)
 | 
			
		|||
 | 
			
		||||
    StringValue(key);
 | 
			
		||||
    GetHMAC(self, ctx);
 | 
			
		||||
    if (HMAC_Init_ex(ctx, RSTRING_PTR(key), RSTRING_LENINT(key),
 | 
			
		||||
		 GetDigestPtr(digest), NULL) != 1) {
 | 
			
		||||
	ossl_raise(eHMACError, "HMAC initialization failed.");
 | 
			
		||||
    }
 | 
			
		||||
    HMAC_Init(ctx, RSTRING_PTR(key), RSTRING_LENINT(key),
 | 
			
		||||
		 GetDigestPtr(digest));
 | 
			
		||||
 | 
			
		||||
    return self;
 | 
			
		||||
}
 | 
			
		||||
| 
						 | 
				
			
			@ -182,9 +180,7 @@ ossl_hmac_reset(VALUE self)
 | 
			
		|||
    HMAC_CTX *ctx;
 | 
			
		||||
 | 
			
		||||
    GetHMAC(self, ctx);
 | 
			
		||||
    if (HMAC_Init_ex(ctx, NULL, 0, NULL, NULL) != 1) {
 | 
			
		||||
	ossl_raise(eHMACError, "HMAC initialization failed");
 | 
			
		||||
    }
 | 
			
		||||
    HMAC_Init(ctx, NULL, 0, NULL);
 | 
			
		||||
 | 
			
		||||
    return self;
 | 
			
		||||
}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue