แก้ไข

แชร์ผ่าน


SignedXml.GetPublicKey Method

Definition

Returns the public key of a signature.

protected:
 virtual System::Security::Cryptography::AsymmetricAlgorithm ^ GetPublicKey();
protected virtual System.Security.Cryptography.AsymmetricAlgorithm? GetPublicKey ();
protected virtual System.Security.Cryptography.AsymmetricAlgorithm GetPublicKey ();
abstract member GetPublicKey : unit -> System.Security.Cryptography.AsymmetricAlgorithm
override this.GetPublicKey : unit -> System.Security.Cryptography.AsymmetricAlgorithm
Protected Overridable Function GetPublicKey () As AsymmetricAlgorithm

Returns

An AsymmetricAlgorithm object that contains the public key of the signature, or null if the key cannot be found.

Exceptions

The KeyInfo property is null.

Remarks

The GetPublicKey method returns an AsymmetricAlgorithm object that contains a public key that can be used to verify an XML digital signature.

The key must be either a DSA or an RSA key.

Applies to