|
@@ -103,19 +103,19 @@ Quadripoint BGN::homomorphic_multiplication(const CurveBipoint& a, const TwistBi
|
|
|
return public_key.homomorphic_multiplication(a, b);
|
|
|
}
|
|
|
|
|
|
-void BGN::rerandomize(CurveBipoint& G_element) const
|
|
|
+CurveBipoint BGN::rerandomize(const CurveBipoint& G_element) const
|
|
|
{
|
|
|
- public_key.rerandomize(G_element);
|
|
|
+ return public_key.rerandomize(G_element);
|
|
|
}
|
|
|
|
|
|
-void BGN::rerandomize(TwistBipoint& H_element) const
|
|
|
+TwistBipoint BGN::rerandomize(const TwistBipoint& H_element) const
|
|
|
{
|
|
|
- public_key.rerandomize(H_element);
|
|
|
+ return public_key.rerandomize(H_element);
|
|
|
}
|
|
|
|
|
|
-void BGN::rerandomize(Quadripoint& Gt_element) const
|
|
|
+Quadripoint BGN::rerandomize(const Quadripoint& Gt_element) const
|
|
|
{
|
|
|
- public_key.rerandomize(Gt_element);
|
|
|
+ return public_key.rerandomize(Gt_element);
|
|
|
}
|
|
|
|
|
|
Scalar BGN::decrypt(const CurveBipoint& ciphertext)
|
|
@@ -133,12 +133,12 @@ Scalar BGN::decrypt(const Quadripoint& ciphertext)
|
|
|
return private_key.decrypt(ciphertext);
|
|
|
}
|
|
|
|
|
|
-const PublicKey& BGN::get_public_key() const
|
|
|
+const BGNPublicKey& BGN::get_public_key() const
|
|
|
{
|
|
|
return public_key;
|
|
|
}
|
|
|
|
|
|
-const PrivateKey& BGN::get_private_key() const
|
|
|
+const BGNPrivateKey& BGN::get_private_key() const
|
|
|
{
|
|
|
return private_key;
|
|
|
}
|