RSA cryptography between Python and Java

Piet van Oostrum piet at
Mon Jul 27 08:19:49 EDT 2009

>>>>> Michael Ströder <michael at> (MS) wrote:

>MS> Piet van Oostrum wrote:
>>> Please note that the text to be encrypted must be smaller than the key
>>> size (at least 11 bytes smaller). You shouldn't encrypt large data with
>>> RSA anyway: it is too slow. Normally you would encrypt a session key
>>> with RSA and encrypt the data with the session key using a symmetric
>>> algorithms like AES.

>MS> I'd use CMS (AKA PKCS#7) for encrypted/signed data with X.509 certs. One
>MS> should not invent another message format.

Yes but the original question was not about X.509 certs. Just the RSA
public key. I don't know what the OP wants to do with it.
Piet van Oostrum <piet at>
URL: [PGP 8DAE142BE17999C4]
Private email: piet at

More information about the Python-list mailing list