diff options
| author | J08nY | 2019-03-16 23:17:31 +0100 |
|---|---|---|
| committer | J08nY | 2019-03-18 00:08:04 +0100 |
| commit | f85110c524d53aa856ebfedb2a7c4cd516179126 (patch) | |
| tree | af8dab02203436592378a1b819fad80a9abee534 /src/cz/crcs/ectester/standalone/ECTesterStandalone.java | |
| parent | 21b7936fce4f41dafa9aa3032eff44de1a72b1da (diff) | |
| download | ECTester-f85110c524d53aa856ebfedb2a7c4cd516179126.tar.gz ECTester-f85110c524d53aa856ebfedb2a7c4cd516179126.tar.zst ECTester-f85110c524d53aa856ebfedb2a7c4cd516179126.zip | |
Migrate plot scripts to Jupyter notebook format. Fix ECDSA nonce recovery.
Diffstat (limited to '')
| -rw-r--r-- | src/cz/crcs/ectester/standalone/ECTesterStandalone.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cz/crcs/ectester/standalone/ECTesterStandalone.java b/src/cz/crcs/ectester/standalone/ECTesterStandalone.java index 35db7da..1b4d9b8 100644 --- a/src/cz/crcs/ectester/standalone/ECTesterStandalone.java +++ b/src/cz/crcs/ectester/standalone/ECTesterStandalone.java @@ -369,7 +369,7 @@ public class ECTesterStandalone { ECPublicKey pubkey = (ECPublicKey) ECUtil.loadKey(EC_Consts.PARAMETER_W, cli.getOptionValue("ecdh.named-public"), cli.getOptionValue("ecdh.public"), (ECParameterSpec) spec); int amount = Integer.parseInt(cli.getOptionValue("ecdh.amount", "1")); - for (int i = 0; i < amount; ++i) { + for (int i = 0; i < amount || amount == 0; ++i) { if (!cli.hasOption("ecdh.fixed-private") && !cli.hasOption("ecdh.named-private") && !cli.hasOption("ecdh.private")) { one = kpg.genKeyPair(); } @@ -506,7 +506,7 @@ public class ECTesterStandalone { ECPublicKey pubkey = (ECPublicKey) ECUtil.loadKey(EC_Consts.PARAMETER_W, cli.getOptionValue("ecdsa.named-public"), cli.getOptionValue("ecdsa.public"), spec); int amount = Integer.parseInt(cli.getOptionValue("ecdsa.amount", "1")); - for (int i = 0; i < amount; ++i) { + for (int i = 0; i < amount || amount == 0; ++i) { if (!cli.hasOption("ecdsa.named-private") || !cli.hasOption("ecdsa.named-public")) { KeyPair one = kpg.genKeyPair(); |
