diff options
Diffstat (limited to 'crypto/src/math/ec/custom/sec/SecP192K1Field.cs')
-rw-r--r-- | crypto/src/math/ec/custom/sec/SecP192K1Field.cs | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/crypto/src/math/ec/custom/sec/SecP192K1Field.cs b/crypto/src/math/ec/custom/sec/SecP192K1Field.cs index 6f6f28f91..d5ca903d1 100644 --- a/crypto/src/math/ec/custom/sec/SecP192K1Field.cs +++ b/crypto/src/math/ec/custom/sec/SecP192K1Field.cs @@ -75,6 +75,18 @@ namespace Org.BouncyCastle.Math.EC.Custom.Sec Reduce(tt, z); } + public static void MultiplyAddToExt(uint[] x, uint[] y, uint[] zz) + { + uint c = Nat192.MulAddTo(x, y, zz); + if (c != 0 || (zz[11] == PExt11 && Nat.Gte(12, zz, PExt))) + { + if (Nat.AddTo(PExtInv.Length, PExtInv, zz) != 0) + { + Nat.IncAt(12, zz, PExtInv.Length); + } + } + } + public static void Negate(uint[] x, uint[] z) { if (Nat192.IsZero(x)) |