Pascal Paillier
   HOME

TheInfoList



OR:

The Paillier cryptosystem, invented by and named after Pascal Paillier in 1999, is a probabilistic
asymmetric algorithm Public-key cryptography, or asymmetric cryptography, is the field of cryptographic systems that use pairs of related keys. Each key pair consists of a public key and a corresponding private key. Key pairs are generated with cryptographic al ...
for
public key cryptography Public-key cryptography, or asymmetric cryptography, is the field of cryptographic systems that use pairs of related keys. Each key pair consists of a public key and a corresponding private key. Key pairs are generated with cryptographic alg ...
. The problem of computing ''n''-th residue classes is believed to be computationally difficult. The
decisional composite residuosity assumption The decisional composite residuosity assumption (DCRA) is a mathematical assumption used in cryptography. In particular, the assumption is used in the proof of the Paillier cryptosystem. Informally, the DCRA states that given a composite n and an i ...
is the intractability hypothesis upon which this cryptosystem is based. The scheme is an additive homomorphic cryptosystem; this means that, given only the public key and the encryption of m_1 and m_2, one can compute the encryption of m_1+m_2.


Algorithm

The scheme works as follows:


Key generation

#Choose two large prime numbers p and q randomly and independently of each other such that \gcd(pq, (p-1)(q-1))=1. This property is assured if both primes are of equal length.Jonathan Katz, Yehuda Lindell, "Introduction to Modern Cryptography: Principles and Protocols," Chapman & Hall/CRC, 2007 #Compute n=pq and \lambda=\operatorname(p-1,q-1). lcm means
Least Common Multiple In arithmetic and number theory, the least common multiple, lowest common multiple, or smallest common multiple of two integers ''a'' and ''b'', usually denoted by lcm(''a'', ''b''), is the smallest positive integer that is divisible by bot ...
. #Select random integer g where g\in \mathbb Z^_ #Ensure n divides the order of g by checking the existence of the following
modular multiplicative inverse In mathematics, particularly in the area of arithmetic, a modular multiplicative inverse of an integer is an integer such that the product is congruent to 1 with respect to the modulus .. In the standard notation of modular arithmetic this congru ...
: \mu = (L(g^\lambda \bmod n^2))^ \bmod n, :where function L is defined as L(x) = \frac . ::Note that the notation \frac does not denote the modular multiplication of a times the
modular multiplicative inverse In mathematics, particularly in the area of arithmetic, a modular multiplicative inverse of an integer is an integer such that the product is congruent to 1 with respect to the modulus .. In the standard notation of modular arithmetic this congru ...
of b but rather the
quotient In arithmetic, a quotient (from lat, quotiens 'how many times', pronounced ) is a quantity produced by the division of two numbers. The quotient has widespread use throughout mathematics, and is commonly referred to as the integer part of a ...
of a divided by b, i.e., the largest integer value v \ge 0 to satisfy the relation a \ge vb. *The public (encryption) key is (n, g). *The private (decryption) key is (\lambda, \mu). If using p,q of equivalent length, a simpler variant of the above key generation steps would be to set g = n+1, \lambda = \varphi(n), and \mu = \varphi(n)^ \bmod n, where \varphi(n) = (p-1)(q-1) . The simpler variant is recommended for implementational purposes, because in the general form the calculation time of \mu can be very high with sufficiently large primes p,q.


Encryption

#Let m be a message to be encrypted where 0 \leq m < n #Select random r where 0 < r < n #Compute ciphertext as: c=g^m \cdot r^n \bmod n^2


Decryption

#Let c be the ciphertext to decrypt, where c\in \mathbb Z^_ #Compute the plaintext message as: m = L(c^\lambda \bmod n^2) \cdot \mu \bmod n As the original paper points out, decryption is "essentially one exponentiation modulo n^2."


Homomorphic properties

A notable feature of the Paillier cryptosystem is its
homomorphic In algebra, a homomorphism is a structure-preserving map between two algebraic structures of the same type (such as two groups, two rings, or two vector spaces). The word ''homomorphism'' comes from the Ancient Greek language: () meaning "same" ...
properties along with its non-deterministic encryption (see Electronic voting in Applications for usage). As the encryption function is additively homomorphic, the following identities can be described: * Homomorphic addition of plaintexts : The product of two ciphertexts will decrypt to the sum of their corresponding plaintexts, :: D(E(m_1, r_1)\cdot E(m_2, r_2)\bmod n^2) = m_1 + m_2 \bmod n. \, : The product of a ciphertext with a plaintext raising g will decrypt to the sum of the corresponding plaintexts, :: D(E(m_1, r_1)\cdot g^ \bmod n^2) = m_1 + m_2 \bmod n. \, * Homomorphic multiplication of plaintexts : A ciphertext raised to the power of a plaintext will decrypt to the product of the two plaintexts, :: D(E(m_1, r_1)^\bmod n^2) = m_1 m_2 \bmod n, \, :: D(E(m_2, r_2)^\bmod n^2) = m_1 m_2 \bmod n. \, : More generally, a ciphertext raised to a constant ''k'' will decrypt to the product of the plaintext and the constant, :: D(E(m_1, r_1)^k\bmod n^2) = k m_1 \bmod n. \, However, given the Paillier encryptions of two messages there is no known way to compute an encryption of the product of these messages without knowing the private key.


Background

Paillier cryptosystem exploits the fact that certain
discrete logarithms In mathematics, for given real numbers ''a'' and ''b'', the logarithm log''b'' ''a'' is a number ''x'' such that . Analogously, in any group ''G'', powers ''b'k'' can be defined for all integers ''k'', and the discrete logarithm log''b'' ...
can be computed easily. For example, by
binomial theorem In elementary algebra, the binomial theorem (or binomial expansion) describes the algebraic expansion of powers of a binomial. According to the theorem, it is possible to expand the polynomial into a sum involving terms of the form , where the ...
, :: (1+n)^x=\sum_^x n^k = 1+nx+n^2 + \textn This indicates that: :: (1+n)^x \equiv 1+nx\pmod Therefore, if: :: y = (1+n)^x \bmod n^2 then :: x \equiv \frac \pmod. Thus: :: L((1+n)^x \bmod n^2) \equiv x \pmod, :where function L is defined as L(u) = \frac (quotient of integer division) and x \in \mathbb Z_.


Semantic security

The original cryptosystem as shown above does provide
semantic security In cryptography, a semantically secure cryptosystem is one where only negligible information about the plaintext can be feasibly extracted from the ciphertext. Specifically, any probabilistic, polynomial-time algorithm (PPTA) that is given the ciph ...
against chosen-plaintext attacks (
IND-CPA Ciphertext indistinguishability is a property of many encryption schemes. Intuitively, if a cryptosystem possesses the property of indistinguishability, then an adversary will be unable to distinguish pairs of ciphertexts based on the message th ...
). The ability to successfully distinguish the challenge ciphertext essentially amounts to the ability to decide composite residuosity. The so-called
decisional composite residuosity assumption The decisional composite residuosity assumption (DCRA) is a mathematical assumption used in cryptography. In particular, the assumption is used in the proof of the Paillier cryptosystem. Informally, the DCRA states that given a composite n and an i ...
(DCRA) is believed to be intractable. Because of the aforementioned homomorphic properties however, the system is
malleable Ductility is a mechanical property commonly described as a material's amenability to drawing (e.g. into wire). In materials science, ductility is defined by the degree to which a material can sustain plastic deformation under tensile stres ...
, and therefore does not enjoy the highest level of semantic security, protection against adaptive chosen-ciphertext attacks (
IND-CCA2 Ciphertext indistinguishability is a property of many encryption schemes. Intuitively, if a cryptosystem possesses the property of indistinguishability, then an adversary will be unable to distinguish pairs of ciphertexts based on the message th ...
). Usually in cryptography the notion of malleability is not seen as an "advantage," but under certain applications such as secure electronic voting and threshold cryptosystems, this property may indeed be necessary. Paillier and Pointcheval however went on to propose an improved cryptosystem that incorporates the combined hashing of message ''m'' with random ''r''. Similar in intent to the
Cramer–Shoup cryptosystem The Cramer–Shoup system is an asymmetric key encryption algorithm, and was the first efficient scheme proven to be secure against adaptive chosen ciphertext attack using standard cryptographic assumptions. Its security is based on the computation ...
, the hashing prevents an attacker, given only ''c,'' from being able to change ''m'' in a meaningful way. Through this adaptation the improved scheme can be shown to be
IND-CCA2 Ciphertext indistinguishability is a property of many encryption schemes. Intuitively, if a cryptosystem possesses the property of indistinguishability, then an adversary will be unable to distinguish pairs of ciphertexts based on the message th ...
secure in the
random oracle model In cryptography, a random oracle is an oracle (a theoretical black box) that responds to every ''unique query'' with a (truly) random response chosen uniformly from its output domain. If a query is repeated, it responds the same way every time t ...
.


Applications


Electronic voting

Semantic security is not the only consideration. There are situations under which malleability may be desirable. The above homomorphic properties can be utilized by secure electronic voting systems. Consider a simple binary ("for" or "against") vote. Let ''m'' voters cast a vote of either ''1'' (for) or ''0'' (against). Each voter encrypts their choice before casting their vote. The election official takes the product of the ''m'' encrypted votes and then decrypts the result and obtains the value ''n'', which is the sum of all the votes. The election official then knows that ''n'' people voted ''for'' and ''m-n'' people voted ''against''. The role of the random ''r'' ensures that two equivalent votes will encrypt to the same value only with negligible likelihood, hence ensuring voter privacy.


Electronic cash

Another feature named in paper is the notion of self- blinding. This is the ability to change one ciphertext into another without changing the content of its decryption. This has application to the development of
ecash Ecash was conceived by David Chaum as an anonymous cryptographic electronic money or electronic cash system in 1983. It was realized through his corporation Digicash and used as micropayment system at one US bank from 1995 to 1998. Design Chaum pub ...
, an effort originally spearheaded by
David Chaum David Lee Chaum (born 1955) is an American computer scientist, cryptographer, and inventor. He is known as a pioneer in cryptography and privacy-preserving technologies, and widely recognized as the inventor of digital cash. His 1982 dissertatio ...
. Imagine paying for an item online without the vendor needing to know your credit card number, and hence your identity. The goal in both electronic cash and electronic voting, is to ensure the e-coin (likewise e-vote) is valid, while at the same time not disclosing the identity of the person with whom it is currently associated.


Threshold cryptosystem

The homomorphic property of Paillier cryptosystem is sometime used to build Threshold ECDSA signature.


See also

* The
Naccache–Stern cryptosystem The Naccache–Stern cryptosystem is a homomorphic public-key cryptosystem whose security rests on the higher residuosity problem. The Naccache–Stern cryptosystem was discovered by David Naccache and Jacques Stern in 1998. Scheme Definition L ...
and the
Okamoto–Uchiyama cryptosystem The Okamoto–Uchiyama cryptosystem is a public key cryptosystem proposed in 1998 by Tatsuaki Okamoto and Shigenori Uchiyama. The system works in the multiplicative group of integers modulo n, (\mathbb/n\mathbb)^*, where ''n'' is of the form ''p'' ...
are historical antecedents of Paillier. * The
Damgård–Jurik cryptosystem The Damgård–Jurik cryptosystemIvan Damgård, Mads JurikA Generalisation, a Simplification and Some Applications of Paillier's Probabilistic Public-Key System Public Key Cryptography 2001: 119-136 is a generalization of the Paillier cryptosystem. ...
is a generalization of Paillier.


References

* * * *


Notes


External links


The Homomorphic Encryption Project
implements the Paillier cryptosystem along with its homomorphic operations.
Encounter: an open-source library providing an implementation of Paillier cryptosystem and a cryptographic counters construction based on the same.python-paillier
a library for Partially Homomorphic Encryption in Python, including full support for floating point numbers. * Th
Paillier cryptosystem interactive simulator
demonstrates a voting application. * A
interactive demo
of the Paillier cryptosystem. * A proof-of-concep
Javascript implementation
of the Paillier cryptosystem with a
interactive demo
*
googletechtalk video
on voting using cryptographic methods. *
Ruby implementation
of Paillier homomorphic addition and a zero-knowledge proof protocol
documentation
{{Cryptography navbox , public-key Public-key encryption schemes