TheBenaloh Cryptosystem is an extension of theGoldwasser-Micali cryptosystem (GM) created in 1985 by Josh (Cohen) Benaloh. The main improvement of the Benaloh Cryptosystem over GM is that longer blocks of data can be encrypted at once, whereas in GM each bit is encrypted individually.[1][2][3]
Given block sizer, a public/private key pair is generated as follows:
Choose large primesp andq such that and
Set
Choose such that.
Note: Ifr is composite, it was pointed out by Fousse et al. in 2011[4] that the above conditions (i.e., those stated in the original paper) are insufficient to guarantee correct decryption, i.e., to guarantee that in all cases (as should be the case). To address this, the authors propose the following check: let be the prime factorization ofr. Choose such that for each factor, it is the case that.
To understand decryption, first notice that for any and we have:
To recoverm froma, we take thediscrete log ofa basex. Ifr is small, we can recover m by an exhaustive search, i.e. checking if for all. For larger values ofr, theBaby-step giant-step algorithm can be used to recoverm in time and space.
The security of this scheme rests on theHigher residuosity problem, specifically, givenz,r andn where the factorization ofn is unknown, it is computationally infeasible to determine whetherz is anrth residue modn, i.e. if there exists anx such that.