title: Python RSA library?
body: <pre><code>from Crypto.PublicKey import RSA
  private = RSA.generate(1024, os.urandom)
  </code></pre>
  
  <p>Now how do I export or import keys? Everything is there except these 2 functions!</p>
  
  <pre><code>private.exportKey()
  private.publickey.exportKey()
  </code></pre>
  
  <p>Preferably in --armor format :)</p>
  
  <p>Any ideas?</p>
  
  <hr>
  
  <p>Thanks all. Turned out that Ubuntu installs an old version of PyCrypto and I had to fetch 2.3 from their website.</p>