ECDsa.TrySignDataCore Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Attempts to create the ECDSA signature for the specified data in the indicated format into the provided buffer.
protected:
virtual bool TrySignDataCore(ReadOnlySpan<System::Byte> data, Span<System::Byte> destination, System::Security::Cryptography::HashAlgorithmName hashAlgorithm, System::Security::Cryptography::DSASignatureFormat signatureFormat, [Runtime::InteropServices::Out] int % bytesWritten);
protected virtual bool TrySignDataCore (ReadOnlySpan<byte> data, Span<byte> destination, System.Security.Cryptography.HashAlgorithmName hashAlgorithm, System.Security.Cryptography.DSASignatureFormat signatureFormat, out int bytesWritten);
abstract member TrySignDataCore : ReadOnlySpan<byte> * Span<byte> * System.Security.Cryptography.HashAlgorithmName * System.Security.Cryptography.DSASignatureFormat * int -> bool
override this.TrySignDataCore : ReadOnlySpan<byte> * Span<byte> * System.Security.Cryptography.HashAlgorithmName * System.Security.Cryptography.DSASignatureFormat * int -> bool
Protected Overridable Function TrySignDataCore (data As ReadOnlySpan(Of Byte), destination As Span(Of Byte), hashAlgorithm As HashAlgorithmName, signatureFormat As DSASignatureFormat, ByRef bytesWritten As Integer) As Boolean
Parameters
- data
- ReadOnlySpan<Byte>
The data to hash and sign.
- hashAlgorithm
- HashAlgorithmName
The hash algorithm to use to create the hash value.
- signatureFormat
- DSASignatureFormat
The encoding format to use for the signature.
- bytesWritten
- Int32
When this method returns, contains a value that indicates the number of bytes written to destination
. This parameter is treated as uninitialized.
Returns
true
if destination
is big enough to receive the signature; otherwise, false
.
Exceptions
An error occurred in the signing operation.