diff options
author | lloyd <[email protected]> | 2010-02-25 20:13:25 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2010-02-25 20:13:25 +0000 |
commit | f39241bf20dc6781be576f17b264ee1a6bf7d58b (patch) | |
tree | 9c1997c15c52c1f5e416625c8182f323a85f2d06 /src/math/gfpmath/point_gfp.cpp | |
parent | 679a1a57a19484c4cf2720f9b415b8a8df45b209 (diff) |
create_random_point was not used anywhere, so remove it
Diffstat (limited to 'src/math/gfpmath/point_gfp.cpp')
-rw-r--r-- | src/math/gfpmath/point_gfp.cpp | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/src/math/gfpmath/point_gfp.cpp b/src/math/gfpmath/point_gfp.cpp index 24aa8d8af..42ad7ef51 100644 --- a/src/math/gfpmath/point_gfp.cpp +++ b/src/math/gfpmath/point_gfp.cpp @@ -425,29 +425,4 @@ PointGFp OS2ECP(const MemoryRegion<byte>& os, const CurveGFp& curve) return result; } -PointGFp create_random_point(RandomNumberGenerator& rng, - const CurveGFp& curve) - { - const BigInt& p = curve.get_p(); - - while(true) - { - BigInt r(rng, p.bits()); - - GFpElement x = GFpElement(p, r); - GFpElement x3 = x * x * x; - - GFpElement ax(curve.get_p(), curve.get_a()); - ax *= x; - - GFpElement bx3(curve.get_p(), curve.get_b()); - bx3 *= x3; - - GFpElement y = ax + bx3; - - if(ressol(y.get_value(), p) > 0) - return PointGFp(curve, x.get_value(), y.get_value()); - } - } - } |