1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2012
    Rep Power

    Split data to smaller pieces then encrypt with RSA

    I am working on something which requires a large data to be encrypted. I know that this should be done using a symmetric key encryption system like AES instead of a public key encryption system like RSA. But I am thinking of doing it with RSA anyway, by splitting the data into smaller pieces and then encrypting each of them with the same public key. Aside from performance considerations, is this method safe? Can this encryption method be easily broken?

    Thanks a lot!
  2. #2
  3. No Profile Picture
    Lost in code
    Devshed Supreme Being (6500+ posts)

    Join Date
    Dec 2004
    Rep Power
    It is safe as long as you use a secure padding scheme with a different random value for every piece of the message. However the performance would be absurdly bad, I can't think of any possible benefit of doing it this way unless you're working with an embedded system that has limited space for storing code.

    Just do what everyone else does:
    generate a random AES key -> encrypt the message using AES -> encrypt the AES key using RSA -> transmit both

    Originally Posted by Spad
    Ah USB, the only rectangular connector where you have to make 3 attempts before you get it the right way around

IMN logo majestic logo threadwatch logo seochat tools logo