diff options
Diffstat (limited to 'crypto/src/math/ec/custom/sec/SecP256R1FieldElement.cs')
-rw-r--r-- | crypto/src/math/ec/custom/sec/SecP256R1FieldElement.cs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/crypto/src/math/ec/custom/sec/SecP256R1FieldElement.cs b/crypto/src/math/ec/custom/sec/SecP256R1FieldElement.cs index ba48fcbac..b22763cfa 100644 --- a/crypto/src/math/ec/custom/sec/SecP256R1FieldElement.cs +++ b/crypto/src/math/ec/custom/sec/SecP256R1FieldElement.cs @@ -157,7 +157,7 @@ namespace Org.BouncyCastle.Math.EC.Custom.Sec SecP256R1Field.SquareN(t1, 94, t1); SecP256R1Field.Multiply(t1, t1, t2); - return Arrays.AreEqual(x1, t2) ? new SecP256R1FieldElement(t1) : null; + return Nat256.Eq(x1, t2) ? new SecP256R1FieldElement(t1) : null; } public override bool Equals(object obj) @@ -176,12 +176,12 @@ namespace Org.BouncyCastle.Math.EC.Custom.Sec return true; if (null == other) return false; - return Arrays.AreEqual(x, other.x); + return Nat256.Eq(x, other.x); } public override int GetHashCode() { - return Q.GetHashCode() ^ Arrays.GetHashCode(x); + return Q.GetHashCode() ^ Arrays.GetHashCode(x, 0, 8); } } } |