diff options
author | Peter Dettman <peter.dettman@bouncycastle.org> | 2014-03-04 11:12:43 +0700 |
---|---|---|
committer | Peter Dettman <peter.dettman@bouncycastle.org> | 2014-03-04 11:12:43 +0700 |
commit | ecf5397a6edbe46248ef74a782e7443e4f5341c5 (patch) | |
tree | add85103823cd9edef723854e8215f396ca6123e /crypto/src/math/ec/custom/sec/SecP256K1Field.cs | |
parent | Refactoring in the Nat* classes and some new method variations (diff) | |
download | BouncyCastle.NET-ed25519-ecf5397a6edbe46248ef74a782e7443e4f5341c5.tar.xz |
Just use shift methods from Nat class evverywhere
Diffstat (limited to 'crypto/src/math/ec/custom/sec/SecP256K1Field.cs')
-rw-r--r-- | crypto/src/math/ec/custom/sec/SecP256K1Field.cs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/crypto/src/math/ec/custom/sec/SecP256K1Field.cs b/crypto/src/math/ec/custom/sec/SecP256K1Field.cs index 91144c017..6e834beb3 100644 --- a/crypto/src/math/ec/custom/sec/SecP256K1Field.cs +++ b/crypto/src/math/ec/custom/sec/SecP256K1Field.cs @@ -62,12 +62,12 @@ namespace Org.BouncyCastle.Math.EC.Custom.Sec { if ((x[0] & 1) == 0) { - Nat256.ShiftDownBit(x, 0, z); + Nat.ShiftDownBit(8, x, 0, z); } else { uint c = Nat256.Add(x, P, z); - Nat256.ShiftDownBit(z, c, z); + Nat.ShiftDownBit(8, z, c); } } @@ -157,7 +157,7 @@ namespace Org.BouncyCastle.Math.EC.Custom.Sec public static void Twice(uint[] x, uint[] z) { - uint c = Nat256.ShiftUpBit(x, 0, z); + uint c = Nat.ShiftUpBit(8, x, 0, z); if (c != 0 || (z[7] == P7 && Nat256.Gte(z, P))) { Nat256.Add33To(PInv33, z); |