语言

DSAOpenSsl 构造函数

定义

初始化 DSAOpenSsl 类的新实例。

重载

名称 说明
DSAOpenSsl()

使用默认密钥大小为 2048 位初始化类的新实例 DSAOpenSsl 。

DSAOpenSsl(Int32)

使用指定的键大小初始化类的新实例 DSAOpenSsl 。

DSAOpenSsl(IntPtr)

从表示为 a DSAOpenSsl的现有 OpenSSL 键初始化类的新实例DSA*。

DSAOpenSsl(DSAParameters)

初始化类的新实例 DSAOpenSsl ,并从现有键导入参数。

DSAOpenSsl(SafeEvpPKeyHandle)

从表示为 <a0/a0> 的现有 OpenSSL 键初始化类的新实例。

DSAOpenSsl()

Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs

使用默认密钥大小为 2048 位初始化类的新实例 DSAOpenSsl 。

public:
 DSAOpenSsl();
[System.Runtime.Versioning.UnsupportedOSPlatform("android")]
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
[System.Runtime.Versioning.UnsupportedOSPlatform("ios")]
[System.Runtime.Versioning.UnsupportedOSPlatform("tvos")]
[System.Runtime.Versioning.UnsupportedOSPlatform("windows")]
public DSAOpenSsl();
public DSAOpenSsl();
Public Sub New ()
特性

注解

此构造函数不会立即生成新的 DSA 公钥/私钥对,它只会设置在需要密钥时用于生成密钥的大小。 如果密钥是通过 ImportParameters 该方法或其他键导入方法加载的,则此构造函数中的密钥大小没有任何意义。

另请参阅

适用于

DSAOpenSsl(Int32)

Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs

使用指定的键大小初始化类的新实例 DSAOpenSsl 。

public:
 DSAOpenSsl(int keySize);
[System.Runtime.Versioning.UnsupportedOSPlatform("android")]
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
[System.Runtime.Versioning.UnsupportedOSPlatform("ios")]
[System.Runtime.Versioning.UnsupportedOSPlatform("tvos")]
[System.Runtime.Versioning.UnsupportedOSPlatform("windows")]
public DSAOpenSsl(int keySize);
public DSAOpenSsl(int keySize);
[<System.Runtime.Versioning.UnsupportedOSPlatform("android")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("browser")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("ios")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("tvos")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("windows")>]
new System.Security.Cryptography.DSAOpenSsl : int -> System.Security.Cryptography.DSAOpenSsl
new System.Security.Cryptography.DSAOpenSsl : int -> System.Security.Cryptography.DSAOpenSsl
Public Sub New (keySize As Integer)

参数

keySize
Int32
特性

例外

此 keySize 实现不支持该值。

注解

此构造函数不会立即生成新的 DSA 公钥/私钥对,它只会设置在需要密钥时用于生成密钥的大小。 如果通过 ImportParameters 方法或其他密钥导入方法加载密钥,则 keySize 提供给此构造函数的密钥没有意义。

另请参阅

适用于

DSAOpenSsl(IntPtr)

Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs

从表示为 a DSAOpenSsl的现有 OpenSSL 键初始化类的新实例DSA*。

public:
 DSAOpenSsl(IntPtr handle);
[System.Runtime.Versioning.UnsupportedOSPlatform("android")]
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
[System.Runtime.Versioning.UnsupportedOSPlatform("ios")]
[System.Runtime.Versioning.UnsupportedOSPlatform("tvos")]
[System.Runtime.Versioning.UnsupportedOSPlatform("windows")]
public DSAOpenSsl(IntPtr handle);
public DSAOpenSsl(IntPtr handle);
[<System.Runtime.Versioning.UnsupportedOSPlatform("android")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("browser")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("ios")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("tvos")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("windows")>]
new System.Security.Cryptography.DSAOpenSsl : nativeint -> System.Security.Cryptography.DSAOpenSsl
new System.Security.Cryptography.DSAOpenSsl : nativeint -> System.Security.Cryptography.DSAOpenSsl
Public Sub New (handle As IntPtr)

参数

handle
IntPtr

nativeint

特性

例外

handle 是 Zero。

handle 不是有效的 DSA*。

注解

Important

OpenSSL 支持在同一进程中加载多个库版本。 在调用此构造函数之前,请验证指针值是否来自此类使用的相同版本的 OpenSSL。 有关详细信息,请参阅 OpenSslVersion。

另请参阅

适用于

DSAOpenSsl(DSAParameters)

Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs

初始化类的新实例 DSAOpenSsl ,并从现有键导入参数。

public:
 DSAOpenSsl(System::Security::Cryptography::DSAParameters parameters);
[System.Runtime.Versioning.UnsupportedOSPlatform("android")]
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
[System.Runtime.Versioning.UnsupportedOSPlatform("ios")]
[System.Runtime.Versioning.UnsupportedOSPlatform("tvos")]
[System.Runtime.Versioning.UnsupportedOSPlatform("windows")]
public DSAOpenSsl(System.Security.Cryptography.DSAParameters parameters);
public DSAOpenSsl(System.Security.Cryptography.DSAParameters parameters);
[<System.Runtime.Versioning.UnsupportedOSPlatform("android")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("browser")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("ios")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("tvos")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("windows")>]
new System.Security.Cryptography.DSAOpenSsl : System.Security.Cryptography.DSAParameters -> System.Security.Cryptography.DSAOpenSsl
new System.Security.Cryptography.DSAOpenSsl : System.Security.Cryptography.DSAParameters -> System.Security.Cryptography.DSAOpenSsl
Public Sub New (parameters As DSAParameters)

参数

parameters
DSAParameters
特性

例外

parameters 缺少必填字段。

-或者-

parameters 具有有效密钥长度不一致的字段。

parameters 不表示有效的 DSA 密钥参数集。

另请参阅

适用于

DSAOpenSsl(SafeEvpPKeyHandle)

Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs
Source:
DSAOpenSsl.cs

从表示为 <a0/a0> 的现有 OpenSSL 键初始化类的新实例。

public:
 DSAOpenSsl(System::Security::Cryptography::SafeEvpPKeyHandle ^ pkeyHandle);
[System.Runtime.Versioning.UnsupportedOSPlatform("android")]
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
[System.Runtime.Versioning.UnsupportedOSPlatform("ios")]
[System.Runtime.Versioning.UnsupportedOSPlatform("tvos")]
[System.Runtime.Versioning.UnsupportedOSPlatform("windows")]
public DSAOpenSsl(System.Security.Cryptography.SafeEvpPKeyHandle pkeyHandle);
public DSAOpenSsl(System.Security.Cryptography.SafeEvpPKeyHandle pkeyHandle);
[<System.Runtime.Versioning.UnsupportedOSPlatform("android")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("browser")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("ios")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("tvos")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("windows")>]
new System.Security.Cryptography.DSAOpenSsl : System.Security.Cryptography.SafeEvpPKeyHandle -> System.Security.Cryptography.DSAOpenSsl
new System.Security.Cryptography.DSAOpenSsl : System.Security.Cryptography.SafeEvpPKeyHandle -> System.Security.Cryptography.DSAOpenSsl
Public Sub New (pkeyHandle As SafeEvpPKeyHandle)

参数

pkeyHandle
SafeEvpPKeyHandle
特性

例外

pkeyHandle 表示无效的句柄。

pkeyHandle 是 null。

pkeyHandle 不表示 DSA 密钥。

注解

Important

OpenSSL 支持在同一进程中加载多个库版本。 在调用此构造函数之前,请验证指针值是否来自此类使用的相同版本的 OpenSSL。 有关详细信息,请参阅 OpenSslVersion。

另请参阅

适用于