Implement ECC in C

I would like to implement “my own hybrid encryption mechanism” using the asymmetric curvature cryptography of an elliptic curve instead of other RSA or ElGamal algorithms.

Assuming I want to use curves that provide more security, which ones should I use? Based on what I read, I think the 521-bit curve is probably perfect. Are there safer schemes?

What are the safest implementations in C / C ++ (without using C ++ STL) against, for example, side attacks? I would like to implement it as a “separate” module, so I would appreciate clean source code or good links.

+5
source share
1 answer

Before even thinking about whether any of the standard curves might be safe enough, I just go and make sure that the encryption mode is really protected from simple old selected encrypted text attacks. I think that Cramer and Shope's 2003 article, “Developing and Analyzing Practical Public Key Encryption Schemes to Protect Against Adaptive Selective Encryption Attacks,” 2003 was a good starting point for analyzing hybrid encryption schemes.

As for temporary attacks: OpenSSL contains implementations for a small number of selected curves that were implemented so that they run in constant time.

+1
source

All Articles