ECParameters.Validate ECParameters.Validate ECParameters.Validate ECParameters.Validate Method

定义

验证当前对象。Validates the current object.

public:
 void Validate();
public void Validate ();
member this.Validate : unit -> unit
Public Sub Validate ()

异常

密钥或曲线参数对当前曲线类型无效。The key or curve parameters are not valid for the current curve type.

注解

方法检查ECParameters结构的完整性, CryptographicException在其无效时引发。 ValidateThe Validate method checks the integrity of the ECParameters structure, throwing a CryptographicException when it is not valid. 要求如下:The following are the requirements:

  • Q.XQ.X QYand Q.Y 是必填字段, 必须具有相同的长度。are required fields and must have the same length.

  • 如果曲线是显式曲线, D则是必需的, 并且其Curve长度Order必须与相同。If the curve is an explicit curve, D is required and must have the same length as Curve.Order.

  • 如果曲线是已命名曲线, D则是必需的, 并且其Q长度必须与相同。XIf the curve is a named curve, D is required and must have the same length as Q.X QYand Q.Y.

  • Curve.ValidateCurve.Validate 还必须成功。must also succeed.

适用于