A system for elliptic curve encryption, the system comprising a computer having a computer readable medium having stored thereon instructions which, when executed by a processor of the computer, causes the processor to perform the steps of:
- (a) selecting an elliptic curve Ep (a,b) of the form y2=x3+ax+b mod (p), wherein p is a prime number, wherein a and b are non-negative integers less than p satisfying the formula 4a3+27b2 mod (p) not equal to 0;
- (b) generating a 160 bit random number by a method of concatenation of a number of smaller random numbers;
- (c) generating a well hidden point G (x,y) on the elliptic curve Ep (a,b) by scalar multiplication of a point B (x,y) on the elliptic curve with a random integer M further comprising the steps of:
- (i) converting the random integer M into a series of powers of 231;
- (ii) converting each coefficient of 231 obtained from above step into a binary series;
- (iii) multiplying the binary series obtained from steps (i) and (ii) above with the point B (x,y) on the elliptic curve;
- (d) generating a private key nA greater than or equal to 160 bits;
- (e) generating a public key PA(x,y) given by the formula PA(x,y)=(nA.G(x,y)) mod (p);
- (f) encrypting an input message MSG further comprising the steps of:
- (i) generating a random integer K;
- (ii) setting Pmask(x,y)=k.PA(x,y) mod (p);
- (iii) setting pk(x,y)=k.G(x,y) mod (p);
- (iv) accepting the input message MSG to be encrypted;
- (v) converting the input message into a point Pc(x,y);
- (vi) generating a random point Pm(x,y) on the elliptic curve Ep(a,b);
- (vii) setting Pe(x,y)=(Pc(x,y)−Pm(x,y));
- (viii) setting Pmk(x,y)=(Pm(x,y)+Pmask(x,y)) mod (p);
- (ix) returning Pk(x),Pe(x,y), and Pmk(x) as a ciphered text;
- and
- (g) decrypting the ciphered text further comprising the steps of:
- (i) getting the ciphered text (Pk(x), Pa(x,y), and Pmk(x);
- (ii) computing Pk(y) from Pk(x) using the elliptic curve Ep(a,b);
- (iii) computing Pmk(y) from Pmk(x) using elliptic curve Ep(a,b);
- (iv) computing Pak(x,y)=(nA. Pk(x,y)) mod (p);
- (v) computing Pm(x,y)=Pmk(x,y)−Pak(x,y)) mod (p);
- (vi) computing Pc(x,y)=Pm(x,y)+Pe(x,y);
- (vii) converting Pc(x,y) into the input message MSG.