mirror of
				https://github.com/laurivosandi/certidude
				synced 2025-10-31 01:19:11 +00:00 
			
		
		
		
	ocsp: Add EC support
This commit is contained in:
		| @@ -100,8 +100,8 @@ class OCSPResource(AuthorityHandler): | |||||||
|                 'response': { |                 'response': { | ||||||
|                     'tbs_response_data': response_data, |                     'tbs_response_data': response_data, | ||||||
|                     'certs': [server_certificate.asn1], |                     'certs': [server_certificate.asn1], | ||||||
|                     'signature_algorithm': {'algorithm': "sha1_rsa"}, |                     'signature_algorithm': {'algorithm': "sha1_ecdsa" if self.authority.public_key.algorithm == "ec" else "sha1_rsa" }, | ||||||
|                     'signature': asymmetric.rsa_pkcs1v15_sign( |                     'signature': (asymmetric.ecdsa_sign if self.authority.public_key.algorithm == "ec" else asymmetric.rsa_pkcs1v15_sign)( | ||||||
|                         self.authority.private_key, |                         self.authority.private_key, | ||||||
|                         response_data.dump(), |                         response_data.dump(), | ||||||
|                         "sha1" |                         "sha1" | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user