What are the best asymmetric encryption algorithms out there? I am trying to use RSA in my project howoever I have read that it is not quite secure as other asymmetric encryption algorithms.
closed as not a real question by Adi, Gilles, AJ Henderson, Iszi, lynks Apr 30 '13 at 16:57
It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. If this question can be reworded to fit the rules in the help center, please edit the question.
"Best" implies some gradation on a scale, which should be defined...
The most commonly used asymmetric encryption algorithm is RSA. It is good enough for most purposes. RSA has some limitations, which are rather generic (i.e. which apply to most other asymmetric encryption algorithms as well):
- It can process only limited-size messages (with a 1024-bit RSA key, you can encrypt at most 117 bytes).
- It implies some size overhead (with a 1024-bit RSA key, you get a 128-byte encrypted message, even though the source message has size no more than 117 bytes).
- It must use some randomness (deterministic asymmetric encryption is intrinsically weak because it allows for exhaustive search on the message itself).
- It can be relatively expensive on very small architectures.
To work around most of these issues, hybrid encryption is used: with RSA, you encrypt a random symmetric key (i.e. 128 random bits) and you use that key to encrypt the bulk of the data with a faster, less constrained symmetric encryption algorithm like AES.
Another relatively common asymmetric encryption algorithm is ElGamal. Its elliptic curve variants can offer better performance than RSA (faster, less size overhead), but hybrid encryption is still needed.
Assembling asymmetric and symmetric encryption correctly is not an easy task, so don't go creative and invent your own (it is easy to have something which works, but very hard to obtain something which works securely). Instead, use an existing protocol where all the tricky details have been worked out; e.g. OpenPGP.