aboutsummaryrefslogtreecommitdiff
path: root/src/ringct/rctOps.cpp
diff options
context:
space:
mode:
authorShen Noether <Shen.Noether@gmx.com>2016-06-02 19:02:54 +0100
committermoneromooo-monero <moneromooo-monero@users.noreply.github.com>2016-08-28 21:27:57 +0100
commit55ff136e12d7425426e2196c6018f3123dd5e40d (patch)
treed01b5342fa41d656833af0b8d8f2823904c5abc1 /src/ringct/rctOps.cpp
parentringct: compare keys with bitwise equality, not crypto ops (diff)
downloadmonero-55ff136e12d7425426e2196c6018f3123dd5e40d.tar.xz
ringct: changes to hashToPointSimple to calcualte H2 values
Ported from Shen's RingCT repo
Diffstat (limited to '')
-rw-r--r--src/ringct/rctOps.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/ringct/rctOps.cpp b/src/ringct/rctOps.cpp
index 4fdfba73b..29e5e7e89 100644
--- a/src/ringct/rctOps.cpp
+++ b/src/ringct/rctOps.cpp
@@ -408,9 +408,14 @@ namespace rct {
key hashToPointSimple(const key & hh) {
key pointk;
+ ge_p1p1 point2;
+ ge_p2 point;
ge_p3 res;
key h = cn_fast_hash(hh);
ge_frombytes_vartime(&res, h.bytes);
+ ge_p3_to_p2(&point, &res);
+ ge_mul8(&point2, &point);
+ ge_p1p1_to_p3(&res, &point2);
ge_p3_tobytes(pointk.bytes, &res);
return pointk;
}