didiercrunch / paillier

Paillier cryptosystem implemented in Go
MIT License
20 stars 16 forks source link

Added support for a Cypher multiplication #8

Closed pdyraga closed 6 years ago

pdyraga commented 6 years ago

It's now possible to multiply Cypher by an integer.

Paillier is a homomorphic encryption scheme, where an encrypted plaintext m raised to an integer k will decrypt to the product of the plaintext m and k.

D( E(m)^k mod N^2 ) = km mod N

I have also updated all .DeepEqual calls to just .Cmp in the paillier_test.go when we compare integers. Use of reflection for just an integer comparison feels like a bit too heavy.

didiercrunch commented 6 years ago

As always, outstanding code quality that brings true value to the package.

Thousand thanks and continue what you are doing!

didier