Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]
Defines a wrapper object to access the cryptographic service provider (CSP) implementation of the DSA algorithm. This class cannot be inherited.
Inheritance Hierarchy
System. . :: . .Object
Microsoft.SPOT.Cryptoki. . :: . .SessionContainer
System.Security.Cryptography. . :: . .AsymmetricAlgorithm
System.Security.Cryptography..::..DSACryptoServiceProvider
Namespace: System.Security.Cryptography
Assembly: System.Security (in System.Security.dll)
Syntax
'Declaration
Public NotInheritable Class DSACryptoServiceProvider _
Inherits AsymmetricAlgorithm
public sealed class DSACryptoServiceProvider : AsymmetricAlgorithm
public ref class DSACryptoServiceProvider sealed : public AsymmetricAlgorithm
[<Sealed>]
type DSACryptoServiceProvider =
class
inherit AsymmetricAlgorithm
end
public final class DSACryptoServiceProvider extends AsymmetricAlgorithm
The DSACryptoServiceProvider type exposes the following members.
Constructors
Name | Description | |
---|---|---|
![]() |
DSACryptoServiceProvider(CryptoKey) | Initializes a new instance of the DSACryptoServiceProvider class with the specified key. |
![]() |
DSACryptoServiceProvider(Int32) | Initializes a new instance of the DSACryptoServiceProvider class with the specified key size. |
![]() |
DSACryptoServiceProvider(Session, Int32) | Initializes a new instance of the DSACryptoServiceProvider class with the specified session and key size. |
![]() |
DSACryptoServiceProvider(String, Int32) | Initializes a new instance of the DSACryptoServiceProvider class with the specified service provider name and key size. |
Top
Properties
Name | Description | |
---|---|---|
![]() |
HashAlgorithm | Gets or sets the hash algorithm to use when generating a signature for the data. |
![]() |
IsDisposed | (Inherited from SessionContainer.) |
![]() |
KeyPair | Gets or sets the CryptoKey object representing the key pair for the asymmetric algorithm. (Inherited from AsymmetricAlgorithm.) |
![]() |
KeySize | Gets or sets the size, in bits, of the key modulus used by the asymmetric algorithm. (Inherited from AsymmetricAlgorithm.) |
![]() |
LegalKeySizes | Gets the key sizes that are supported by the asymmetric algorithm. (Inherited from AsymmetricAlgorithm.) |
![]() |
PublicOnly | Gets a value that indicates whether the DSACryptoServiceProvider object contains only a public key. |
![]() |
Session | (Inherited from SessionContainer.) |
Top
Methods
Name | Description | |
---|---|---|
![]() |
Clear | Releases all resources used by the AsymmetricAlgorithm class. (Inherited from AsymmetricAlgorithm.) |
![]() |
CreateSignature | Creates the DSA signature for the specified data. |
![]() |
Dispose() () () () | (Inherited from SessionContainer.) |
![]() |
Equals(Object) | Determines whether the specified Object is equal to the current Object. (Inherited from Object.) |
![]() |
ExportParameters | Exports the DSAParameters. |
![]() |
GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) |
![]() |
GetType | Gets the Type of the current instance. (Inherited from Object.) |
![]() |
ImportParameters | Imports the specified DSAParameters. |
![]() |
SignData(array<Byte> [] () [] []) | Computes the hash value of the specified byte array and signs the resulting hash value. |
![]() |
SignData(Stream) | Computes the hash value of the specified input stream and signs the resulting hash value. |
![]() |
SignData(array<Byte> [] () [] [], Int32, Int32) | Signs a byte array from the specified start point to the specified end point. |
![]() |
SignHash | Computes the signature for the specified hash value by encrypting it with the private key. |
![]() |
ToString | Returns a string that represents the current object. (Inherited from Object.) |
![]() |
VerifyData | Verifies the specified signature data by comparing it to the signature computed for the specified data. |
![]() |
VerifyHash | Verifies the specified signature data by comparing it to the signature computed for the specified hash value. |
![]() |
VerifySignature | Verifies the DSA signature for the specified data. |
Top
Fields
Name | Description | |
---|---|---|
![]() ![]() |
DefaultKeySize | Specifies the size, in bits, to use for the key size if one is not provided. |
Top
Remarks
You can use the DSACryptoServiceProvider class to create digital signatures and protect the integrity of your data.
To use a public-key system to digitally sign a message, the sender first applies a hash function to the message to create a message digest. The sender then encrypts the message digest with the sender's private key to create the sender's personal signature. Upon receiving the message and signature, the receiver decrypts the signature using the sender's public key to recover the message digest and hashes the message using the same hash algorithm that the sender used. If the message digest that the receiver computes exactly matches the message digest received from the sender, the receiver can be sure that the message was not altered while in transit. Note that a signature can be verified by anyone, because the sender's public key is common knowledge.
This algorithm supports key lengths from 512 bits to 1024 bits in increments of 64 bits.
Thread Safety
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.