aboutsummaryrefslogtreecommitdiff
path: root/pyecsca/misc
diff options
context:
space:
mode:
authorJ08nY2024-07-11 17:23:31 +0200
committerJ08nY2024-07-11 17:23:31 +0200
commit63024fd9395f2e6a5712226773f012091ea85edb (patch)
tree2518918f48155e5ae23115682b9f0390e4a5a4c9 /pyecsca/misc
parent43e105655bd2de6b64ddb3c4ddf4b965bc196e6b (diff)
downloadpyecsca-63024fd9395f2e6a5712226773f012091ea85edb.tar.gz
pyecsca-63024fd9395f2e6a5712226773f012091ea85edb.tar.zst
pyecsca-63024fd9395f2e6a5712226773f012091ea85edb.zip
Diffstat (limited to 'pyecsca/misc')
-rw-r--r--pyecsca/misc/cfg.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/pyecsca/misc/cfg.py b/pyecsca/misc/cfg.py
index 05f89b8..eac5174 100644
--- a/pyecsca/misc/cfg.py
+++ b/pyecsca/misc/cfg.py
@@ -18,7 +18,7 @@ class ECConfig:
_non_residue_action: str = "error"
_unsatisfied_formula_assumption_action: str = "error"
_unsatisfied_coordinate_assumption_action: str = "error"
- _mod_implementation: str = "gmp"
+ _mod_implementation: str = "flint"
@property
def no_inverse_action(self) -> str:
@@ -109,6 +109,7 @@ class ECConfig:
One of:
+ - ``"flint"``: Requires the flint library and `python-flint` package.
- ``"gmp"``: Requires the GMP library and `gmpy2` package.
- ``"python"``: Doesn't require anything.
- ``"symbolic"``: Requires sympy.
@@ -117,8 +118,8 @@ class ECConfig:
@mod_implementation.setter
def mod_implementation(self, value: str):
- if value not in ("python", "gmp", "symbolic"):
- raise ValueError("Bad Mod implementaiton, can be one of 'python', 'gmp' or 'symbolic'.")
+ if value not in ("python", "gmp", "flint", "symbolic"):
+ raise ValueError("Bad Mod implementaiton, can be one of 'python', 'gmp', 'flint' or 'symbolic'.")
self._mod_implementation = value