From ac5ab976832d3d6e107502acd318f9fe3b12e547 Mon Sep 17 00:00:00 2001 From: Peter Dettman Date: Fri, 9 Aug 2019 17:08:48 +0700 Subject: Add non-constant-time variant to ECLookupTable --- crypto/BouncyCastle.Android.csproj | 1 + crypto/BouncyCastle.csproj | 1 + crypto/BouncyCastle.iOS.csproj | 1 + crypto/crypto.csproj | 5 +++ crypto/src/math/ec/AbstractECLookupTable.cs | 16 +++++++ crypto/src/math/ec/ECAlgorithms.cs | 4 +- crypto/src/math/ec/ECCurve.cs | 58 +++++++++++++++++++++---- crypto/src/math/ec/ECLookupTable.cs | 1 + crypto/src/math/ec/SimpleLookupTable.cs | 11 +++-- crypto/src/math/ec/custom/djb/Curve25519.cs | 43 +++++++++++++----- crypto/src/math/ec/custom/gm/SM2P256V1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecP128R1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecP160K1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecP160R1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecP160R2Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecP192K1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecP192R1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecP224K1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecP224R1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecP256K1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecP256R1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecP384R1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecP521R1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT113R1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT113R2Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT131R1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT131R2Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT163K1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT163R1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT163R2Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT193R1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT193R2Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT233K1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT233R1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT239K1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT283K1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT283R1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT409K1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT409R1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT571K1Curve.cs | 28 ++++++++++-- crypto/src/math/ec/custom/sec/SecT571R1Curve.cs | 28 ++++++++++-- 41 files changed, 860 insertions(+), 149 deletions(-) create mode 100644 crypto/src/math/ec/AbstractECLookupTable.cs (limited to 'crypto') diff --git a/crypto/BouncyCastle.Android.csproj b/crypto/BouncyCastle.Android.csproj index c1c53fc52..f30b48433 100644 --- a/crypto/BouncyCastle.Android.csproj +++ b/crypto/BouncyCastle.Android.csproj @@ -1218,6 +1218,7 @@ + diff --git a/crypto/BouncyCastle.csproj b/crypto/BouncyCastle.csproj index 3ba21ac66..be84564e2 100644 --- a/crypto/BouncyCastle.csproj +++ b/crypto/BouncyCastle.csproj @@ -1212,6 +1212,7 @@ + diff --git a/crypto/BouncyCastle.iOS.csproj b/crypto/BouncyCastle.iOS.csproj index b6810009b..53e8a5b00 100644 --- a/crypto/BouncyCastle.iOS.csproj +++ b/crypto/BouncyCastle.iOS.csproj @@ -1213,6 +1213,7 @@ + diff --git a/crypto/crypto.csproj b/crypto/crypto.csproj index 7789d1858..ca6dba5ff 100644 --- a/crypto/crypto.csproj +++ b/crypto/crypto.csproj @@ -5948,6 +5948,11 @@ SubType = "Code" BuildAction = "Compile" /> +