Rfc3161TimestampRequest.CreateFromHash Metodo
Definizione
Importante
Alcune informazioni sono relative alla release non definitiva del prodotto, che potrebbe subire modifiche significative prima della release definitiva. Microsoft non riconosce alcuna garanzia, espressa o implicita, in merito alle informazioni qui fornite.
Overload
| Nome | Descrizione |
|---|---|
| CreateFromHash(ReadOnlyMemory<Byte>, HashAlgorithmName, Oid, Nullable<ReadOnlyMemory<Byte>>, Boolean, X509ExtensionCollection) |
Creare una richiesta di timestamp usando un valore hash precalcorato e il nome dell'algoritmo hash. |
| CreateFromHash(ReadOnlyMemory<Byte>, Oid, Oid, Nullable<ReadOnlyMemory<Byte>>, Boolean, X509ExtensionCollection) |
Creare una richiesta di timestamp usando un valore hash precalcorato e l'identificatore dell'oggetto per l'algoritmo hash. |
CreateFromHash(ReadOnlyMemory<Byte>, HashAlgorithmName, Oid, Nullable<ReadOnlyMemory<Byte>>, Boolean, X509ExtensionCollection)
- Origine:
- Rfc3161TimestampRequest.cs
- Origine:
- Rfc3161TimestampRequest.cs
- Origine:
- Rfc3161TimestampRequest.cs
- Origine:
- Rfc3161TimestampRequest.cs
- Origine:
- Rfc3161TimestampRequest.cs
- Origine:
- Rfc3161TimestampRequest.cs
- Origine:
- Rfc3161TimestampRequest.cs
- Origine:
- Rfc3161TimestampRequest.cs
- Origine:
- Rfc3161TimestampRequest.cs
Creare una richiesta di timestamp usando un valore hash precalcorato e il nome dell'algoritmo hash.
public static System.Security.Cryptography.Pkcs.Rfc3161TimestampRequest CreateFromHash(ReadOnlyMemory<byte> hash, System.Security.Cryptography.HashAlgorithmName hashAlgorithm, System.Security.Cryptography.Oid? requestedPolicyId = default, ReadOnlyMemory<byte>? nonce = default, bool requestSignerCertificates = false, System.Security.Cryptography.X509Certificates.X509ExtensionCollection? extensions = default);
public static System.Security.Cryptography.Pkcs.Rfc3161TimestampRequest CreateFromHash(ReadOnlyMemory<byte> hash, System.Security.Cryptography.HashAlgorithmName hashAlgorithm, System.Security.Cryptography.Oid requestedPolicyId = default, ReadOnlyMemory<byte>? nonce = default, bool requestSignerCertificates = false, System.Security.Cryptography.X509Certificates.X509ExtensionCollection extensions = default);
static member CreateFromHash : ReadOnlyMemory<byte> * System.Security.Cryptography.HashAlgorithmName * System.Security.Cryptography.Oid * Nullable<ReadOnlyMemory<byte>> * bool * System.Security.Cryptography.X509Certificates.X509ExtensionCollection -> System.Security.Cryptography.Pkcs.Rfc3161TimestampRequest
Public Shared Function CreateFromHash (hash As ReadOnlyMemory(Of Byte), hashAlgorithm As HashAlgorithmName, Optional requestedPolicyId As Oid = Nothing, Optional nonce As Nullable(Of ReadOnlyMemory(Of Byte)) = Nothing, Optional requestSignerCertificates As Boolean = false, Optional extensions As X509ExtensionCollection = Nothing) As Rfc3161TimestampRequest
Parametri
- hash
- ReadOnlyMemory<Byte>
Valore hash precalcorato da timestamp.
- hashAlgorithm
- HashAlgorithmName
Algoritmo hash utilizzato per produrre hash.
- requestedPolicyId
- Oid
Identificatore oggetto (OID) per i criteri di timestamp che l'autorità di timestamp (TSA) deve usare o null per non esprimere alcuna preferenza.
- nonce
- Nullable<ReadOnlyMemory<Byte>>
Valore facoltativo utilizzato per associare in modo univoco una richiesta a una risposta o null per non includere un nonce nella richiesta.
- requestSignerCertificates
- Boolean
true per indicare che l'autorità di timestamp (TSA) deve includere il certificato di firma nel token timestamp emesso; in caso contrario, false.
- extensions
- X509ExtensionCollection
Raccolta facoltativa di estensioni da includere nella richiesta.
Valori restituiti
Oggetto Rfc3161TimestampRequest che rappresenta i valori scelti.
Eccezioni
hashAlgorithm non è un algoritmo hash noto.
Commenti
Questo metodo usa il hashAlgorithm parametro per determinare l'identificatore dell'oggetto (OID) da includere nella richiesta di timestamp.
Quando si compila una richiesta per un timestamp basato su un algoritmo hash non supportato da questo metodo, usare l'overload CreateFromHash(ReadOnlyMemory<Byte>, Oid, Oid, Nullable<ReadOnlyMemory<Byte>>, Boolean, X509ExtensionCollection) .
Il valore nonce in questo metodo viene considerato come un intero big-endian senza segno. Questo metodo normalizza l'input in una codifica BER INTEGER prima di assegnare il valore nonce. Il valore normalizzato viene restituito dal GetNonce() metodo .
Vedi anche
- CreateFromData(ReadOnlySpan<Byte>, HashAlgorithmName, Oid, Nullable<ReadOnlyMemory<Byte>>, Boolean, X509ExtensionCollection)
- CreateFromHash(ReadOnlyMemory<Byte>, Oid, Oid, Nullable<ReadOnlyMemory<Byte>>, Boolean, X509ExtensionCollection)
Si applica a
CreateFromHash(ReadOnlyMemory<Byte>, Oid, Oid, Nullable<ReadOnlyMemory<Byte>>, Boolean, X509ExtensionCollection)
- Origine:
- Rfc3161TimestampRequest.cs
- Origine:
- Rfc3161TimestampRequest.cs
- Origine:
- Rfc3161TimestampRequest.cs
- Origine:
- Rfc3161TimestampRequest.cs
- Origine:
- Rfc3161TimestampRequest.cs
- Origine:
- Rfc3161TimestampRequest.cs
- Origine:
- Rfc3161TimestampRequest.cs
- Origine:
- Rfc3161TimestampRequest.cs
- Origine:
- Rfc3161TimestampRequest.cs
Creare una richiesta di timestamp usando un valore hash precalcorato e l'identificatore dell'oggetto per l'algoritmo hash.
public static System.Security.Cryptography.Pkcs.Rfc3161TimestampRequest CreateFromHash(ReadOnlyMemory<byte> hash, System.Security.Cryptography.Oid hashAlgorithmId, System.Security.Cryptography.Oid? requestedPolicyId = default, ReadOnlyMemory<byte>? nonce = default, bool requestSignerCertificates = false, System.Security.Cryptography.X509Certificates.X509ExtensionCollection? extensions = default);
public static System.Security.Cryptography.Pkcs.Rfc3161TimestampRequest CreateFromHash(ReadOnlyMemory<byte> hash, System.Security.Cryptography.Oid hashAlgorithmId, System.Security.Cryptography.Oid requestedPolicyId = default, ReadOnlyMemory<byte>? nonce = default, bool requestSignerCertificates = false, System.Security.Cryptography.X509Certificates.X509ExtensionCollection extensions = default);
static member CreateFromHash : ReadOnlyMemory<byte> * System.Security.Cryptography.Oid * System.Security.Cryptography.Oid * Nullable<ReadOnlyMemory<byte>> * bool * System.Security.Cryptography.X509Certificates.X509ExtensionCollection -> System.Security.Cryptography.Pkcs.Rfc3161TimestampRequest
Public Shared Function CreateFromHash (hash As ReadOnlyMemory(Of Byte), hashAlgorithmId As Oid, Optional requestedPolicyId As Oid = Nothing, Optional nonce As Nullable(Of ReadOnlyMemory(Of Byte)) = Nothing, Optional requestSignerCertificates As Boolean = false, Optional extensions As X509ExtensionCollection = Nothing) As Rfc3161TimestampRequest
Parametri
- hash
- ReadOnlyMemory<Byte>
Valore hash precalcorato da timestamp.
- hashAlgorithmId
- Oid
Identificatore dell'oggetto (OID) per l'algoritmo hash che ha prodotto hash.
- requestedPolicyId
- Oid
L'identificatore dell'oggetto (OID) per un criterio timestamp che l'autorità di timestamp (TSA) deve usare o null per non esprimere alcuna preferenza.
- nonce
- Nullable<ReadOnlyMemory<Byte>>
Un nonce facoltativo (numero usato una volta) per identificare in modo univoco questa richiesta per associarla alla risposta. Il valore viene interpretato come un intero big-endian senza segno e può essere normalizzato nel formato di codifica.
- requestSignerCertificates
- Boolean
true per indicare che l'autorità di timestamp (TSA) deve includere il certificato di firma nel token timestamp emesso; in caso contrario, false.
- extensions
- X509ExtensionCollection
Raccolta facoltativa di estensioni da includere nella richiesta.
Valori restituiti
Oggetto Rfc3161TimestampRequest che rappresenta i valori scelti.
Eccezioni
hashAlgorithmId è null.
hashAlgorithmId.Value non è un OID valido.
Commenti
Il valore nonce in questo metodo viene considerato come un intero big-endian senza segno. Questo metodo normalizza l'input in una codifica BER INTEGER prima di assegnare il valore nonce. Il valore normalizzato viene restituito dal GetNonce() metodo .