开发者

openssl_csr_get_public_key in Python

开发者 https://www.devze.com 2023-03-06 19:18 出处:网络
Can anybody suggest any python *ssl rsa library* , which has a function like in PHP (openssl_csr_get_public_key).

Can anybody suggest any python *ssl rsa library* , which has a function like in PHP (openssl_csr_get_public_key).

Because i have a certificate , with which i need t开发者_如何学运维o verify the data . And every time i try to use this certificate with M2Crypto public key functiton , it gives error "no start line " , which is completely understandable because its not a public key , but a certificate which has a public key in it. As much as i understand.

Thx in advance .


I think what you want is M2Crypto.X509.load_cert(), and then getting the public key from the certificate object using cert.get_pubkey().

0

精彩评论

暂无评论...
验证码 换一张
取 消