pyecsca.ec.formula.fake module¶
Provides “fake” formulas.
- class FakeFormula(coordinate_model)[source]¶
Bases:
Formula
,ABC
No matter what the input point is, it just returns the right amount of FakePoints.
Useful for computing with the scalar multipliers without having concrete formulas and points (for example to get the addition chain via the MultipleContext).
- class FakeAdditionFormula(coordinate_model)[source]¶
Bases:
FakeFormula
,AdditionFormula
- class FakeDoublingFormula(coordinate_model)[source]¶
Bases:
FakeFormula
,DoublingFormula
- class FakeTriplingFormula(coordinate_model)[source]¶
Bases:
FakeFormula
,TriplingFormula
- class FakeNegationFormula(coordinate_model)[source]¶
Bases:
FakeFormula
,NegationFormula
- class FakeScalingFormula(coordinate_model)[source]¶
Bases:
FakeFormula
,ScalingFormula
- class FakeDifferentialAdditionFormula(coordinate_model)[source]¶
- class FakeLadderFormula(coordinate_model)[source]¶
Bases:
FakeFormula
,LadderFormula
- class FakePoint(model)[source]¶
Bases:
Point
Just a fake point.
- equals(other)[source]¶
Test whether this point is equal to other irrespective of the coordinate model (in the affine sense).
- Return type:
bool
- equals_affine(other)[source]¶
Test whether this point is equal to
other
irrespective of the coordinate model (in the affine sense).- Return type:
bool
- equals_scaled(other)[source]¶
Test whether this point is equal to
other
using the “z” scaling formula.The “z” scaling formula maps the projective class to a single representative.