summary refs log tree commit diff
path: root/crypto/src/math/ec/custom/sec/SecT571FieldElement.cs
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/src/math/ec/custom/sec/SecT571FieldElement.cs')
-rw-r--r--crypto/src/math/ec/custom/sec/SecT571FieldElement.cs2
1 files changed, 1 insertions, 1 deletions
diff --git a/crypto/src/math/ec/custom/sec/SecT571FieldElement.cs b/crypto/src/math/ec/custom/sec/SecT571FieldElement.cs
index 8474c912e..a26e1e336 100644
--- a/crypto/src/math/ec/custom/sec/SecT571FieldElement.cs
+++ b/crypto/src/math/ec/custom/sec/SecT571FieldElement.cs
@@ -12,7 +12,7 @@ namespace Org.BouncyCastle.Math.EC.Custom.Sec
 
         public SecT571FieldElement(BigInteger x)
         {
-            if (x == null || x.SignValue < 0)
+            if (x == null || x.SignValue < 0 || x.BitLength > 571)
                 throw new ArgumentException("value invalid for SecT571FieldElement", "x");
 
             this.x = SecT571Field.FromBigInteger(x);