Skip to content

Commit

Permalink
Add test for generating supersingular curves with chosen prime.
Browse files Browse the repository at this point in the history
  • Loading branch information
J08nY committed Nov 29, 2024
1 parent 4a867ec commit b90324e
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,7 @@ Four different EC curve parameters generation methods are implemented.
- Used with the `--anomalous` option.
- These curves are **NOT SECURE** and are useful for implementation testing.
- [Elliptic curves over F_p suitable for cryptosystems - [Miyaji]](https://dspace.jaist.ac.jp/dspace/bitstream/10119/4464/1/73-61.pdf)
- TODO: Extend with [Generating Anomalous Elliptic Curves - [Leprevost, Monnerat, Varrette, Vaydenay]](https://www.monnerat.info/publications/anomalous.pdf)

### Build

Expand Down
1 change: 1 addition & 0 deletions test/data/prime.in
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
7161604836617373209
2 changes: 2 additions & 0 deletions test/ecgen.sh
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,8 @@ function supersingular() {
order_m1=$(echo $(canonical_num $order) - 1 | bc)
assert "canonical_num $p" $order_m1

assert_raises "${ecgen} --fp --supersingular --input=data/prime.in 64"

assert_raises "${ecgen} --fp --supersingular -r -u --metadata 20"
assert_raises "${ecgen} --fp --supersingular -r --points=random 16"
assert_raises "${ecgen} --fp --supersingular -r --points=5random 16"
Expand Down

0 comments on commit b90324e

Please sign in to comment.