title: M2Crypto get certificate (X509) signature hash algorithm
body: <p>For a small project I want to manage some certificates.
  In the beginning I used the Python &quot;cryptography&quot; extension but I needed some further functionality so I switched to M2Crypto.</p>
  <p>With &quot;cryptography&quot; I retrieved the signature hash algorithm from the certificate like so <code>cert.signature_hash_algorithm.name.upper()</code>. With M2Crypto I cannot find a way to get the same result.</p>
  <p>How can I get the signature hash algorithm from a X509 certificate with M2Crypto?</p>