diff --git a/xml/Microsoft.Extensions.Compliance.Redaction/HmacRedactor.xml b/xml/Microsoft.Extensions.Compliance.Redaction/HmacRedactor.xml index 999a534ffec..7a89b1b9f36 100644 --- a/xml/Microsoft.Extensions.Compliance.Redaction/HmacRedactor.xml +++ b/xml/Microsoft.Extensions.Compliance.Redaction/HmacRedactor.xml @@ -24,9 +24,7 @@ - - A redactor using HMACSHA256 to encode data being redacted. - + Represents a redactor that uses HMAC SHA-256 to encode redacted data. To be added. diff --git a/xml/System.CodeDom/CodeChecksumPragma.xml b/xml/System.CodeDom/CodeChecksumPragma.xml index e6d8f6c2ec6..2b20205e24b 100644 --- a/xml/System.CodeDom/CodeChecksumPragma.xml +++ b/xml/System.CodeDom/CodeChecksumPragma.xml @@ -47,19 +47,19 @@ Represents a code checksum pragma code entity. - class inherits from and can be contained in a . provides the unique identification of source files, including files that have been generated. - - - -## Examples - The following code example shows the use of the class. - + class inherits from and can be contained in a . provides the unique identification of source files, including files that have been generated. + + + +## Examples + The following code example shows the use of the class. + :::code language="csharp" source="~/snippets/csharp/System.CodeDom/CodeChecksumPragma/Overview/codedirective.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.CodeDom.CodeDirectives/VB/codedirective.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.CodeDom.CodeDirectives/VB/codedirective.vb" id="Snippet1"::: + ]]> @@ -106,14 +106,14 @@ Initializes a new instance of the class. - constructor. This code example is part of a larger example provided for the class. - + constructor. This code example is part of a larger example provided for the class. + :::code language="csharp" source="~/snippets/csharp/System.CodeDom/CodeChecksumPragma/Overview/codedirective.cs" id="Snippet4"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.CodeDom.CodeDirectives/VB/codedirective.vb" id="Snippet4"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.CodeDom.CodeDirectives/VB/codedirective.vb" id="Snippet4"::: + ]]> @@ -159,19 +159,19 @@ A byte array that contains the checksum data. Initializes a new instance of the class using a file name, a GUID representing the checksum algorithm, and a byte stream representing the checksum data. - property. - - - -## Examples - The following code example shows the use of the constructor. This code example is part of a larger example provided for the class. - + property. + + + +## Examples + The following code example shows the use of the constructor. This code example is part of a larger example provided for the class. + :::code language="csharp" source="~/snippets/csharp/System.CodeDom/CodeChecksumPragma/Overview/codedirective.cs" id="Snippet8"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.CodeDom.CodeDirectives/VB/codedirective.vb" id="Snippet8"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.CodeDom.CodeDirectives/VB/codedirective.vb" id="Snippet8"::: + ]]> @@ -217,21 +217,22 @@ Gets or sets a GUID that identifies the checksum algorithm to use. A that identifies the checksum algorithm to use. - property. This code example is part of a larger example provided for the class. - + property. This code example is part of a larger example provided for the class. + :::code language="csharp" source="~/snippets/csharp/System.CodeDom/CodeChecksumPragma/Overview/codedirective.cs" id="Snippet6"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.CodeDom.CodeDirectives/VB/codedirective.vb" id="Snippet6"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.CodeDom.CodeDirectives/VB/codedirective.vb" id="Snippet6"::: + ]]> @@ -277,19 +278,19 @@ Gets or sets the value of the data for the checksum calculation. A byte array that contains the data for the checksum calculation. - property contains data from the target file specified by the property. - - - -## Examples - The following code example shows the setting of the property. This code example is part of a larger example provided for the class - + property contains data from the target file specified by the property. + + + +## Examples + The following code example shows the setting of the property. This code example is part of a larger example provided for the class + :::code language="csharp" source="~/snippets/csharp/System.CodeDom/CodeChecksumPragma/Overview/codedirective.cs" id="Snippet7"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.CodeDom.CodeDirectives/VB/codedirective.vb" id="Snippet7"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.CodeDom.CodeDirectives/VB/codedirective.vb" id="Snippet7"::: + ]]> @@ -331,19 +332,19 @@ Gets or sets the path to the checksum file. The path to the checksum file. - property value is "C:\Temp\Test\OuterLinePragma.txt". - - - -## Examples - The following code example shows the setting of the property. This code example is part of a larger example provided for the class - + property value is "C:\Temp\Test\OuterLinePragma.txt". + + + +## Examples + The following code example shows the setting of the property. This code example is part of a larger example provided for the class + :::code language="csharp" source="~/snippets/csharp/System.CodeDom/CodeChecksumPragma/Overview/codedirective.cs" id="Snippet5"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.CodeDom.CodeDirectives/VB/codedirective.vb" id="Snippet5"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.CodeDom.CodeDirectives/VB/codedirective.vb" id="Snippet5"::: + ]]> diff --git a/xml/System.Configuration.Assemblies/AssemblyHashAlgorithm.xml b/xml/System.Configuration.Assemblies/AssemblyHashAlgorithm.xml index 1a28cb60176..b325d62c8bb 100644 --- a/xml/System.Configuration.Assemblies/AssemblyHashAlgorithm.xml +++ b/xml/System.Configuration.Assemblies/AssemblyHashAlgorithm.xml @@ -54,25 +54,25 @@ Specifies all the hash algorithms used for hashing files and for generating the strong name. - @@ -154,7 +154,7 @@ 0 - A mask indicating that there is no hash algorithm. If you specify for a multi-module assembly, the common language runtime defaults to the SHA1 algorithm, since multi-module assemblies need to generate a hash. Due to collision problems with SHA1, Microsoft recommends SHA256. + A mask indicating that there is no hash algorithm. If you specify for a multi-module assembly, the common language runtime defaults to the SHA-1 algorithm, since multi-module assemblies need to generate a hash. Due to collision problems with SHA-1, Microsoft recommends SHA-256. diff --git a/xml/System.IO.Packaging/PackageDigitalSignatureManager.xml b/xml/System.IO.Packaging/PackageDigitalSignatureManager.xml index 91fb7db3a2a..97f7f906004 100644 --- a/xml/System.IO.Packaging/PackageDigitalSignatureManager.xml +++ b/xml/System.IO.Packaging/PackageDigitalSignatureManager.xml @@ -273,13 +273,13 @@ This property specifies where the signer's X.509 certificate will be stored when class is (Secure Hash Algorithm version 1.0 (SHA1)). + The default hash algorithm for the standard class is (Secure Hash Algorithm version 1.0, or SHA-1). The property gets or sets the actual hash algorithm this is used to create and verify signatures. The property is typically used to reset the property back to default after a temporary change. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> @@ -360,7 +360,7 @@ This property specifies where the signer's X.509 certificate will be stored when The property is typically not changed from its default. This property must be changed only if a signature that uses a different known and accessible is encountered. When finished with the signature that uses a different hash algorithm, call to reset the property back to default. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> diff --git a/xml/System.IdentityModel.Tokens/InMemorySymmetricSecurityKey.xml b/xml/System.IdentityModel.Tokens/InMemorySymmetricSecurityKey.xml index 82d0b213d0c..d9119f4dc12 100644 --- a/xml/System.IdentityModel.Tokens/InMemorySymmetricSecurityKey.xml +++ b/xml/System.IdentityModel.Tokens/InMemorySymmetricSecurityKey.xml @@ -17,11 +17,11 @@ Represents keys that are generated using symmetric algorithms and are only stored in the local computer's random access memory. - @@ -116,11 +116,11 @@ Decrypts the specified encrypted key. An array of that contains the decrypted key. - class to specify the algorithm. - + class to specify the algorithm. + ]]> @@ -153,11 +153,11 @@ Encrypts the specified key. An array of that contains the encrypted key. - class to specify the algorithm. - + class to specify the algorithm. + ]]> @@ -196,12 +196,12 @@ Generates a derived key using the specified cryptographic algorithm and parameters for the current key. An array of that contains the derived key. - field. + field. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> @@ -235,11 +235,11 @@ Gets a transform that decrypts cipher text using the specified cryptographic algorithm. An that represents the decryption transform. - class to specify the algorithm. - + class to specify the algorithm. + ]]> @@ -272,11 +272,11 @@ Gets a transform that encrypts XML using the specified cryptographic algorithm. An that represents the encryption transform. - class to specify the algorithm. - + class to specify the algorithm. + ]]> @@ -307,11 +307,11 @@ Gets the size, in bits, of the initialization vector () that is required for the specified cryptographic algorithm. The size, in bits, of the initialization vector () that is required for the cryptographic algorithm specified in the parameter. - class to specify the algorithm. - + class to specify the algorithm. + ]]> @@ -449,31 +449,31 @@ when the specified algorithm is supported by this class; otherwise, . - - -- - -- - -- - -- - -- - -- - -- - -- - -- - + + +- + +- + +- + +- + +- + +- + +- + +- + +- + ]]> diff --git a/xml/System.IdentityModel.Tokens/SecurityAlgorithms.xml b/xml/System.IdentityModel.Tokens/SecurityAlgorithms.xml index 5f6be2977bd..eb65d9b36ec 100644 --- a/xml/System.IdentityModel.Tokens/SecurityAlgorithms.xml +++ b/xml/System.IdentityModel.Tokens/SecurityAlgorithms.xml @@ -403,7 +403,7 @@ Represents the P-SHA1 key generation algorithm. This field is constant. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. @@ -432,7 +432,7 @@ Represents the December 2007 version of the P-SHA1 key generation algorithm. This field is constant. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. @@ -519,7 +519,7 @@ Specifies a URI that points to the RSA-SHA1 cryptographic algorithm for digitally signing XML. This field is constant. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. @@ -606,7 +606,7 @@ Specifies a URI that points to the 160-bit SHA-1 digest algorithm. This field is constant. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. diff --git a/xml/System.IdentityModel.Tokens/SymmetricSecurityKey.xml b/xml/System.IdentityModel.Tokens/SymmetricSecurityKey.xml index e22597c9c07..da3ac188712 100644 --- a/xml/System.IdentityModel.Tokens/SymmetricSecurityKey.xml +++ b/xml/System.IdentityModel.Tokens/SymmetricSecurityKey.xml @@ -118,7 +118,7 @@ ## Remarks To specify P-SHA1 as the cryptographic algorithm, use the field. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> diff --git a/xml/System.IdentityModel.Tokens/X509AsymmetricSecurityKey.xml b/xml/System.IdentityModel.Tokens/X509AsymmetricSecurityKey.xml index eac498383d3..7ec26882d13 100644 --- a/xml/System.IdentityModel.Tokens/X509AsymmetricSecurityKey.xml +++ b/xml/System.IdentityModel.Tokens/X509AsymmetricSecurityKey.xml @@ -95,25 +95,25 @@ Decrypts the specified encrypted key using the specified cryptographic algorithm. An array of that contains the decrypted key. - or fields to specify the algorithm. - + or fields to specify the algorithm. + ]]> - The X.509 certificate specified in the constructor does not have a private key. - - -or- - - The X.509 certificate has a private key, but it was not generated using the algorithm. - - -or- - - The X.509 certificate has a private key, it was generated using the algorithm, but the property is . - - -or- - + The X.509 certificate specified in the constructor does not have a private key. + + -or- + + The X.509 certificate has a private key, but it was not generated using the algorithm. + + -or- + + The X.509 certificate has a private key, it was generated using the algorithm, but the property is . + + -or- + The parameter is not supported. The supported algorithms are and . @@ -151,17 +151,17 @@ Encrypts the specified encrypted key using the specified cryptographic algorithm. An array of that contains the encrypted key. - or fields to specify the algorithm. - + or fields to specify the algorithm. + ]]> - The X.509 certificate specified in the constructor has a public key that was not generated using the algorithm. - - -or- - + The X.509 certificate specified in the constructor has a public key that was not generated using the algorithm. + + -or- + The parameter is not supported. The supported algorithms are and . @@ -200,28 +200,28 @@ Gets the specified asymmetric cryptographic algorithm. An that represents the specified asymmetric cryptographic algorithm. - , , , or fields to specify the `algorithm` parameter. + , , , or fields to specify the `algorithm` parameter. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> - is and the X.509 certificate specified in the constructor does not have a private key. - - -or- - - is and the public or private key for the X.509 certificate specified in the constructor is not of type . - - -or- - - is , , or and the public or private key for the X.509 certificate specified in the constructor is not of type . - - -or- - + is and the X.509 certificate specified in the constructor does not have a private key. + + -or- + + is and the public or private key for the X.509 certificate specified in the constructor is not of type . + + -or- + + is , , or and the public or private key for the X.509 certificate specified in the constructor is not of type . + + -or- + is not supported. The supported algorithms are , , , , and . @@ -257,12 +257,12 @@ Gets a cryptographic algorithm that generates a hash for a digital signature. A that generates hashes for digital signatures. - , or fields to specify the `algorithm` parameter. + , or fields to specify the `algorithm` parameter. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> @@ -302,24 +302,24 @@ Gets the de-formatter algorithm for the digital signature. An that represents the de-formatter algorithm for the digital signature. - , or fields to specify the `algorithm` parameter. - + , or fields to specify the `algorithm` parameter. + ]]> - is and the public key for the X.509 certificate specified in the constructor is not of type . - - -or- - - is or and the public key for the X.509 certificate specified in the constructor is not of type . - - -or- - - is not supported. The supported algorithms are , - + is and the public key for the X.509 certificate specified in the constructor is not of type . + + -or- + + is or and the public key for the X.509 certificate specified in the constructor is not of type . + + -or- + + is not supported. The supported algorithms are , + , and . @@ -355,29 +355,29 @@ Gets the formatter algorithm for the digital signature. An that represents the formatter algorithm for the digital signature. - , or fields to specify the `algorithm` parameter. + , or fields to specify the `algorithm` parameter. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> - The X.509 certificate specified in the constructor does not have a private key. - - -or- - - is and the private key for the X.509 certificate specified in the constructor is not of type . - - -or- - - is or and the private key for the X.509 certificate specified in the constructor is not of type . - - -or- - - is not supported. The supported algorithms are , - + The X.509 certificate specified in the constructor does not have a private key. + + -or- + + is and the private key for the X.509 certificate specified in the constructor is not of type . + + -or- + + is or and the private key for the X.509 certificate specified in the constructor is not of type . + + -or- + + is not supported. The supported algorithms are , + , and . @@ -445,7 +445,7 @@ Gets a value that indicates whether the specified algorithm uses asymmetric keys. when the specified algorithm is , , , , or ; otherwise, . - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. @@ -481,16 +481,16 @@ when the specified algorithm is , , , , or and the public key is of the right type; otherwise, . - method returns `true` when one of the following is true: - -- The `algorithm` parameter is and the public key for the X.509 certificate specified in the constructor is of type . - -- The `algorithm` parameter is , , or and the public key for the X.509 certificate specified in the constructor is of type . - -Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + method returns `true` when one of the following is true: + +- The `algorithm` parameter is and the public key for the X.509 certificate specified in the constructor is of type . + +- The `algorithm` parameter is , , or and the public key for the X.509 certificate specified in the constructor is of type . + +Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> diff --git a/xml/System.IdentityModel/RsaEncryptionCookieTransform.xml b/xml/System.IdentityModel/RsaEncryptionCookieTransform.xml index a9ff481e97f..9cee1607a3c 100644 --- a/xml/System.IdentityModel/RsaEncryptionCookieTransform.xml +++ b/xml/System.IdentityModel/RsaEncryptionCookieTransform.xml @@ -16,16 +16,16 @@ Encrypts a cookie using . - [!IMPORTANT] -> When using the with a service, if a key provided by a certificate changes the service must be restarted. - +> When using the with a service, if a key provided by a certificate changes the service must be restarted. + ]]> @@ -79,18 +79,18 @@ - The certificate whose private key is used to encrypt and decrypt. - + The certificate whose private key is used to encrypt and decrypt. + The certificate whose private key will be used as the default encryption and decryption key. Initializes the and properties. Initializes a new instance of the class that uses the private key of the specified X.509 certificate for encryption and decryption. To be added. is . - does not have a private key. - - -or- - + does not have a private key. + + -or- + The private key is not RSA. @@ -195,11 +195,11 @@ Gets or sets the RSA key used for encryption. The RSA key used for encryption. - property to a collection that contains the same key as its only element. - + property to a collection that contains the same key as its only element. + ]]> @@ -221,17 +221,16 @@ Gets or sets the name of the hash algorithm to use. - The name of the hash algorithm to use. The default is "SHA2566". + The name of the hash algorithm to use. The default is "SHA256". - property to "SHA1". + property to "SHA1". + + Due to collision problems with SHA-1, Microsoft recommends SHA-256 or better. - Due to collision problems with SHA1, Microsoft recommends SHA256 or better. - ]]> diff --git a/xml/System.IdentityModel/RsaSignatureCookieTransform.xml b/xml/System.IdentityModel/RsaSignatureCookieTransform.xml index cee8e24e39f..207245a3b18 100644 --- a/xml/System.IdentityModel/RsaSignatureCookieTransform.xml +++ b/xml/System.IdentityModel/RsaSignatureCookieTransform.xml @@ -16,16 +16,16 @@ Provides cookie integrity using an signature. - adds an RSA MAC to the cookie data. This provides integrity but not confidentiality. By default, the MAC uses SHA-256, but SHA-1 may be requested. - - Cookies protected with this transform may be read by any computer that shares the same RSA private key (generally associated with an X509 certificate). - + adds an RSA MAC to the cookie data. This provides integrity but not confidentiality. By default, the MAC uses SHA-256, but SHA-1 may be requested. + + Cookies protected with this transform may be read by any computer that shares the same RSA private key (generally associated with an X509 certificate). + > [!IMPORTANT] -> When using the with a service, if a key provided by a certificate changes the service must be restarted. - +> When using the with a service, if a key provided by a certificate changes the service must be restarted. + ]]> @@ -59,11 +59,11 @@ The RSA key to use as the default signing and verification key. Initializes a new instance of the class by using the specified RSA key. - property is initialized to `key`. The property is initialized to a collection that contains `key` as its only element. - + property is initialized to `key`. The property is initialized to a collection that contains `key` as its only element. + ]]> @@ -89,20 +89,20 @@ The certificate whose private key is to be used for signing and verifying. Initializes a new instance of the class by using the private key of the specified certificate. - property is initialized to private key of the certificate. The property is initialized to a collection that contains the private key of the certificate as its only element. - + property is initialized to private key of the certificate. The property is initialized to a collection that contains the private key of the certificate as its only element. + ]]> is . - has no private key - - -or- - + has no private key + + -or- + The private key of the is not an RSA key. @@ -129,11 +129,11 @@ Verifies the specified signature and returns the original, unsigned data. The original data (unsigned). - property are tried. - + property are tried. + ]]> @@ -169,27 +169,27 @@ Signs the specified data. The signed data. - property must include the private key in order to sign the data. - - The signed data may be verified by calling the method. - + property must include the private key in order to sign the data. + + The signed data may be verified by calling the method. + ]]> is . contains zero bytes. - The property is . - - -or- - - The key specified by the property is not assignable as . - - -or- - + The property is . + + -or- + + The key specified by the property is not assignable as . + + -or- + The key specified by the property does not contain a private key. The operating system does not support the specified algorithm. @@ -213,14 +213,13 @@ Gets or sets the name of the hash algorithm to use. The name of the hash algorithm. The default is "SHA256". - property to "SHA1". + property to "SHA1". + + Due to collision problems with SHA-1, Microsoft recommends SHA-256 or better. ]]> @@ -263,8 +262,8 @@ System.Collections.ObjectModel.ReadOnlyCollection<System.Security.Cryptography.RSA> - Gets the collection of keys used for signature verification. - + Gets the collection of keys used for signature verification. + By default, this property returns a list that contains only the signing key. The collection of keys used for signature verification. To be added. diff --git a/xml/System.Messaging/DefaultPropertiesToSend.xml b/xml/System.Messaging/DefaultPropertiesToSend.xml index dac58721f75..fd1d8929dcf 100644 --- a/xml/System.Messaging/DefaultPropertiesToSend.xml +++ b/xml/System.Messaging/DefaultPropertiesToSend.xml @@ -24,24 +24,24 @@ Specifies the default property values that will be used when sending objects other than instances to a message queue. - . is used to specify default property values of the message being sent when objects other than instances are sent to a queue, for example, the string argument passed into the method in the code fragment, `myMessageQueue.Send("hello")`. The class has corresponding, identically named properties to those in that provide the values when sending a instance specifically. Even if you have specified for a queue, sending a object to that queue will cause the values for the identically named properties to override the queue's values. - - Properties that you do not set explicitly default to the values specified by the constructor, . - - For a list of initial property values for an instance of , see the constructor. - - - -## Examples - The following code example uses the priority of a message to determine default properties to send for the message. - + . is used to specify default property values of the message being sent when objects other than instances are sent to a queue, for example, the string argument passed into the method in the code fragment, `myMessageQueue.Send("hello")`. The class has corresponding, identically named properties to those in that provide the values when sending a instance specifically. Even if you have specified for a queue, sending a object to that queue will cause the values for the identically named properties to override the queue's values. + + Properties that you do not set explicitly default to the values specified by the constructor, . + + For a list of initial property values for an instance of , see the constructor. + + + +## Examples + The following code example uses the priority of a message to determine default properties to send for the message. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/MessageQueue.DefaultPropertiesToSend/CPP/mqdefaultpropertiestosend.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Messaging/DefaultPropertiesToSend/Overview/mqdefaultpropertiestosend.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/MessageQueue.DefaultPropertiesToSend/VB/mqdefaultpropertiestosend.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/MessageQueue.DefaultPropertiesToSend/VB/mqdefaultpropertiestosend.vb" id="Snippet1"::: + ]]> @@ -65,58 +65,58 @@ Initializes a new instance of the class. - to define default property values to associate with objects sent to a queue that are not of type . When working with objects, a instance is created for you and associated with the member of the . - - There are two ways to define a queue's default properties to send, as shown in the following C# code. You can set values for this instance of and associate it with the queue's property: - -``` -DefaultPropertiesToSend myDefaultProperties = new DefaultPropertiesToSend(); - // Set default values for the properties. - myDefaultProperties.Label = "myLabel"; - myDefaultProperties.Recoverable = false; - ... - myMessageQueue.DefaultPropertiesToSend = myDefaultProperties; - myMessageQueue.Send("hello"); -``` - - Or, you can individually assign values to the instance's property directly: - -``` -myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; - myMessageQueue.DefaultPropertiesToSend.Recoverable = false; -... - myMessageQueue.Send("hello"); -``` - - If you choose the second of these options, you do not need to call the constructor explicitly. You might want to create instances of , for example, if the properties' default values depend on some criterion of the message being sent. You can create multiple instances and assign one to the queue's property before sending the message to the queue. - - The following table shows initial property values for an instance of . - -|Property|Initial value| -|--------------|-------------------| -||`AcknowledgeTypes.None`| -||`null`| -||0| -||`true`| -||`EncryptionAlgorithm.RC2`| -||A zero-length array of bytes| -||`HashAlgorithm.MD5`| -||An empty string ("")| -||`MessagePriority.Normal`| -||`false`| -||`null`| -||`Message.InfiniteTimeout`| -||`Message.InfiniteTimeout`| -||`null`| -||`false`| -||`false`| -||`false`| -||`false`| -||`false`| - + to define default property values to associate with objects sent to a queue that are not of type . When working with objects, a instance is created for you and associated with the member of the . + + There are two ways to define a queue's default properties to send, as shown in the following C# code. You can set values for this instance of and associate it with the queue's property: + +``` +DefaultPropertiesToSend myDefaultProperties = new DefaultPropertiesToSend(); + // Set default values for the properties. + myDefaultProperties.Label = "myLabel"; + myDefaultProperties.Recoverable = false; + ... + myMessageQueue.DefaultPropertiesToSend = myDefaultProperties; + myMessageQueue.Send("hello"); +``` + + Or, you can individually assign values to the instance's property directly: + +``` +myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; + myMessageQueue.DefaultPropertiesToSend.Recoverable = false; +... + myMessageQueue.Send("hello"); +``` + + If you choose the second of these options, you do not need to call the constructor explicitly. You might want to create instances of , for example, if the properties' default values depend on some criterion of the message being sent. You can create multiple instances and assign one to the queue's property before sending the message to the queue. + + The following table shows initial property values for an instance of . + +|Property|Initial value| +|--------------|-------------------| +||`AcknowledgeTypes.None`| +||`null`| +||0| +||`true`| +||`EncryptionAlgorithm.RC2`| +||A zero-length array of bytes| +||`HashAlgorithm.MD5`| +||An empty string ("")| +||`MessagePriority.Normal`| +||`false`| +||`null`| +||`Message.InfiniteTimeout`| +||`Message.InfiniteTimeout`| +||`null`| +||`false`| +||`false`| +||`false`| +||`false`| +||`false`| + ]]> @@ -159,11 +159,11 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; Gets or sets the type of acknowledgement message to be returned to the sending application. One of the enumeration values. This value is used to determine the type of acknowledgment messages the system posts in the administration queue and when acknowledgments are returned to the sending application. The default is . - property specifies the type of acknowledgment messages to return to the sending application. For example, set the property to request notification when a message reaches its destination, when it is retrieved, or whether a time-out has prevented the message from reaching or being retrieved from the destination queue. - + property specifies the type of acknowledgment messages to return to the sending application. For example, set the property to request notification when a message reaches its destination, when it is retrieved, or whether a time-out has prevented the message from reaching or being retrieved from the destination queue. + ]]> @@ -202,13 +202,13 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; Gets or sets the queue that receives acknowledgement messages generated by Message Queuing. The that specifies the administration queue used for system-generated acknowledgment messages. The default is . - property can be any non-transactional queue. The acknowledgment messages sent to the administration queue can indicate whether or not the original message reached its destination queue, and whether or not it was removed from the queue. - - When the property has any value other than `None`, the sending application must specify the queue to be used as the administration queue. - + property can be any non-transactional queue. The acknowledgment messages sent to the administration queue can indicate whether or not the original message reached its destination queue, and whether or not it was removed from the queue. + + When the property has any value other than `None`, the sending application must specify the queue to be used as the administration queue. + ]]> @@ -246,15 +246,15 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; Gets or sets additional, application-specific information. Information specific to the application. The default is 0. - property contains additional, application-specific information that can be used to organize different types of messages, for example, using application-specific indexes. It is the responsibility of the application to interpret information. - - Where possible, message data should be included in the body of the message rather than in the property. - - When working with foreign queues, use the property to specify non-Message Queuing message properties. As with , it is the responsibility of the application to understand the content of the property. - + property contains additional, application-specific information that can be used to organize different types of messages, for example, using application-specific indexes. It is the responsibility of the application to interpret information. + + Where possible, message data should be included in the body of the message rather than in the property. + + When working with foreign queues, use the property to specify non-Message Queuing message properties. As with , it is the responsibility of the application to understand the content of the property. + ]]> @@ -293,13 +293,13 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; if sender ID should be attached to the message; otherwise, . The default is . - or is `false`, the message will be rejected when it reaches the queue. - + or is `false`, the message will be rejected when it reaches the queue. + ]]> @@ -340,13 +340,13 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; Gets or sets the encryption algorithm used to encrypt the body of a private message. One of the enumeration values. The default is . - property specifies the algorithm used to encrypt the message body of a private message. - - A queue can require that incoming messages be encrypted. If a non-encrypted (non-private) message is sent to a queue that only accepts private messages, or if a private message is sent to a queue that only accepts non-private messages, the message is rejected by the queue. The sending application can request a negative acknowledgment message be returned to the sending application if a message was rejected. - + property specifies the algorithm used to encrypt the message body of a private message. + + A queue can require that incoming messages be encrypted. If a non-encrypted (non-private) message is sent to a queue that only accepts private messages, or if a private message is sent to a queue that only accepts non-private messages, the message is rejected by the queue. The sending application can request a negative acknowledgment message be returned to the sending application if a message was rejected. + ]]> @@ -395,17 +395,17 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; Gets or sets additional information associated with the message. An array of bytes that provides additional, application-defined information associated with the message. The default is a zero-length array. - property provides for additional application-defined information that is associated with the message, such as a large binary object. It is the responsibility of the receiving application to interpret the contents of the . - - Where possible, message data should be included in the body of the message rather than in the extension. - - When working with foreign queues, use the property to specify non-Message Queuing message properties. - - A foreign queue exists in a queuing system other than Microsoft Message Queuing. Microsoft Message Queuing communicates with such queues through a connector application. - + property provides for additional application-defined information that is associated with the message, such as a large binary object. It is the responsibility of the receiving application to interpret the contents of the . + + Where possible, message data should be included in the body of the message rather than in the extension. + + When working with foreign queues, use the property to specify non-Message Queuing message properties. + + A foreign queue exists in a queuing system other than Microsoft Message Queuing. Microsoft Message Queuing communicates with such queues through a connector application. + ]]> @@ -443,14 +443,14 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; Gets or sets the hashing algorithm used when authenticating messages or creating a digital signature for a message. One of the enumeration values. The default is . - property identifies the hashing algorithm Message Queuing uses when authenticating messages or when creating a digital signature for a message. - - Message Queuing on the source computer uses the hashing algorithm when creating a digital signature for a message. The target Queue Manager then uses the same hashing algorithm to authenticate the message when it is received. + property identifies the hashing algorithm Message Queuing uses when authenticating messages or when creating a digital signature for a message. + + Message Queuing on the source computer uses the hashing algorithm when creating a digital signature for a message. The target Queue Manager then uses the same hashing algorithm to authenticate the message when it is received. + + Due to collision problems with MD5, Microsoft recommends SHA-256. ]]> @@ -492,13 +492,13 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; Gets or sets an application-defined string that describes the message. The label of the message. The default is an empty string (""). - @@ -536,13 +536,13 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; Gets or sets the message priority, which is used to determine where the message is placed in the queue. One of the enumeration values that represents the priority level of a non-transactional message. The default is . - property affects how Message Queuing handles the message while it is en route, as well as where the message is placed in the queue when it reaches its destination. Higher priority messages are given preference during routing and inserted toward the front of the queue. Messages with the same priority are placed in the queue according to their arrival time. - - Message priority can only be set meaningfully for non-transactional messages. The priority for transactional messages is automatically set to `Lowest`, which causes transactional message priority to be ignored. - + property affects how Message Queuing handles the message while it is en route, as well as where the message is placed in the queue when it reaches its destination. Higher priority messages are given preference during routing and inserted toward the front of the queue. Messages with the same priority are placed in the queue according to their arrival time. + + Message priority can only be set meaningfully for non-transactional messages. The priority for transactional messages is automatically set to `Lowest`, which causes transactional message priority to be ignored. + ]]> @@ -582,15 +582,15 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; if the message is guaranteed delivery by saving it to disk while en route; if delivery is not assured. The default is . - property indicates whether delivery of a message is guaranteed, even if a computer crashes while the message is en route to the destination queue. - - If delivery of a message is guaranteed, the message is stored locally at every step along the route until the message is successfully forwarded to the next computer. Setting to `true` on could affect the throughput. - - If the message is transactional, Message Queuing automatically treats the message as recoverable, regardless of whether is set to `true`. - + property indicates whether delivery of a message is guaranteed, even if a computer crashes while the message is en route to the destination queue. + + If delivery of a message is guaranteed, the message is stored locally at every step along the route until the message is successfully forwarded to the next computer. Setting to `true` on could affect the throughput. + + If the message is transactional, Message Queuing automatically treats the message as recoverable, regardless of whether is set to `true`. + ]]> @@ -628,13 +628,13 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; Gets or sets the queue that receives application-generated response messages. The to which application-generated response messages are returned. The default is . - property identifies the queue that receives application-generated response messages that are returned to the sending application by the receiving application. Response queues are specified by the sending application when the application sends its messages. Any available queue can be specified as a response queue. - - Messages returned to the response queue are application-specific. The application must define what is in the messages as well as what is to be done when a message is received. - + property identifies the queue that receives application-generated response messages that are returned to the sending application by the receiving application. Response queues are specified by the sending application when the application sends its messages. Any available queue can be specified as a response queue. + + Messages returned to the response queue are application-specific. The application must define what is in the messages as well as what is to be done when a message is received. + ]]> @@ -671,23 +671,23 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; Gets or sets the time limit for the message to be retrieved from the destination queue. The total time, in seconds, for a sent message to be received from the destination queue. The default is . - property specifies the total time in seconds for a sent message to be received from the destination queue. This time limit includes the time spent getting to the destination queue, plus the time spent waiting in the queue before the message is retrieved by an application. - + property specifies the total time in seconds for a sent message to be received from the destination queue. This time limit includes the time spent getting to the destination queue, plus the time spent waiting in the queue before the message is retrieved by an application. + > [!CAUTION] -> When using dependent client computers, synchronize the clock on the client computer with the clock on the server running Message Queuing. If the two clocks are not synchronized, you might see unpredictable behavior when sending messages when is not . - - If the interval expires before the message is removed from the queue, the Message Queuing application discards the message. The message is either sent to the dead-letter queue, if the message's property is set to `true`, or ignored, if is `false`. If is less than , takes precedence. - - The message's property can be set to request that Message Queuing send a negative acknowledgment message back to the sending application if the message is not retrieved before the timer expires. - +> When using dependent client computers, synchronize the clock on the client computer with the clock on the server running Message Queuing. If the two clocks are not synchronized, you might see unpredictable behavior when sending messages when is not . + + If the interval expires before the message is removed from the queue, the Message Queuing application discards the message. The message is either sent to the dead-letter queue, if the message's property is set to `true`, or ignored, if is `false`. If is less than , takes precedence. + + The message's property can be set to request that Message Queuing send a negative acknowledgment message back to the sending application if the message is not retrieved before the timer expires. + > [!CAUTION] -> If you have specified to receive negative acknowledgments, you will not receive them when the value of is less than the value of . - - When several messages are sent in a transaction, Message Queuing uses the value of the first message's property. - +> If you have specified to receive negative acknowledgments, you will not receive them when the value of is less than the value of . + + When several messages are sent in a transaction, Message Queuing uses the value of the first message's property. + ]]> @@ -726,17 +726,17 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; Gets or sets the time limit for the message to reach the queue. The time limit in seconds for a message to reach the destination queue, from the time the message is sent. The default is . - interval expires before the message reaches its destination, the Message Queuing application discards the message. The message is either sent to the dead-letter queue, if the message's property is set to `true`, or ignored, if is `false`. If is greater than , takes precedence. - - The message's property can be set to request that Message Queuing send a negative acknowledgment message back to the sending application if the message does not arrive before the timer expires. - - If is 0 seconds, Message Queuing tries once to send the message to its destination if the queue is waiting for the message. If the queue is local, the message always reaches the queue. - - When several messages are sent in a transaction, Message Queuing uses the value of the first message's property. - + interval expires before the message reaches its destination, the Message Queuing application discards the message. The message is either sent to the dead-letter queue, if the message's property is set to `true`, or ignored, if is `false`. If is greater than , takes precedence. + + The message's property can be set to request that Message Queuing send a negative acknowledgment message back to the sending application if the message does not arrive before the timer expires. + + If is 0 seconds, Message Queuing tries once to send the message to its destination if the queue is waiting for the message. If the queue is local, the message always reaches the queue. + + When several messages are sent in a transaction, Message Queuing uses the value of the first message's property. + ]]> @@ -775,15 +775,15 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; Gets the transaction status queue on the source computer. The transaction status queue on the source computer, which is used for sending acknowledgement messages back to the sending application. The default is . - property identifies the transaction status queue on the source computer. The property is set by Message Queuing, and is used by connector applications when retrieving transactional messages sent to a foreign queue. - - A foreign queue exists in a queuing system other than Microsoft Message Queuing. Microsoft Message Queuing communicates with such queues through a connector application. - - The connector application can use the transaction status queue to send acknowledgment messages back to the sending application. The transaction status queue should receive these acknowledgments even if the sending application does not request other acknowledgments. - + property identifies the transaction status queue on the source computer. The property is set by Message Queuing, and is used by connector applications when retrieving transactional messages sent to a foreign queue. + + A foreign queue exists in a queuing system other than Microsoft Message Queuing. Microsoft Message Queuing communicates with such queues through a connector application. + + The connector application can use the transaction status queue to send acknowledgment messages back to the sending application. The transaction status queue should receive these acknowledgments even if the sending application does not request other acknowledgments. + ]]> @@ -823,15 +823,15 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; if the sending application requested authentication for the message; otherwise, . The default is . - property specifies whether the message needs to be authenticated. If the sending application requests authentication, Message Queuing creates a digital signature and uses it to sign the message when it is sent and to authenticate the message when it is received. - - If a message is sent to a queue that only accepts authenticated messages, the message will be rejected when it reaches the queue if is set to `false`. - - It is not possible to look at the properties of a message and determine whether a message failed authentication. Messages that fail authentication are discarded and are not delivered to the queue. - + property specifies whether the message needs to be authenticated. If the sending application requests authentication, Message Queuing creates a digital signature and uses it to sign the message when it is sent and to authenticate the message when it is received. + + If a message is sent to a queue that only accepts authenticated messages, the message will be rejected when it reaches the queue if is set to `false`. + + It is not possible to look at the properties of a message and determine whether a message failed authentication. Messages that fail authentication are discarded and are not delivered to the queue. + ]]> @@ -872,17 +872,17 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; if message delivery failure should result in a copy of the message being sent to a dead-letter queue; otherwise, . The default is . - and specify how Message Queuing will track a message. If is `true`, then in case of delivery failure (for non-transactional messages), the message is sent to the non-transactional dead-letter queue on the computer that could not deliver the message (for example, if a message timer expires). - - In the case of delivery failure for transactional messages, the message is sent to the transactional dead-letter queue on the source computer in all negative and in-doubt cases. - - When you store messages in a dead-letter queue, empty the queue periodically to remove messages that are no longer needed. Messages stored in dead-letter queues count against the size quota for the computer where the queue resides. The computer quota is set by the administrator and refers to the total size allocated for storing messages on a computer, not just in a single queue. - - You do not create a journal or dead-letter queue. These are both system queues that are generated by Message Queuing. - + and specify how Message Queuing will track a message. If is `true`, then in case of delivery failure (for non-transactional messages), the message is sent to the non-transactional dead-letter queue on the computer that could not deliver the message (for example, if a message timer expires). + + In the case of delivery failure for transactional messages, the message is sent to the transactional dead-letter queue on the source computer in all negative and in-doubt cases. + + When you store messages in a dead-letter queue, empty the queue periodically to remove messages that are no longer needed. Messages stored in dead-letter queues count against the size quota for the computer where the queue resides. The computer quota is set by the administrator and refers to the total size allocated for storing messages on a computer, not just in a single queue. + + You do not create a journal or dead-letter queue. These are both system queues that are generated by Message Queuing. + ]]> @@ -922,13 +922,13 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; to require Message Queuing to encrypt the message; otherwise, . The default is . - @@ -968,19 +968,19 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; to require that a copy of a message be kept in the originating computer's machine journal after it has been successfully transmitted from the originating computer to the next step; otherwise, . The default is . - and specify how Message Queuing will track a message. If is `true`, then at each step that a message is transmitted, a copy is kept in the computer journal on the originating computer. - - The sent message will only be copied to the journal queue if the destination queue is on a remote computer. If the destination is on the local computer, the message is sent directly to the queue; there are no intermediate steps to require journaling. - - When you store messages in a journal queue, empty the queue periodically to remove messages that are no longer needed. Messages stored in journal queues count against the quota for the computer where the queue resides (the computer quota is set by the administrator). - - You do not create a journal or dead-letter queue. These are both system queues that are generated by Message Queuing. - - Journaling can be specified by both the message and the queue. When is `true`, the message is journaled when it is sent. When is `true`, the message is journaled when it is received. - + and specify how Message Queuing will track a message. If is `true`, then at each step that a message is transmitted, a copy is kept in the computer journal on the originating computer. + + The sent message will only be copied to the journal queue if the destination queue is on a remote computer. If the destination is on the local computer, the message is sent directly to the queue; there are no intermediate steps to require journaling. + + When you store messages in a journal queue, empty the queue periodically to remove messages that are no longer needed. Messages stored in journal queues count against the quota for the computer where the queue resides (the computer quota is set by the administrator). + + You do not create a journal or dead-letter queue. These are both system queues that are generated by Message Queuing. + + Journaling can be specified by both the message and the queue. When is `true`, the message is journaled when it is sent. When is `true`, the message is journaled when it is received. + ]]> @@ -1022,13 +1022,13 @@ myMessageQueue.DefaultPropertiesToSend.Label = "myLabel"; if each intermediate step made by the original message en route to the destination queue will generate a report to be sent to the system's report queue; otherwise, . The default is . - property specifies whether to track the route of a message as it moves toward its destination queue. If `true`, a Message Queuing-generated report message is sent to a report queue each time the message passes through a Message Queuing routing server. The report queue is specified by the source Queue Manager. Report queues are not limited to Message Queuing-generated report messages. Your application-generated messages can be sent to report queues as well. - - Using tracing involves setting up Active Directory and specifying a report queue for the Message Queuing enterprise. These settings are configured by the administrator. - + property specifies whether to track the route of a message as it moves toward its destination queue. If `true`, a Message Queuing-generated report message is sent to a report queue each time the message passes through a Message Queuing routing server. The report queue is specified by the source Queue Manager. Report queues are not limited to Message Queuing-generated report messages. Your application-generated messages can be sent to report queues as well. + + Using tracing involves setting up Active Directory and specifying a report queue for the Message Queuing enterprise. These settings are configured by the administrator. + ]]> diff --git a/xml/System.Messaging/Message.xml b/xml/System.Messaging/Message.xml index ecf06851d41..2f01ef38a4d 100644 --- a/xml/System.Messaging/Message.xml +++ b/xml/System.Messaging/Message.xml @@ -32,35 +32,35 @@ Provides access to the properties needed to define a Message Queuing message. - class to peek or receive messages from a queue, or to have fine control over message properties when sending a message to a queue. - - uses the class when it peeks or receives messages from queues, because both the and methods create a new instance of the class and set the instance's properties. The class's read-only properties apply to retrieving messages from a queue, while the read/write properties apply to sending and retrieving messages. When peeks or receives a message from a queue, its property determines which of the message's properties are retrieved. - - The class's method allows you to specify any object type for a message being sent to that queue. You can use the instance's property to specify settings for generic messages sent to the queue. The types of settings include formatter, label, encryption, and authentication. You can also specify values for the appropriate members when you coordinate your messaging application to respond to acknowledgment and report messages. Using a instance to send a message to the queue gives you the flexibility to access and modify many of these properties - either for a single message or on a message-by-message basis. properties take precedence over . - - Message data is stored in the property and to a lesser extent, the and properties. When message data is encrypted, serialized, or deserialized, only the contents of the property are affected. - - The contents of the property are serialized when the message is sent, using the property you specify. The serialized contents are found in the property. You can also set the property directly, for example, to send a file as the data content of a message. You can change the or properties at any time before sending the message, and the data will be serialized appropriately when you call . - - The properties defined by the property apply only to messages that are not of type . If you specify the property for a , the identically named properties in a instance sent to that queue cause these default properties to be ignored. - - For a list of initial property values for an instance of , see the constructor. - -## Examples - The following code example demonstrates formatting a message body using . - + class to peek or receive messages from a queue, or to have fine control over message properties when sending a message to a queue. + + uses the class when it peeks or receives messages from queues, because both the and methods create a new instance of the class and set the instance's properties. The class's read-only properties apply to retrieving messages from a queue, while the read/write properties apply to sending and retrieving messages. When peeks or receives a message from a queue, its property determines which of the message's properties are retrieved. + + The class's method allows you to specify any object type for a message being sent to that queue. You can use the instance's property to specify settings for generic messages sent to the queue. The types of settings include formatter, label, encryption, and authentication. You can also specify values for the appropriate members when you coordinate your messaging application to respond to acknowledgment and report messages. Using a instance to send a message to the queue gives you the flexibility to access and modify many of these properties - either for a single message or on a message-by-message basis. properties take precedence over . + + Message data is stored in the property and to a lesser extent, the and properties. When message data is encrypted, serialized, or deserialized, only the contents of the property are affected. + + The contents of the property are serialized when the message is sent, using the property you specify. The serialized contents are found in the property. You can also set the property directly, for example, to send a file as the data content of a message. You can change the or properties at any time before sending the message, and the data will be serialized appropriately when you call . + + The properties defined by the property apply only to messages that are not of type . If you specify the property for a , the identically named properties in a instance sent to that queue cause these default properties to be ignored. + + For a list of initial property values for an instance of , see the constructor. + +## Examples + The following code example demonstrates formatting a message body using . + :::code language="csharp" source="~/snippets/csharp/System.Messaging/BinaryMessageFormatter/Overview/message_binaryformatter.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/MessagingBinaryFormatter/VB/message_binaryformatter.vb" id="Snippet1"::: - - The following code example demonstrates formatting a message body using . - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/MessagingBinaryFormatter/VB/message_binaryformatter.vb" id="Snippet1"::: + + The following code example demonstrates formatting a message body using . + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/Message.Body/CPP/message_sendreceive.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Messaging/Message/Overview/message_sendreceive.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.Body/VB/message_sendreceive.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.Body/VB/message_sendreceive.vb" id="Snippet1"::: + ]]> @@ -96,61 +96,61 @@ Initializes a new instance of the class with an empty body. - class that has an empty body. - - Specify either the property or the property before sending the object. The property can be any object that can be serialized, such as a text string, a structure object, a class instance, or an embedded object. - - Unless you write the contents of the message directly to the property, set the property before you send the message. The body is serialized using the property's value at the time the method is called on the instance. - - The is loosely coupled, so it is not necessary to have the same object type on the sender and receiver when using this format. The and serialize the data into binary representation. The is used when sending or receiving COM components. - - The following table shows initial property values for an instance of . - -|Property|Initial value| -|--------------|-------------------| -||`AcknowledgeType.None`| -||`null`| -||0| -||`true`| -||Microsoft Base Cryptographic Provider version 1.0| -||`CryptoProviderType.RSA_FULL`| -||`null`| -||`Stream.null`| -||0| -||`Guid.Empty`| -||An empty string ("")| -||A zero-length array of bytes| -||A zero-length array of bytes| -||`EncryptionAlgorithm.RC2`| -||A zero-length array of bytes| -||`XmlMessageFormatter`| -||`HashAlgorithm.MD5`| -||An empty string ("")| -||`MessagePriority.Normal`| -||`false`| -||`null`| -||A zero-length array of bytes| -||`Message.InfiniteTimeout`| -||`Message.InfiniteTimeout`| -||`null`| -||`false`| -||`false`| -||`false`| -||`false`| -||`false`| - - - -## Examples - The following code example sends two messages of different priorities to the queue, and retrieves them subsequently. - + class that has an empty body. + + Specify either the property or the property before sending the object. The property can be any object that can be serialized, such as a text string, a structure object, a class instance, or an embedded object. + + Unless you write the contents of the message directly to the property, set the property before you send the message. The body is serialized using the property's value at the time the method is called on the instance. + + The is loosely coupled, so it is not necessary to have the same object type on the sender and receiver when using this format. The and serialize the data into binary representation. The is used when sending or receiving COM components. + + The following table shows initial property values for an instance of . + +|Property|Initial value| +|--------------|-------------------| +||`AcknowledgeType.None`| +||`null`| +||0| +||`true`| +||Microsoft Base Cryptographic Provider version 1.0| +||`CryptoProviderType.RSA_FULL`| +||`null`| +||`Stream.null`| +||0| +||`Guid.Empty`| +||An empty string ("")| +||A zero-length array of bytes| +||A zero-length array of bytes| +||`EncryptionAlgorithm.RC2`| +||A zero-length array of bytes| +||`XmlMessageFormatter`| +||`HashAlgorithm.MD5`| +||An empty string ("")| +||`MessagePriority.Normal`| +||`false`| +||`null`| +||A zero-length array of bytes| +||`Message.InfiniteTimeout`| +||`Message.InfiniteTimeout`| +||`null`| +||`false`| +||`false`| +||`false`| +||`false`| +||`false`| + + + +## Examples + The following code example sends two messages of different priorities to the queue, and retrieves them subsequently. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/Message.DefaultPropertiesToSend/CPP/message_defaultandpriority.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Messaging/Message/.ctor/message_defaultandpriority.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.DefaultPropertiesToSend/VB/message_defaultandpriority.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.DefaultPropertiesToSend/VB/message_defaultandpriority.vb" id="Snippet1"::: + ]]> @@ -183,57 +183,57 @@ The object to be serialized into the body of the message. Initializes a new instance of the class, using the to serialize the specified object into the body of the message. - class that contains the specified by the `body` parameter. The `body` parameter can be any object that can be serialized, such as a text string, a structure object, a class instance, or an embedded object. The body is serialized using the unless you change the property before the is sent. If you change the or property at any time before calling , the message will be serialized according to the new property value. - - The is loosely coupled, so it is not necessary to have the same object type on the sender and receiver when using this format. The and serialize the data into binary representation. The is used when sending or receiving COM components. - - The following table shows initial property values for an instance of . - -|Property|Initial value| -|--------------|-------------------| -||`AcknowledgeType.None`| -||`null`| -||0| -||`true`| -||Microsoft Base Cryptographic Provider version 1.0| -||`CryptoProviderType.RSA_FULL`| -||The `body` parameter.| -||`Stream.null`| -||0| -||`Guid.Empty`| -||An empty string ("")| -||A zero-length array of bytes| -||A zero-length array of bytes| -||`EncryptionAlgorithm.RC2`| -||A zero-length array of bytes| -||`XmlMessageFormatter`| -||`HashAlgorithm.MD5`| -||An empty string ("")| -||`MessagePriority.Normal`| -||`false`| -||`null`| -||A zero-length array of bytes| -||`Message.InfiniteTimeout`| -||`Message.InfiniteTimeout`| -||`null`| -||`false`| -||`false`| -||`false`| -||`false`| -||`false`| - - - -## Examples - The following code example creates a new queue, sends a message that contains an order to it, and then retrieves it. - + class that contains the specified by the `body` parameter. The `body` parameter can be any object that can be serialized, such as a text string, a structure object, a class instance, or an embedded object. The body is serialized using the unless you change the property before the is sent. If you change the or property at any time before calling , the message will be serialized according to the new property value. + + The is loosely coupled, so it is not necessary to have the same object type on the sender and receiver when using this format. The and serialize the data into binary representation. The is used when sending or receiving COM components. + + The following table shows initial property values for an instance of . + +|Property|Initial value| +|--------------|-------------------| +||`AcknowledgeType.None`| +||`null`| +||0| +||`true`| +||Microsoft Base Cryptographic Provider version 1.0| +||`CryptoProviderType.RSA_FULL`| +||The `body` parameter.| +||`Stream.null`| +||0| +||`Guid.Empty`| +||An empty string ("")| +||A zero-length array of bytes| +||A zero-length array of bytes| +||`EncryptionAlgorithm.RC2`| +||A zero-length array of bytes| +||`XmlMessageFormatter`| +||`HashAlgorithm.MD5`| +||An empty string ("")| +||`MessagePriority.Normal`| +||`false`| +||`null`| +||A zero-length array of bytes| +||`Message.InfiniteTimeout`| +||`Message.InfiniteTimeout`| +||`null`| +||`false`| +||`false`| +||`false`| +||`false`| +||`false`| + + + +## Examples + The following code example creates a new queue, sends a message that contains an order to it, and then retrieves it. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/Message.Body/CPP/message_sendreceive.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Messaging/Message/Overview/message_sendreceive.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.Body/VB/message_sendreceive.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.Body/VB/message_sendreceive.vb" id="Snippet1"::: + ]]> @@ -267,53 +267,53 @@ A that specifies the formatter with which to serialize the message body. Initializes a new instance of the class using the specified formatter to serialize the specified object into the body of the message. - class that contains the specified by the `body` parameter and that uses any valid formatter to serialize the body. The `body` parameter is any object that can be serialized, such as a text string, a structure object, a class instance, or an embedded object. If you change the or property at any time before calling , the message will be serialized according to the new property value. - - The is loosely coupled, so it is not necessary to have the same object type on the sender and receiver when using this format. The and serialize the data into binary representation. The is used when sending or receiving COM components. - - The following table shows initial property values for an instance of . - -|Property|Initial value| -|--------------|-------------------| -||`AcknowledgeType.None`| -||`null`| -||0| -||`true`| -||Microsoft Base Cryptographic Provider version 1.0| -||`CryptoProviderType.RSA_FULL`| -||The `body` parameter.| -||`Stream.null`| -||0| -||`Guid.Empty`| -||An empty string ("")| -||A zero-length array of bytes| -||A zero-length array of bytes| -||`EncryptionAlgorithm.RC2`| -||A zero-length array of bytes| -||The `formatter` parameter.| -||`HashAlgorithm.MD5`| -||An empty string ("")| -||`MessagePriority.Normal`| -||`false`| -||`null`| -||A zero-length array of bytes| -||`Message.InfiniteTimeout`| -||`Message.InfiniteTimeout`| -||`null`| -||`false`| -||`false`| -||`false`| -||`false`| -||`false`| - -## Examples + class that contains the specified by the `body` parameter and that uses any valid formatter to serialize the body. The `body` parameter is any object that can be serialized, such as a text string, a structure object, a class instance, or an embedded object. If you change the or property at any time before calling , the message will be serialized according to the new property value. + + The is loosely coupled, so it is not necessary to have the same object type on the sender and receiver when using this format. The and serialize the data into binary representation. The is used when sending or receiving COM components. + + The following table shows initial property values for an instance of . + +|Property|Initial value| +|--------------|-------------------| +||`AcknowledgeType.None`| +||`null`| +||0| +||`true`| +||Microsoft Base Cryptographic Provider version 1.0| +||`CryptoProviderType.RSA_FULL`| +||The `body` parameter.| +||`Stream.null`| +||0| +||`Guid.Empty`| +||An empty string ("")| +||A zero-length array of bytes| +||A zero-length array of bytes| +||`EncryptionAlgorithm.RC2`| +||A zero-length array of bytes| +||The `formatter` parameter.| +||`HashAlgorithm.MD5`| +||An empty string ("")| +||`MessagePriority.Normal`| +||`false`| +||`null`| +||A zero-length array of bytes| +||`Message.InfiniteTimeout`| +||`Message.InfiniteTimeout`| +||`null`| +||`false`| +||`false`| +||`false`| +||`false`| +||`false`| + +## Examples :::code language="csharp" source="~/snippets/csharp/System.Messaging/BinaryMessageFormatter/Overview/message_binaryformatter.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/MessagingBinaryFormatter/VB/message_binaryformatter.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/MessagingBinaryFormatter/VB/message_binaryformatter.vb" id="Snippet1"::: + ]]> @@ -361,22 +361,22 @@ Gets or sets the type of acknowledgment message to be returned to the sending application. One of the values, which represent both the types of acknowledgment messages the system posts in the administration queue and the conditions under which acknowledgments are returned to the sending application. The default is . - property specifies the type of acknowledgment messages requested by the sending application. Set the property before sending the message to request notification of certain occurrences - for example, a message reaching its destination queue, a message being retrieved, or a time-out preventing a message from reaching or being retrieved from the destination queue. - - Message Queuing returns notification by sending acknowledgment messages to the property specified by the original message. An acknowledgment message's property indicates the type of acknowledgment that it represents. For example, if an acknowledgment message was sent because a message did not reach the destination before the interval expired, the property of the acknowledgment message would contain the value `ReachQueueTimeout`. - - - -## Examples - The following code example sends and receives a message containing an order to and from a queue. It specifically requests a positive acknowledgment when the original message reaches or is retrieved from the queue. - + property specifies the type of acknowledgment messages requested by the sending application. Set the property before sending the message to request notification of certain occurrences - for example, a message reaching its destination queue, a message being retrieved, or a time-out preventing a message from reaching or being retrieved from the destination queue. + + Message Queuing returns notification by sending acknowledgment messages to the property specified by the original message. An acknowledgment message's property indicates the type of acknowledgment that it represents. For example, if an acknowledgment message was sent because a message did not reach the destination before the interval expired, the property of the acknowledgment message would contain the value `ReachQueueTimeout`. + + + +## Examples + The following code example sends and receives a message containing an order to and from a queue. It specifically requests a positive acknowledgment when the original message reaches or is retrieved from the queue. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/Message.Acknowledgment/CPP/message_acknowledgment.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Messaging/AcknowledgeTypes/Overview/message_acknowledgment.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.Acknowledgment/VB/message_acknowledgment.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.Acknowledgment/VB/message_acknowledgment.vb" id="Snippet1"::: + ]]> The message is filtered to ignore the property. @@ -419,23 +419,23 @@ Gets the classification of acknowledgment that this message represents. One of the enumeration values. - property to verify the status of the original message. - - When a message is sent to its destination queue, Message Queuing can be requested to post an acknowledgment message. Such a message can indicate, for example, whether the message arrived and was retrieved within specified time-outs, or it can indicate what went wrong in the case of delivery failure. The destination queue returns acknowledgment messages and posts them to the administration queue specified in the original message's property. The property of an acknowledgment message identifies the acknowledgment message, not the original message. You can find the identifier of the original message in the acknowledgment instance's property. - - If this instance represents an acknowledgment message, the property specifies the type of acknowledgment. Otherwise, the property contains the value `Normal`. - - Use the property of the original message to specify the circumstances under which acknowledgments will be returned. - + property to verify the status of the original message. + + When a message is sent to its destination queue, Message Queuing can be requested to post an acknowledgment message. Such a message can indicate, for example, whether the message arrived and was retrieved within specified time-outs, or it can indicate what went wrong in the case of delivery failure. The destination queue returns acknowledgment messages and posts them to the administration queue specified in the original message's property. The property of an acknowledgment message identifies the acknowledgment message, not the original message. You can find the identifier of the original message in the acknowledgment instance's property. + + If this instance represents an acknowledgment message, the property specifies the type of acknowledgment. Otherwise, the property contains the value `Normal`. + + Use the property of the original message to specify the circumstances under which acknowledgments will be returned. + ]]> - The message has not been sent. This property can only be read on messages retrieved from a queue. - - -or- - + The message has not been sent. This property can only be read on messages retrieved from a queue. + + -or- + The message queue is filtered to ignore the property. @@ -481,22 +481,22 @@ Gets or sets the queue that receives the acknowledgement messages that Message Queuing generates. The that specifies the administration queue used for system-generated acknowledgment messages. The default is . - property can be any non-transactional queue. The acknowledgment messages sent to the administration queue can indicate whether the original message reached its destination queue and whether it was removed from the queue. - - When the property has any value other than `None`, the sending application must specify the queue to use as the administration queue. - - - -## Examples - The following code example sends and receives a message containing an order to and from a queue. It specifically requests a positive acknowledgment when the original message reaches or is retrieved from the queue. - + property can be any non-transactional queue. The acknowledgment messages sent to the administration queue can indicate whether the original message reached its destination queue and whether it was removed from the queue. + + When the property has any value other than `None`, the sending application must specify the queue to use as the administration queue. + + + +## Examples + The following code example sends and receives a message containing an order to and from a queue. It specifically requests a positive acknowledgment when the original message reaches or is retrieved from the queue. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/Message.Acknowledgment/CPP/message_acknowledgment.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Messaging/AcknowledgeTypes/Overview/message_acknowledgment.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.Acknowledgment/VB/message_acknowledgment.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.Acknowledgment/VB/message_acknowledgment.vb" id="Snippet1"::: + ]]> The message queue is filtered to ignore the property. @@ -539,15 +539,15 @@ Gets or sets additional, application-specific information. Information that is specific to the application. The default is zero. - property contains application-specific information that you can use to organize different types of messages. For example, you can use application-specific indexes. It is the responsibility of the application to interpret property information. - - Whenever possible, you should include message data in the body of the message rather than the property. - - When working with foreign queues, use the property to specify message properties that do not exist in Message Queuing. As with the property, it is the responsibility of the application to understand the content of the property. - + property contains application-specific information that you can use to organize different types of messages. For example, you can use application-specific indexes. It is the responsibility of the application to interpret property information. + + Whenever possible, you should include message data in the body of the message rather than the property. + + When working with foreign queues, use the property to specify message properties that do not exist in Message Queuing. As with the property, it is the responsibility of the application to understand the content of the property. + ]]> The message queue is filtered to ignore the property. @@ -586,24 +586,24 @@ Gets the time that the message arrived in the destination queue. A that represents the message's arrival time in the destination queue. The time is adjusted from GMT to the local time of the computer on which the destination queue resides. - property indicates how quickly the message must be received from the destination queue. The property timer starts when the message is sent, not when the message arrives in the queue. - - - -## Examples - The following code example displays the value of a message's property. - - - + property indicates how quickly the message must be received from the destination queue. The property timer starts when the message is sent, not when the message arrives in the queue. + + + +## Examples + The following code example displays the value of a message's property. + + + ]]> - The message has not been sent. This property can only be read on messages retrieved from a queue. - - -or- - + The message has not been sent. This property can only be read on messages retrieved from a queue. + + -or- + The message queue is filtered to ignore the property. @@ -644,23 +644,23 @@ if the should be attached to the message; otherwise, . The default is . - property is an array of bytes that represents the identifier of the sending user. The sender ID is set by Message Queuing and is used by the receiving Queue Manager to verify whether the sender has access rights to a queue. - - The absence of the sender ID is an indication by the sending application that Message Queuing should not validate the message's sender nor verify the sender's access rights to the receiving queue. The is trustworthy only if the message was authenticated when it reached the destination queue. The message is rejected when it reaches the destination queue if the queue accepts only authenticated messages and either the or the property is `false`. - + property is an array of bytes that represents the identifier of the sending user. The sender ID is set by Message Queuing and is used by the receiving Queue Manager to verify whether the sender has access rights to a queue. + + The absence of the sender ID is an indication by the sending application that Message Queuing should not validate the message's sender nor verify the sender's access rights to the receiving queue. The is trustworthy only if the message was authenticated when it reached the destination queue. The message is rejected when it reaches the destination queue if the queue accepts only authenticated messages and either the or the property is `false`. + > [!CAUTION] -> If a message is rejected, it is either sent to the dead-letter queue (if is `true`), or it is ignored. You can request acknowledgments when a message fails to reach a queue. Otherwise, when is `false` the message might be lost without warning. - - - -## Examples - The following code example gets and sets the value of a message's property. - - - +> If a message is rejected, it is either sent to the dead-letter queue (if is `true`), or it is ignored. You can request acknowledgments when a message fails to reach a queue. Otherwise, when is `false` the message might be lost without warning. + + + +## Examples + The following code example gets and sets the value of a message's property. + + + ]]> The message queue is filtered to ignore the property. @@ -705,26 +705,26 @@ if authentication was requested for the message when it entered the queue; otherwise, . - property is used only by the application while it is interacting with the message and trying to determine if authentication was requested. If the message is in the queue, the message was authenticated. Conversely, if the property is `true`, the receiving Queue Manager authenticated the message when it received that message. - - You cannot determine if a message failed authentication by looking at its properties. Message Queuing discards messages that fail authentication before they are delivered to the queue. However, you can request that an acknowledgment message be sent if a delivery failure prevents the message from arriving in the queue. - - - -## Examples - The following code example displays the value of a message's property. - - - + property is used only by the application while it is interacting with the message and trying to determine if authentication was requested. If the message is in the queue, the message was authenticated. Conversely, if the property is `true`, the receiving Queue Manager authenticated the message when it received that message. + + You cannot determine if a message failed authentication by looking at its properties. Message Queuing discards messages that fail authentication before they are delivered to the queue. However, you can request that an acknowledgment message be sent if a delivery failure prevents the message from arriving in the queue. + + + +## Examples + The following code example displays the value of a message's property. + + + ]]> - The message has not been sent. This property can only be read on messages retrieved from a queue. - - -or- - + The message has not been sent. This property can only be read on messages retrieved from a queue. + + -or- + The message queue is filtered to ignore the property. @@ -767,21 +767,21 @@ Gets or sets the name of the cryptographic provider used to generate the digital signature of the message. The name of the cryptographic provider used to generate the digital signature of the message. The default is Microsoft Base Cryptographic Provider version 1.0. - when working with foreign queues. Message Queuing requires the authentication provider name and authentication provider type of the cryptographic provider (authentication provider) to validate the digital signatures of both messages sent to a foreign queue and messages passed to Message Queuing from a foreign queue. - - When sending a message, always set the and properties together. When the message is sent, Message Queuing ignores the authentication provider name if the connector type is not also set. - - The property cannot be `null`, but it can be an empty string (""). - + when working with foreign queues. Message Queuing requires the authentication provider name and authentication provider type of the cryptographic provider (authentication provider) to validate the digital signatures of both messages sent to a foreign queue and messages passed to Message Queuing from a foreign queue. + + When sending a message, always set the and properties together. When the message is sent, Message Queuing ignores the authentication provider name if the connector type is not also set. + + The property cannot be `null`, but it can be an empty string (""). + ]]> - The property could not be set. - - -or- - + The property could not be set. + + -or- + The message queue is filtered to ignore the property. The was set to . @@ -826,21 +826,21 @@ Gets or sets the type of cryptographic provider used to generate the digital signature of the message. One of the values. The default is . - property when working with foreign queues to specify which cryptographic service provider is associated with a message. Message Queuing requires the authentication provider name and authentication provider type of the cryptographic provider (authentication provider) to validate the digital signatures of both messages sent to a foreign queue and messages passed to Message Queuing from a foreign queue. - - Only `RsaFull` is intended to be used with messaging. - - When sending a message, always set the and properties together. When the message is sent, Message Queuing ignores the authentication provider type if the connector type is not also set. - + property when working with foreign queues to specify which cryptographic service provider is associated with a message. Message Queuing requires the authentication provider name and authentication provider type of the cryptographic provider (authentication provider) to validate the digital signatures of both messages sent to a foreign queue and messages passed to Message Queuing from a foreign queue. + + Only `RsaFull` is intended to be used with messaging. + + When sending a message, always set the and properties together. When the message is sent, Message Queuing ignores the authentication provider type if the connector type is not also set. + ]]> - The property could not be set. - - -or- - + The property could not be set. + + -or- + The message queue is filtered to ignore the property. @@ -881,39 +881,39 @@ Gets or sets the content of the message. An object that specifies the message contents. The object can be a string, a date, a currency, a number, an array of bytes, or any managed object. - property usually contains the data associated with the message. Although you can also send application-specific data in the and properties, you should include message data in the of the message whenever possible. Only the property contents are serialized or encrypted. - - The property can contain any object whose size does not exceed 4 MB. If you use to send any object that is not of type to the , that object will be located in the property of the instance returned by or . - - The string argument in `MessageQueue.Send("hello.")` is an example of such a generic object. - - The property indicates the type of information that is stored in the message body. Message Queuing uses this information to identify the type of the property contents. - - Specify either the property or the property before sending the object. The property can be any serializable object, such as a text string, structure object, class instance, or embedded object. - - Unless you write the contents of the message directly to the property, set the property before you send the message. When the method is called on the instance, the body is serialized using the formatter contained in the property. If you send the message without specifying a value for the property, the formatter defaults to . - + property usually contains the data associated with the message. Although you can also send application-specific data in the and properties, you should include message data in the of the message whenever possible. Only the property contents are serialized or encrypted. + + The property can contain any object whose size does not exceed 4 MB. If you use to send any object that is not of type to the , that object will be located in the property of the instance returned by or . + + The string argument in `MessageQueue.Send("hello.")` is an example of such a generic object. + + The property indicates the type of information that is stored in the message body. Message Queuing uses this information to identify the type of the property contents. + + Specify either the property or the property before sending the object. The property can be any serializable object, such as a text string, structure object, class instance, or embedded object. + + Unless you write the contents of the message directly to the property, set the property before you send the message. When the method is called on the instance, the body is serialized using the formatter contained in the property. If you send the message without specifying a value for the property, the formatter defaults to . + > [!NOTE] -> Attempting to set the body of a message to will cause a when the `Send` method of the class is called and the is used. - - - -## Examples - The following code example sends two messages of different priorities to the queue, and retrieves them subsequently. - +> Attempting to set the body of a message to will cause a when the `Send` method of the class is called and the is used. + + + +## Examples + The following code example sends two messages of different priorities to the queue, and retrieves them subsequently. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/Message.DefaultPropertiesToSend/CPP/message_defaultandpriority.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Messaging/Message/.ctor/message_defaultandpriority.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.DefaultPropertiesToSend/VB/message_defaultandpriority.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.DefaultPropertiesToSend/VB/message_defaultandpriority.vb" id="Snippet1"::: + ]]> - The property is . - - -or- - + The property is . + + -or- + The message queue is filtered to ignore the property. @@ -972,17 +972,17 @@ Gets or sets the information in the body of the message. A that contains the serialized information included in the of the message. - to be passed to the queue. - - Specify either the property or the property before sending the object. If you set the property, the contents are serialized into the property. However, you can choose to write the property directly. This is useful, for example, when you want to open a connection to a file and stream its contents as the body of your message. - - Unless you write the contents of the message directly to the property, set the property before you send the message. When the method is called on the instance, the body is serialized using the formatter contained in the property. If you send the message without specifying a value for the property, the formatter defaults to . - - If you set the property to `true` for the body of this message, the message will be encrypted when it is sent, not when you set the property. Therefore, the property is never encrypted. - + to be passed to the queue. + + Specify either the property or the property before sending the object. If you set the property, the contents are serialized into the property. However, you can choose to write the property directly. This is useful, for example, when you want to open a connection to a file and stream its contents as the body of your message. + + Unless you write the contents of the message directly to the property, set the property before you send the message. When the method is called on the instance, the body is serialized using the formatter contained in the property. If you send the message without specifying a value for the property, the formatter defaults to . + + If you set the property to `true` for the body of this message, the message will be encrypted when it is sent, not when you set the property. Therefore, the property is never encrypted. + ]]> The message queue is filtered to ignore the property. @@ -1031,33 +1031,33 @@ Gets or sets the type of data that the message body contains. The message body's true type, such as a string, a date, a currency, or a number. - property indicates the type of the object within the property of the message. - - The performs binding between native types and the object in a message body. If you use the , the formatter sets the property for you. - - Other formatters can provide binding functionality also, as shown in the following C# code. - -``` -message.Formatter = new ActiveXMessageFormatter(); -object myObject message.Body; -if (myObject is string) { -} -if (myObject is int) { -} -if (myObject is float) { -} -``` - - - -## Examples - The following code example displays the value of a message's property. - - - + property indicates the type of the object within the property of the message. + + The performs binding between native types and the object in a message body. If you use the , the formatter sets the property for you. + + Other formatters can provide binding functionality also, as shown in the following C# code. + +``` +message.Formatter = new ActiveXMessageFormatter(); +object myObject message.Body; +if (myObject is string) { +} +if (myObject is int) { +} +if (myObject is float) { +} +``` + + + +## Examples + The following code example displays the value of a message's property. + + + ]]> The message queue is filtered to ignore the property. @@ -1103,29 +1103,29 @@ if (myObject is float) { Gets or sets a value that indicates that some message properties typically set by Message Queuing were set by the sending application. A defined by the application and used in conjunction with connector applications or message encryption. This allows a receiving application to interpret message properties that were set by the sending application but that are usually set by Message Queuing. - property be set whenever an application sets a message property that is usually set by Message Queuing. An application typically uses a in the following two cases: - -- Whenever a connector application passes a message. The tells the sending and receiving applications how to interpret the security and acknowledgment properties of the message. - -- Whenever the sending application, rather than Message Queuing, encrypts a message. The tells Message Queuing to use the property value to decrypt the message. - - You must set the property if you set any of the following properties (otherwise, the queue ignores these properties when the message is sent): - -- - -- - -- - -- - -- - -- - + property be set whenever an application sets a message property that is usually set by Message Queuing. An application typically uses a in the following two cases: + +- Whenever a connector application passes a message. The tells the sending and receiving applications how to interpret the security and acknowledgment properties of the message. + +- Whenever the sending application, rather than Message Queuing, encrypts a message. The tells Message Queuing to use the property value to decrypt the message. + + You must set the property if you set any of the following properties (otherwise, the queue ignores these properties when the message is sent): + +- + +- + +- + +- + +- + +- + ]]> The message queue is filtered to ignore the property. @@ -1172,26 +1172,26 @@ if (myObject is float) { Gets or sets the message identifier used by acknowledgment, report, and response messages to reference the original message. The message identifier specified by the property of the original message. The correlation identifier is used by Message Queuing when it generates an acknowledgment or report message, and by an application when it generates a response message. - property to identify the original message's property. - - Connector applications also must set the property of the acknowledgment and report messages to the message identifier of the original message. - - When your application sends a response message to the sending application, you can set the property of the response message to the message identifier of the original message. The sending application can then match your response message to the message that was sent. - - - -## Examples - The following code example sends and receives a message that contains an order to and from a queue. It specifically requests a positive acknowledgment when the original message reaches or is retrieved from the queue. - + property to identify the original message's property. + + Connector applications also must set the property of the acknowledgment and report messages to the message identifier of the original message. + + When your application sends a response message to the sending application, you can set the property of the response message to the message identifier of the original message. The sending application can then match your response message to the message that was sent. + + + +## Examples + The following code example sends and receives a message that contains an order to and from a queue. It specifically requests a positive acknowledgment when the original message reaches or is retrieved from the queue. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/Message.Acknowledgment/CPP/message_acknowledgment.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Messaging/AcknowledgeTypes/Overview/message_acknowledgment.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.Acknowledgment/VB/message_acknowledgment.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.Acknowledgment/VB/message_acknowledgment.vb" id="Snippet1"::: + ]]> The message queue is filtered to ignore the property. @@ -1235,24 +1235,24 @@ if (myObject is float) { Gets the intended destination queue for a message. A that specifies the intended destination queue for the message. - property is most commonly used to determine the original destination of a message that arrived in a journal or dead-letter queue. Usually, you do not need to examine this property, because you typically retrieve the message from its destination queue. - - - -## Examples - The following code example displays the value of a message's property. - - - + property is most commonly used to determine the original destination of a message that arrived in a journal or dead-letter queue. Usually, you do not need to examine this property, because you typically retrieve the message from its destination queue. + + + +## Examples + The following code example displays the value of a message's property. + + + ]]> - The message has not been sent. This property can only be read on messages retrieved from a queue. - - -or- - + The message has not been sent. This property can only be read on messages retrieved from a queue. + + -or- + The message queue is filtered to ignore the property. @@ -1294,19 +1294,19 @@ if (myObject is float) { Gets or sets the symmetric key used to encrypt application-encrypted messages or messages sent to foreign queues. An array of byte values that specifies the destination symmetric key used to encrypt the message. The default is a zero-length array. - property. The first is when your application, rather than Message Queuing, encrypts a message. The second is when you send an encrypted message to a queuing system other than Message Queuing. - - Before you set this property, you must encrypt the symmetric key with the public key of the receiving queue manager. When you send an application-encrypted message, the receiving queue manager uses the symmetric key to decrypt the message before sending it to its destination queue. - - If you send a message to a foreign queue, the message is first received by the appropriate connector application, which forwards the encrypted message with the attached symmetric key to the receiving application. It is then the responsibility of the receiving application to decrypt the message using the symmetric key. - - When you set the property, you must also set the property. When the message is sent, Message Queuing ignores the property if the property is not also set. - - The property has a maximum array size of 256. - + property. The first is when your application, rather than Message Queuing, encrypts a message. The second is when you send an encrypted message to a queuing system other than Message Queuing. + + Before you set this property, you must encrypt the symmetric key with the public key of the receiving queue manager. When you send an application-encrypted message, the receiving queue manager uses the symmetric key to decrypt the message before sending it to its destination queue. + + If you send a message to a foreign queue, the message is first received by the appropriate connector application, which forwards the encrypted message with the attached symmetric key to the receiving application. It is then the responsibility of the receiving application to decrypt the message using the symmetric key. + + When you set the property, you must also set the property. When the message is sent, Message Queuing ignores the property if the property is not also set. + + The property has a maximum array size of 256. + ]]> The message queue is filtered to ignore the property. @@ -1350,19 +1350,19 @@ if (myObject is float) { Gets or sets the digital signature that Message Queuing uses to authenticate the message. An array of byte values that specifies the Message Queuing 1.0 digital signature used to authenticate the message. The default is a zero-length array. - property when the sending application requests authentication. The receiving application uses this property to retrieve the digital signature attached to the message. - - You can only use the property when running Message Queuing version 2.0. The sending application must specify Message Queuing version 1.0 signatures when requesting authentication. If the sending application sends a Message Queuing version 2.0 signature, this property contains a buffer of four bytes, each containing zero. - - The property, together with the property, is also used by connector applications when a message is sent. In this scenario, the connector application - rather than Message Queuing - generates the digital signature, which it bases on the certificate of the user sending the message. - - The property has a maximum array size of 256. - - When you set the property, you must also set the property. When a message is sent, Message Queuing ignores the property if the property is not also set. - + property when the sending application requests authentication. The receiving application uses this property to retrieve the digital signature attached to the message. + + You can only use the property when running Message Queuing version 2.0. The sending application must specify Message Queuing version 1.0 signatures when requesting authentication. If the sending application sends a Message Queuing version 2.0 signature, this property contains a buffer of four bytes, each containing zero. + + The property, together with the property, is also used by connector applications when a message is sent. In this scenario, the connector application - rather than Message Queuing - generates the digital signature, which it bases on the certificate of the user sending the message. + + The property has a maximum array size of 256. + + When you set the property, you must also set the property. When a message is sent, Message Queuing ignores the property if the property is not also set. + ]]> The message queue is filtered to ignore the property. @@ -1408,13 +1408,13 @@ if (myObject is float) { Gets or sets the encryption algorithm used to encrypt the body of a private message. One of the enumeration values. The default is . - property specifies the algorithm used to encrypt the message body of a private message. - - A queue can require that incoming messages be encrypted. If an application sends a non-encrypted (non-private) message to a queue that accepts only private messages, or if it sends a private message to a queue that accepts only non-private messages, the queue rejects the message. The sending application can request that a negative acknowledgment message be returned in such a case. - + property specifies the algorithm used to encrypt the message body of a private message. + + A queue can require that incoming messages be encrypted. If an application sends a non-encrypted (non-private) message to a queue that accepts only private messages, or if it sends a private message to a queue that accepts only non-private messages, the queue rejects the message. The sending application can request that a negative acknowledgment message be returned in such a case. + ]]> The message queue is filtered to ignore the property. @@ -1459,17 +1459,17 @@ if (myObject is float) { Gets or sets additional, application-defined information associated with the message. An array of byte values that provides application-defined information associated with the message. The default is a zero-length array. - property provides for application-defined information, like a large binary object, that is associated with the message. It is the responsibility of the receiving application to interpret the contents of the property. - - Where possible, you should include message data in the property of the message rather than the property. - - When working with foreign queues, use the property to specify message properties that do not exist in Message Queuing. - - A foreign queue exists in a queuing system other than Microsoft Message Queuing. Message Queuing communicates with such queues through a connector application. - + property provides for application-defined information, like a large binary object, that is associated with the message. It is the responsibility of the receiving application to interpret the contents of the property. + + Where possible, you should include message data in the property of the message rather than the property. + + When working with foreign queues, use the property to specify message properties that do not exist in Message Queuing. + + A foreign queue exists in a queuing system other than Microsoft Message Queuing. Message Queuing communicates with such queues through a connector application. + ]]> The message queue is filtered to ignore the property. @@ -1509,27 +1509,27 @@ if (myObject is float) { Gets or sets the formatter used to serialize an object into or deserialize an object from the message body. The that produces a stream to be written to or read from the message body. The default is . - property when reading and writing a message. When a message is sent to the queue, the formatter serializes the property into a stream that can be sent to the message queue. When reading from a queue, the formatter deserializes the message data into the property. - - Unless you write the contents of the message directly to the property, set the property before you send the message. When the method is called on the instance, the body is serialized using the formatter contained in the property. If you send the message without specifying a value for the property, the formatter defaults to . - - The is loosely coupled, so it is not necessary to have the same object type on the sender and receiver when using this format. The and serialize the data into binary representation. The is used when sending or receiving COM components. - -## Examples - The following code example demonstrates formatting a message body using . - + property when reading and writing a message. When a message is sent to the queue, the formatter serializes the property into a stream that can be sent to the message queue. When reading from a queue, the formatter deserializes the message data into the property. + + Unless you write the contents of the message directly to the property, set the property before you send the message. When the method is called on the instance, the body is serialized using the formatter contained in the property. If you send the message without specifying a value for the property, the formatter defaults to . + + The is loosely coupled, so it is not necessary to have the same object type on the sender and receiver when using this format. The and serialize the data into binary representation. The is used when sending or receiving COM components. + +## Examples + The following code example demonstrates formatting a message body using . + :::code language="csharp" source="~/snippets/csharp/System.Messaging/BinaryMessageFormatter/Overview/message_binaryformatter.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/MessagingBinaryFormatter/VB/message_binaryformatter.vb" id="Snippet1"::: - - The following code example demonstrates formatting a message body using . - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/MessagingBinaryFormatter/VB/message_binaryformatter.vb" id="Snippet1"::: + + The following code example demonstrates formatting a message body using . + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/Message.Body/CPP/message_sendreceive.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Messaging/Message/Overview/message_sendreceive.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.Body/VB/message_sendreceive.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.Body/VB/message_sendreceive.vb" id="Snippet1"::: + ]]> The property is . @@ -1575,13 +1575,13 @@ if (myObject is float) { Gets or sets the hashing algorithm that Message Queuing uses when authenticating a message or creating a digital signature for a message. One of the enumeration values. For Windows XP, the default is . Otherwise, the default is . - The message queue is filtered to ignore the property. @@ -1627,30 +1627,30 @@ if (myObject is float) { Gets the message's identifier. The message's unique identifier, which is generated by Message Queuing. - of the sending computer and a unique identifier for the message on the computer. The combination of the two items produces a message identifier that is unique on the network. - - Message Queuing generates message identifiers for all messages - including acknowledgment and report messages. An acknowledgment message is generally sent by Message Queuing in reaction to the arrival or failure of an original, sent message. You can find the property value of the original message in the property of an acknowledgment message. - - You can also use the property when sending a response message to a response queue. To include the identifier of the original message in a response message, set the property of the response message to the property of the original message. The application reading the response message can then use the correlation identifier of the response message to identify the original message. - - - -## Examples - The following code example sends and receives a message containing an order to and from a queue. It specifically requests a positive acknowledgment when the original message reaches or is retrieved from the queue. - + of the sending computer and a unique identifier for the message on the computer. The combination of the two items produces a message identifier that is unique on the network. + + Message Queuing generates message identifiers for all messages - including acknowledgment and report messages. An acknowledgment message is generally sent by Message Queuing in reaction to the arrival or failure of an original, sent message. You can find the property value of the original message in the property of an acknowledgment message. + + You can also use the property when sending a response message to a response queue. To include the identifier of the original message in a response message, set the property of the response message to the property of the original message. The application reading the response message can then use the correlation identifier of the response message to identify the original message. + + + +## Examples + The following code example sends and receives a message containing an order to and from a queue. It specifically requests a positive acknowledgment when the original message reaches or is retrieved from the queue. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/Message.Acknowledgment/CPP/message_acknowledgment.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Messaging/AcknowledgeTypes/Overview/message_acknowledgment.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.Acknowledgment/VB/message_acknowledgment.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.Acknowledgment/VB/message_acknowledgment.vb" id="Snippet1"::: + ]]> - The message has not been sent. This property can only be read on messages retrieved from a queue. - - -or- - + The message has not been sent. This property can only be read on messages retrieved from a queue. + + -or- + The message queue is filtered to ignore the property. @@ -1675,18 +1675,18 @@ if (myObject is float) { Specifies that no time-out exists. - and require a value that specifies a time-out. For the former, the time-out is the maximum time allowed for a message to be received from the queue. For the latter, the time-out is the time allowed for a message to reach the queue. In both cases, you can specify the time-out as a number of seconds or use to indicate that no time-out exists. - - - -## Examples - The following code example demonstrates the use of the field. - - - + and require a value that specifies a time-out. For the former, the time-out is the maximum time allowed for a message to be received from the queue. For the latter, the time-out is the time allowed for a message to reach the queue. In both cases, you can specify the time-out as a number of seconds or use to indicate that no time-out exists. + + + +## Examples + The following code example demonstrates the use of the field. + + + ]]> @@ -1725,30 +1725,30 @@ if (myObject is float) { if the message was the first message sent in a transaction; otherwise, . - property to verify that a message was the first message sent in a single transaction to a single queue. - - This property is available only with Message Queuing version 2.0 and later. - - To verify transaction boundaries, you can use the property along with two other properties: and . Use the former to check whether a message was the last message sent in the transaction, and use the latter to retrieve the identifier of the transaction. - - If only one message is sent in a transaction, the and properties are both set to `true`. - - - -## Examples - The following code example displays the value of a message's property. - - - + property to verify that a message was the first message sent in a single transaction to a single queue. + + This property is available only with Message Queuing version 2.0 and later. + + To verify transaction boundaries, you can use the property along with two other properties: and . Use the former to check whether a message was the last message sent in the transaction, and use the latter to retrieve the identifier of the transaction. + + If only one message is sent in a transaction, the and properties are both set to `true`. + + + +## Examples + The following code example displays the value of a message's property. + + + ]]> - The message has not been sent. This property can only be read on messages retrieved from a queue. - - -or- - + The message has not been sent. This property can only be read on messages retrieved from a queue. + + -or- + The message queue is filtered to ignore the property. @@ -1787,30 +1787,30 @@ if (myObject is float) { if the message was the last message sent in a single transaction; otherwise, . - property to verify that a message was the last message sent in a single transaction to a single queue. - - This property is available only with Message Queuing version 2.0 and later. - - To verify transaction boundaries, you can use the property along with two other properties: and . Use the former to check whether a message was the first message sent in the transaction, and use the latter to retrieve the identifier of the transaction. - - If only one message is sent in a transaction, the and properties are both set to `true`. - - - -## Examples - The following code example displays the value of a message's property. - - - + property to verify that a message was the last message sent in a single transaction to a single queue. + + This property is available only with Message Queuing version 2.0 and later. + + To verify transaction boundaries, you can use the property along with two other properties: and . Use the former to check whether a message was the first message sent in the transaction, and use the latter to retrieve the identifier of the transaction. + + If only one message is sent in a transaction, the and properties are both set to `true`. + + + +## Examples + The following code example displays the value of a message's property. + + + ]]> - The message has not been sent. This property can only be read on messages retrieved from a queue. - - -or- - + The message has not been sent. This property can only be read on messages retrieved from a queue. + + -or- + The message queue is filtered to ignore the property. @@ -1852,20 +1852,20 @@ if (myObject is float) { Gets or sets an application-defined Unicode string that describes the message. The label of the message. The default is an empty string (""). - property. - - - + property. + + + ]]> The message queue is filtered to ignore the property. @@ -1892,28 +1892,28 @@ if (myObject is float) { Introduced in MSMQ 3.0. Gets the message's lookup identifier. The message's lookup identifier, which is generated by Message Queuing and is unique to the queue where the message resides. - property provides read-only access to a message's lookup identifier. The lookup identifier, introduced in MSMQ 3.0, is a 64-bit identifier that is generated by Message Queuing and assigned to each message when the message is placed in the queue. The lookup identifier is not the same as the message identifier that is generated when the message is sent. - - Message Queuing generates a lookup identifier for all messages that are placed in any queue, including application-generated destination, administration, and report queues, as well as system-generated journal, dead-letter, connector, and outgoing queues. In other words, this includes both messages sent by sending applications and by Message Queuing. The lookup identifier is unique to the queue and has no meaning outside the queue. - - If a message is sent to several destination queues, or if a copy of a message is stored in a computer journal or queue journal, each copy of the message will have its own lookup identifier when it is placed in its respective queue. - - The property can only be read on messages retrieved from a queue. - - A lookup identifier is used to read a specific message in the queue. Once the lookup identifier of a message is known, the receiving application can call the or function to go directly to that message and peek at or retrieve it from the queue, unlike cursors that must start at the front of the queue and navigate towards the end of the queue, - - Obtaining the lookup identifiers of the messages in the queue is the responsibility of the application. One possible way to obtain the lookup identifiers is to create a trigger for the destination queue that invokes a component that caches the identifiers of each message as they are placed in the queue. - + property provides read-only access to a message's lookup identifier. The lookup identifier, introduced in MSMQ 3.0, is a 64-bit identifier that is generated by Message Queuing and assigned to each message when the message is placed in the queue. The lookup identifier is not the same as the message identifier that is generated when the message is sent. + + Message Queuing generates a lookup identifier for all messages that are placed in any queue, including application-generated destination, administration, and report queues, as well as system-generated journal, dead-letter, connector, and outgoing queues. In other words, this includes both messages sent by sending applications and by Message Queuing. The lookup identifier is unique to the queue and has no meaning outside the queue. + + If a message is sent to several destination queues, or if a copy of a message is stored in a computer journal or queue journal, each copy of the message will have its own lookup identifier when it is placed in its respective queue. + + The property can only be read on messages retrieved from a queue. + + A lookup identifier is used to read a specific message in the queue. Once the lookup identifier of a message is known, the receiving application can call the or function to go directly to that message and peek at or retrieve it from the queue, unlike cursors that must start at the front of the queue and navigate towards the end of the queue, + + Obtaining the lookup identifiers of the messages in the queue is the responsibility of the application. One possible way to obtain the lookup identifiers is to create a trigger for the destination queue that invokes a component that caches the identifiers of each message as they are placed in the queue. + ]]> MSMQ 3.0 is not installed. - The message has not been sent. This property can only be read on messages retrieved from a queue. - - -or- - + The message has not been sent. This property can only be read on messages retrieved from a queue. + + -or- + The message queue is filtered to ignore the property. @@ -1950,30 +1950,30 @@ if (myObject is float) { Gets the message type: , , or . One of the values. - property. - - - + property. + + + ]]> - The message has not been sent. This property can only be read on messages retrieved from a queue. - - -or- - + The message has not been sent. This property can only be read on messages retrieved from a queue. + + -or- + The message queue is filtered to ignore the property. @@ -2016,22 +2016,22 @@ if (myObject is float) { Gets or sets the message priority, which determines where in the queue the message is placed. One of the values, which represent the priority levels of non-transactional messages. The default is . - property affects how Message Queuing handles the message both while it is en route and once it reaches its destination. Higher-priority messages are given preference during routing and inserted toward the front of the destination queue. Messages with the same priority are placed in the queue according to their arrival time. - - You can set a meaningful priority only for non-transactional messages. Message Queuing automatically sets the priority for transactional messages to `Lowest`, which causes transactional message priority to be ignored. - - - -## Examples - The following code example sends two messages of different priorities to the queue, and retrieves them subsequently. - + property affects how Message Queuing handles the message both while it is en route and once it reaches its destination. Higher-priority messages are given preference during routing and inserted toward the front of the destination queue. Messages with the same priority are placed in the queue according to their arrival time. + + You can set a meaningful priority only for non-transactional messages. Message Queuing automatically sets the priority for transactional messages to `Lowest`, which causes transactional message priority to be ignored. + + + +## Examples + The following code example sends two messages of different priorities to the queue, and retrieves them subsequently. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/Message.DefaultPropertiesToSend/CPP/message_defaultandpriority.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Messaging/Message/.ctor/message_defaultandpriority.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.DefaultPropertiesToSend/VB/message_defaultandpriority.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Message.DefaultPropertiesToSend/VB/message_defaultandpriority.vb" id="Snippet1"::: + ]]> The message queue is filtered to ignore the property. @@ -2076,22 +2076,22 @@ if (myObject is float) { if delivery of the message is guaranteed (through saving the message to disk while en route); if delivery is not assured. The default is . - property indicates whether the delivery of a message is guaranteed - even if a computer crashes while the message is en route to the destination queue. - - If delivery of a message is guaranteed, the message is stored locally at every step along the route, until the message is successfully forwarded to the next computer. Setting the property to `true` could affect throughput. - - If the message is transactional, Message Queuing automatically treats the message as recoverable, regardless of the value of the property. - - - -## Examples - The following code example gets and sets the value of a message's property. - - - + property indicates whether the delivery of a message is guaranteed - even if a computer crashes while the message is en route to the destination queue. + + If delivery of a message is guaranteed, the message is stored locally at every step along the route, until the message is successfully forwarded to the next computer. Setting the property to `true` could affect throughput. + + If the message is transactional, Message Queuing automatically treats the message as recoverable, regardless of the value of the property. + + + +## Examples + The following code example gets and sets the value of a message's property. + + + ]]> The message queue is filtered to ignore the property. @@ -2133,20 +2133,20 @@ if (myObject is float) { Gets or sets the queue that receives application-generated response messages. The to which application-generated response messages are returned. The default is . - property identifies the queue that receives application-generated response messages, which the receiving application returns to the sending application. The sending application specifies response queues when the application sends its messages. Any available queue can be specified as a response queue. - - Messages returned to the response queue are application-specific. The application must define the contents of the messages as well as the action to take upon receipt of a message. - - - -## Examples - The following code example gets and sets the value of a message's property. - - - + property identifies the queue that receives application-generated response messages, which the receiving application returns to the sending application. The sending application specifies response queues when the application sends its messages. Any available queue can be specified as a response queue. + + Messages returned to the response queue are application-specific. The application must define the contents of the messages as well as the action to take upon receipt of a message. + + + +## Examples + The following code example gets and sets the value of a message's property. + + + ]]> The message queue is filtered to ignore the property. @@ -2222,15 +2222,15 @@ if (myObject is float) { Gets or sets the security certificate used to authenticate messages. An array of byte values that represents a security certificate, which Message Queuing uses to verify the sender of the message. The default is a zero-length array. - property when the message includes an external security certificate. - - Message Queuing can authenticate a message using either an internal or external security certificate. Message Queuing provides internal certificates, which are used to verify message integrity. A certification authority provides an external certificate, which you can access through the property of the message. In addition to allowing Message Queuing to authenticate the message, an external certificate allows the receiving application to further verify the sender. An internal certificate has no usable value to a receiving application. - - An external certificate must be registered with the directory service of the Message Queuing system. An external certificate contains information about the certification authority, the certificate user, the validity period of the certificate, the public key of the certificate user, and the certification authority's signature. - + property when the message includes an external security certificate. + + Message Queuing can authenticate a message using either an internal or external security certificate. Message Queuing provides internal certificates, which are used to verify message integrity. A certification authority provides an external certificate, which you can access through the property of the message. In addition to allowing Message Queuing to authenticate the message, an external certificate allows the receiving application to further verify the sender. An internal certificate has no usable value to a receiving application. + + An external certificate must be registered with the directory service of the Message Queuing system. An external certificate contains information about the certification authority, the certificate user, the validity period of the certificate, the public key of the certificate user, and the certification authority's signature. + ]]> The message queue is filtered to ignore the property. @@ -2270,19 +2270,19 @@ if (myObject is float) { Gets the identifier of the sending user. An array of byte values that identifies the sender. The receiving Queue Manager uses the identifier when it authenticates the message to verify the sender of the message and the sender's access rights to the queue. - property is `false`, the sender identifier specified in the property is not attached to the message when it is sent. This indicates to Message Queuing that the sender should not be validated when it sends the message to the destination queue. If the property is `true`, the property value is trustworthy only if the message was authenticated. Use the property in conjunction with the property to verify the sender's access rights. - - A connector application is an application that uses a connector server to provide communication between Message Queuing and other queuing systems. Message Queuing requires connector applications to provide sender identification. You must set the property when sending a message through a connector application. - + property is `false`, the sender identifier specified in the property is not attached to the message when it is sent. This indicates to Message Queuing that the sender should not be validated when it sends the message to the destination queue. If the property is `true`, the property value is trustworthy only if the message was authenticated. Use the property in conjunction with the property to verify the sender's access rights. + + A connector application is an application that uses a connector server to provide communication between Message Queuing and other queuing systems. Message Queuing requires connector applications to provide sender identification. You must set the property when sending a message through a connector application. + ]]> - The message has not been sent. This property can only be read on messages retrieved from a queue. - - -or- - + The message has not been sent. This property can only be read on messages retrieved from a queue. + + -or- + The message queue is filtered to ignore the property. @@ -2326,26 +2326,26 @@ if (myObject is float) { Gets the version of Message Queuing used to send the message. The version of Message Queuing used to send the message. - property is important for certain features. For example, transaction processing is supported only by Message Queuing 2.0 and later, and digital signatures are used to authenticate messages sent by MSMQ 1.0. - - The sending Queue Manager sets the property when the message is sent. - - - -## Examples - The following code example displays the value of a message's property. - - - + property is important for certain features. For example, transaction processing is supported only by Message Queuing 2.0 and later, and digital signatures are used to authenticate messages sent by MSMQ 1.0. + + The sending Queue Manager sets the property when the message is sent. + + + +## Examples + The following code example displays the value of a message's property. + + + ]]> - The message has not been sent. This property can only be read on messages retrieved from a queue. - - -or- - + The message has not been sent. This property can only be read on messages retrieved from a queue. + + -or- + The message queue is filtered to ignore the property. @@ -2389,24 +2389,24 @@ if (myObject is float) { Gets the date and time on the sending computer that the message was sent by the source queue manager. A that represents the time the message was sent. - property is adjusted to the local time of the computer on which this instance of the class was created. This time zone could be different from those of the source and destination queues. - - - -## Examples - The following code example displays the value of a message's property. - - - + property is adjusted to the local time of the computer on which this instance of the class was created. This time zone could be different from those of the source and destination queues. + + + +## Examples + The following code example displays the value of a message's property. + + + ]]> - The message has not been sent. This property can only be read on messages retrieved from a queue. - - -or- - + The message has not been sent. This property can only be read on messages retrieved from a queue. + + -or- + The message queue is filtered to ignore the property. @@ -2441,24 +2441,24 @@ if (myObject is float) { Gets the computer from which the message originated. The name of the computer from which the message was sent. - property does not include preceding two forward slashes (\\\\). For example, `myServer` is a valid . - - - -## Examples - The following code example displays the value of a message's property. - - - + property does not include preceding two forward slashes (\\\\). For example, `myServer` is a valid . + + + +## Examples + The following code example displays the value of a message's property. + + + ]]> - The message has not been sent. This property can only be read on messages retrieved from a queue. - - -or- - + The message has not been sent. This property can only be read on messages retrieved from a queue. + + -or- + The message queue is filtered to ignore the property. The computer information or directory service could not be accessed. @@ -2503,29 +2503,29 @@ if (myObject is float) { Gets or sets the maximum amount of time for the message to be received from the destination queue. The total time for a sent message to be received from the destination queue. The default is . - property specifies the total time for a sent message to be received from the destination queue. The time limit includes the time spent getting to the destination queue and the time spent waiting in the queue before the message is received. - + property specifies the total time for a sent message to be received from the destination queue. The time limit includes the time spent getting to the destination queue and the time spent waiting in the queue before the message is received. + > [!CAUTION] -> When using dependent client computers, be sure the clock on the client computer is synchronized with the clock on the server that is running Message Queuing. Otherwise, unpredictable behavior might result when sending a message whose property is not . - - If the interval specified by the property expires before the message is removed from the queue, Message Queuing discards the message in one of two ways. If the message's property is `true`, the message is sent to the dead-letter queue. If is `false`, the message is ignored. - - You can set the message's property to request that Message Queuing send a negative acknowledgment message back to the sending application if the message is not retrieved before the timer expires. - - If the value specified by the property is less than the value specified by the property, takes precedence. - - When several messages are sent in a single transaction, Message Queuing uses the property of the first message. - - - -## Examples - The following code example gets and sets the value of a message's property. - - - +> When using dependent client computers, be sure the clock on the client computer is synchronized with the clock on the server that is running Message Queuing. Otherwise, unpredictable behavior might result when sending a message whose property is not . + + If the interval specified by the property expires before the message is removed from the queue, Message Queuing discards the message in one of two ways. If the message's property is `true`, the message is sent to the dead-letter queue. If is `false`, the message is ignored. + + You can set the message's property to request that Message Queuing send a negative acknowledgment message back to the sending application if the message is not retrieved before the timer expires. + + If the value specified by the property is less than the value specified by the property, takes precedence. + + When several messages are sent in a single transaction, Message Queuing uses the property of the first message. + + + +## Examples + The following code example gets and sets the value of a message's property. + + + ]]> The message queue is filtered to ignore the property. @@ -2573,22 +2573,22 @@ if (myObject is float) { Gets or sets the maximum amount of time for the message to reach the queue. The time limit for the message to reach the destination queue, beginning from the time the message is sent. The default is . - property expires before the message reaches its destination, Message Queuing discards the message in one of two ways. If the message's property is `true`, the message is sent to the dead-letter queue. If is `false`, the message is ignored - - You can set the message's property to request that Message Queuing send a negative acknowledgment message back to the sending application if the message does not arrive before the timer expires. - - If the property is set to 0 seconds, Message Queuing tries once to send the message to its destination - if the queue is waiting for the message. If the queue is local, the message always reaches it. - - If the value specified by the property is greater than the value specified by the property, takes precedence. - + property expires before the message reaches its destination, Message Queuing discards the message in one of two ways. If the message's property is `true`, the message is sent to the dead-letter queue. If is `false`, the message is ignored + + You can set the message's property to request that Message Queuing send a negative acknowledgment message back to the sending application if the message does not arrive before the timer expires. + + If the property is set to 0 seconds, Message Queuing tries once to send the message to its destination - if the queue is waiting for the message. If the queue is local, the message always reaches it. + + If the value specified by the property is greater than the value specified by the property, takes precedence. + When several messages are sent in a single transaction, Message Queuing uses the property of the first message. - -## Examples + +## Examples The following code example gets and sets the value of a message's property. - + ]]> The message queue is filtered to ignore the property. @@ -2628,30 +2628,30 @@ if (myObject is float) { Gets the identifier for the transaction of which the message was a part. The identifier for the transaction associated with the message. - property to verify that a message was sent as part of a specific transaction. The transaction identifier contains the identifier of the sending computer (first 16 bits) followed by a 4-byte transaction sequence number. - - This property is available only for Message Queuing version 2.0 and later. - - Transaction identifiers are not guaranteed to be unique, because transaction sequence numbers are not persistent, and they start over again at 2 20. Message Queuing guarantees only that subsequent transactions will have different transaction sequence numbers. - - You can use the property along with the and properties to verify transaction boundaries. - - - -## Examples - The following code example displays the value of a message's property. - - - + property to verify that a message was sent as part of a specific transaction. The transaction identifier contains the identifier of the sending computer (first 16 bits) followed by a 4-byte transaction sequence number. + + This property is available only for Message Queuing version 2.0 and later. + + Transaction identifiers are not guaranteed to be unique, because transaction sequence numbers are not persistent, and they start over again at 2 20. Message Queuing guarantees only that subsequent transactions will have different transaction sequence numbers. + + You can use the property along with the and properties to verify transaction boundaries. + + + +## Examples + The following code example displays the value of a message's property. + + + ]]> - The message has not been sent. This property can only be read on messages retrieved from a queue. - - -or- - + The message has not been sent. This property can only be read on messages retrieved from a queue. + + -or- + The message queue is filtered to ignore the property. @@ -2693,28 +2693,28 @@ if (myObject is float) { Gets the transaction status queue on the source computer. The transaction status queue on the source computer, which is used for sending acknowledgement messages back to the sending application. The default is . - property identifies the transactional queue on the source computer that receives read-receipt acknowledgments from connector applications. Message Queuing sets the property, and connector applications use the property when retrieving transactional messages sent to foreign queues. - - A foreign queue exists in a queuing system other than Microsoft Message Queuing. Message Queuing communicates with such queues through a connector application. - - The connector application can use the transaction status queue to send acknowledgment messages back to the sending application. The transaction status queue should receive these acknowledgments even if the sending application does not request other acknowledgments. - - - -## Examples - The following code example displays the value of a message's property. - - - + property identifies the transactional queue on the source computer that receives read-receipt acknowledgments from connector applications. Message Queuing sets the property, and connector applications use the property when retrieving transactional messages sent to foreign queues. + + A foreign queue exists in a queuing system other than Microsoft Message Queuing. Message Queuing communicates with such queues through a connector application. + + The connector application can use the transaction status queue to send acknowledgment messages back to the sending application. The transaction status queue should receive these acknowledgments even if the sending application does not request other acknowledgments. + + + +## Examples + The following code example displays the value of a message's property. + + + ]]> - The message has not been sent. This property can only be read on messages retrieved from a queue. - - -or- - + The message has not been sent. This property can only be read on messages retrieved from a queue. + + -or- + The message queue is filtered to ignore the property. @@ -2760,15 +2760,15 @@ if (myObject is float) { if the sending application requested authentication for the message; otherwise, . - property specifies whether the message needs to be authenticated. If the sending application requests authentication, Message Queuing creates a digital signature and uses it to sign the message when it is sent and authenticate the message when it is received. - - If is `false` and a message is sent to a queue that accepts only authenticated messages, the message will be rejected when it reaches the queue. - - You cannot determine if a message failed authentication by looking at its properties. Message Queuing discards such messages before they are delivered to the queue. However, you can request that an acknowledgment message be sent if a delivery failure prevents a message from arriving in the queue. - + property specifies whether the message needs to be authenticated. If the sending application requests authentication, Message Queuing creates a digital signature and uses it to sign the message when it is sent and authenticate the message when it is received. + + If is `false` and a message is sent to a queue that accepts only authenticated messages, the message will be rejected when it reaches the queue. + + You cannot determine if a message failed authentication by looking at its properties. Message Queuing discards such messages before they are delivered to the queue. However, you can request that an acknowledgment message be sent if a delivery failure prevents a message from arriving in the queue. + ]]> The message queue is filtered to ignore the property. @@ -2818,24 +2818,24 @@ if (myObject is float) { if message-delivery failure should result in a copy of the message being sent to a dead-letter queue; otherwise, . The default is . - and properties specify how Message Queuing tracks a message. If is `true`, delivery failure (of a non-transactional message), causes the message to be sent to the non-transactional dead-letter queue on the computer that could not deliver the message. Delivery failure could be caused by a message timer expiring, for example. - - In the case of delivery failure for a transactional message, Message Queuing sends the message to the transactional dead-letter queue on the source machine in all negative and in-doubt cases. - - When you store messages in a dead-letter queue, you should clear the queue periodically to remove messages that are no longer needed. Messages stored in dead-letter queues count against the size quota for the computer where the queue resides. The computer quota is set by the administrator and refers to the size allocated for storing messages on the whole computer, not just in a single queue. - - You do not create a journal or dead-letter queue. These are both system queues that Message Queuing generates. - - - -## Examples - The following code example gets and sets the value of a message's property. - - - + and properties specify how Message Queuing tracks a message. If is `true`, delivery failure (of a non-transactional message), causes the message to be sent to the non-transactional dead-letter queue on the computer that could not deliver the message. Delivery failure could be caused by a message timer expiring, for example. + + In the case of delivery failure for a transactional message, Message Queuing sends the message to the transactional dead-letter queue on the source machine in all negative and in-doubt cases. + + When you store messages in a dead-letter queue, you should clear the queue periodically to remove messages that are no longer needed. Messages stored in dead-letter queues count against the size quota for the computer where the queue resides. The computer quota is set by the administrator and refers to the size allocated for storing messages on the whole computer, not just in a single queue. + + You do not create a journal or dead-letter queue. These are both system queues that Message Queuing generates. + + + +## Examples + The following code example gets and sets the value of a message's property. + + + ]]> The message queue is filtered to ignore the property. @@ -2879,20 +2879,20 @@ if (myObject is float) { to require Message Queuing to encrypt the message; otherwise, . The default is . - property. - - - + property. + + + ]]> The message queue is filtered to ignore the property. @@ -2936,24 +2936,24 @@ if (myObject is float) { to require that a copy of a message be kept in the originating computer's machine journal after the message has been successfully transmitted (from the originating computer to the next server); otherwise, . The default is . - and properties specify how Message Queuing tracks a message. If is `true`, then a copy is kept in the computer journal on the originating machine at each step that a message is transmitted. - - The sent message is only copied to the journal queue if the destination queue is on a remote computer. If the destination is on the local computer, the message is sent directly to the queue; there are no intermediate steps to require journaling. - - When you store messages in a journal queue, clear the queue periodically to remove messages that are no longer needed. Messages stored in journal queues count against the quota for the computer where the queue resides. (The computer quota is set by the administrator.) - - You do not create a journal or dead-letter queue. These are both system queues that Message Queuing generates. - - - -## Examples - The following code example gets and sets the value of a message's property. - - - + and properties specify how Message Queuing tracks a message. If is `true`, then a copy is kept in the computer journal on the originating machine at each step that a message is transmitted. + + The sent message is only copied to the journal queue if the destination queue is on a remote computer. If the destination is on the local computer, the message is sent directly to the queue; there are no intermediate steps to require journaling. + + When you store messages in a journal queue, clear the queue periodically to remove messages that are no longer needed. Messages stored in journal queues count against the quota for the computer where the queue resides. (The computer quota is set by the administrator.) + + You do not create a journal or dead-letter queue. These are both system queues that Message Queuing generates. + + + +## Examples + The following code example gets and sets the value of a message's property. + + + ]]> The message queue is filtered to ignore the property. @@ -2999,20 +2999,20 @@ if (myObject is float) { if each intermediate step made by the original message en route to the destination queue generates a report to be sent to the system's report queue; otherwise, . The default is . - property specifies whether to track the route of a message as it moves toward its destination queue. If `true`, a report message (generated by Message Queuing) is sent to a report queue each time the message passes through a Message Queuing routing server. The report queue is specified by the source Queue Manager. Report queues are not limited to report messages generated by Message Queuing; your application-generated messages can also be sent to report queues. - - Using tracing involves setting up Active Directory and specifying a report queue for the Message Queuing enterprise. The administrator configures these settings. - - - -## Examples - The following code example gets and sets the value of a message's property. - - - + property specifies whether to track the route of a message as it moves toward its destination queue. If `true`, a report message (generated by Message Queuing) is sent to a report queue each time the message passes through a Message Queuing routing server. The report queue is specified by the source Queue Manager. Report queues are not limited to report messages generated by Message Queuing; your application-generated messages can also be sent to report queues. + + Using tracing involves setting up Active Directory and specifying a report queue for the Message Queuing enterprise. The administrator configures these settings. + + + +## Examples + The following code example gets and sets the value of a message's property. + + + ]]> The message queue is filtered to ignore the property. diff --git a/xml/System.Net.Http.Headers/HttpContentHeaders.xml b/xml/System.Net.Http.Headers/HttpContentHeaders.xml index 16f39be2ae6..4b1d2cd0f55 100644 --- a/xml/System.Net.Http.Headers/HttpContentHeaders.xml +++ b/xml/System.Net.Http.Headers/HttpContentHeaders.xml @@ -326,7 +326,7 @@ Gets or sets the value of the content header on an HTTP response. The value of the content header on an HTTP response. - Due to collision problems with MD5, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with MD5, Microsoft recommends a security model based on SHA-256 or better. diff --git a/xml/System.Net/HttpRequestHeader.xml b/xml/System.Net/HttpRequestHeader.xml index ca1c199d210..23239ab551c 100644 --- a/xml/System.Net/HttpRequestHeader.xml +++ b/xml/System.Net/HttpRequestHeader.xml @@ -62,11 +62,11 @@ The HTTP headers that may be specified in a client request. - @@ -667,7 +667,7 @@ 16 - The Content-MD5 header, which specifies the MD5 digest of the accompanying body data, for the purpose of providing an end-to-end message integrity check. Due to collision problems with MD5, Microsoft recommends a security model based on SHA256 or better. + The Content-MD5 header, which specifies the MD5 digest of the accompanying body data, for the purpose of providing an end-to-end message integrity check. Due to collision problems with MD5, Microsoft recommends a security model based on SHA-256 or better. diff --git a/xml/System.Net/HttpResponseHeader.xml b/xml/System.Net/HttpResponseHeader.xml index 6757ef25e52..01f41594a0b 100644 --- a/xml/System.Net/HttpResponseHeader.xml +++ b/xml/System.Net/HttpResponseHeader.xml @@ -43,11 +43,11 @@ The HTTP headers that can be specified in a server response. - @@ -450,7 +450,7 @@ 16 - The Content-MD5 header, which specifies the MD5 digest of the accompanying body data, for the purpose of providing an end-to-end message integrity check. Due to collision problems with MD5, Microsoft recommends a security model based on SHA256 or better. + The Content-MD5 header, which specifies the MD5 digest of the accompanying body data, for the purpose of providing an end-to-end message integrity check. Due to collision problems with MD5, Microsoft recommends a security model based on SHA-256 or better. diff --git a/xml/System.Reflection.Metadata/Document.xml b/xml/System.Reflection.Metadata/Document.xml index 5a0ce6c5eb4..c3d55222880 100644 --- a/xml/System.Reflection.Metadata/Document.xml +++ b/xml/System.Reflection.Metadata/Document.xml @@ -118,7 +118,7 @@ The source document is hashed in its binary form as stored in the file. System.Reflection.Metadata.GuidHandle - Gets the hash algorithm used to calculate the (SHA1, SHA256, etc.). + Gets the hash algorithm used to calculate the (for example, SHA-1 or SHA-256). To be added. To be added. diff --git a/xml/System.Reflection.PortableExecutable/PdbChecksumDebugDirectoryData.xml b/xml/System.Reflection.PortableExecutable/PdbChecksumDebugDirectoryData.xml index dd4a33b0dee..b4dfaad6bbe 100644 --- a/xml/System.Reflection.PortableExecutable/PdbChecksumDebugDirectoryData.xml +++ b/xml/System.Reflection.PortableExecutable/PdbChecksumDebugDirectoryData.xml @@ -70,17 +70,9 @@ For more information, see: https://github.com/dotnet/runtime/blob/main/docs/desi System.String - The name of the crypto hash algorithm used to calculate the checksum. - A string representing the name of the crypto hash algorithm used to calculate the checksum. - - - + Gets the name of the crypto hash algorithm used to calculate the checksum. + The name of the crypto hash algorithm used to calculate the checksum, for example, "SHA256". + To be added. @@ -107,7 +99,7 @@ For example: "SHA256". System.Collections.Immutable.ImmutableArray<System.Byte> - The checksum of the PDB content. + Gets the checksum of the PDB content. An immutable array of bytes representing the checksum of the PDB content. To be added. diff --git a/xml/System.Reflection/Assembly.xml b/xml/System.Reflection/Assembly.xml index 99612c906d7..644b5d0de80 100644 --- a/xml/System.Reflection/Assembly.xml +++ b/xml/System.Reflection/Assembly.xml @@ -2969,14 +2969,8 @@ Note: In .NET for Win [!IMPORTANT] -> Starting with the .NET Framework 4, the property of an object that is returned by this method is if there is no hash algorithm for the referenced assembly, or if the hash algorithm of the referenced assembly is not identified by the enumeration. In previous versions of the .NET Framework, the property returned in this situation. - - - ## Examples + The following code example demonstrates calling the method. This code example is part of a larger example provided for the class. :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/Reflection/CPP/reflection.cpp" id="Snippet1"::: diff --git a/xml/System.Reflection/AssemblyHashAlgorithm.xml b/xml/System.Reflection/AssemblyHashAlgorithm.xml index e8e0b63610e..dcc45912011 100644 --- a/xml/System.Reflection/AssemblyHashAlgorithm.xml +++ b/xml/System.Reflection/AssemblyHashAlgorithm.xml @@ -60,7 +60,7 @@ Retrieves the MD5 message-digest algorithm. - Due to collision problems with MD5, Microsoft recommends SHA256. + Due to collision problems with MD5, Microsoft recommends SHA-256. MD5 was developed by Rivest in 1991. It is basically MD4 with safety-belts and, while it is slightly slower than MD4, it helps provide more security. The algorithm consists of four distinct rounds, which has a slightly different design from that of MD4. Message-digest size, as well as padding requirements, remain the same. @@ -96,7 +96,7 @@ A mask indicating that there is no hash algorithm. - If you specify for a multi-module assembly, the common language runtime defaults to the SHA1 algorithm, since multi-module assemblies need to generate a hash. + If you specify for a multi-module assembly, the common language runtime defaults to the SHA-1 algorithm, since multi-module assemblies need to generate a hash. @@ -131,7 +131,7 @@ Retrieves a revision of the Secure Hash Algorithm that corrects an unpublished flaw in SHA. - Due to collision problems with SHA1, Microsoft recommends SHA256. + Due to collision problems with SHA-1, Microsoft recommends SHA-256. diff --git a/xml/System.Security.Authentication/HashAlgorithmType.xml b/xml/System.Security.Authentication/HashAlgorithmType.xml index f9edeac3fd0..dfa5f11f2a3 100644 --- a/xml/System.Security.Authentication/HashAlgorithmType.xml +++ b/xml/System.Security.Authentication/HashAlgorithmType.xml @@ -49,19 +49,19 @@ Specifies the algorithm used for generating message authentication codes (MACs). - property. - - - -## Examples - The following example displays the properties of an after authentication has succeeded. - + property. + + + +## Examples + The following example displays the properties of an after authentication has succeeded. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NclSslClientAsync/CPP/NclSslClientAsync.cpp" id="Snippet3"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Security/LocalCertificateSelectionCallback/Overview/clientasync.cs" id="Snippet3"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Security/LocalCertificateSelectionCallback/Overview/clientasync.cs" id="Snippet3"::: + ]]> @@ -106,7 +106,7 @@ The Message Digest 5 (MD5) hashing algorithm. - Due to collision problems with MD5, Microsoft recommends SHA256. + Due to collision problems with MD5, Microsoft recommends SHA-256. @@ -189,7 +189,7 @@ The Secure Hashing Algorithm (SHA1). - Due to collision problems with SHA1, Microsoft recommends SHA256. + Due to collision problems with SHA-1, Microsoft recommends SHA-256. diff --git a/xml/System.Security.Cryptography.Pkcs/Pkcs12Builder.xml b/xml/System.Security.Cryptography.Pkcs/Pkcs12Builder.xml index 30eea7645b3..ea5ec51b5fe 100644 --- a/xml/System.Security.Cryptography.Pkcs/Pkcs12Builder.xml +++ b/xml/System.Security.Cryptography.Pkcs/Pkcs12Builder.xml @@ -96,9 +96,9 @@ The password-based encryption (PBE) parameters to use when encrypting the contents. Add contents to the PFX in an bundle encrypted with a byte-based password from a byte array. - The password-based encryption (PBE) parameters to use when encrypting the contents. Add contents to the PFX in an bundle encrypted with a byte-based password from a span. - The password-based encryption (PBE) parameters to use when encrypting the contents. Add contents to the PFX in an bundle encrypted with a char-based password from a span. - The password-based encryption (PBE) parameters to use when encrypting the contents. Add contents to the PFX in an bundle encrypted with a char-based password from a string. - The contents to add to the PFX. Add contents to the PFX without encrypting them. - The iteration count for the Key Derivation Function (KDF) used in computing the MAC. Seals the PFX against further changes by applying a password-based Message Authentication Code (MAC) over the contents with a password from a span. - class. - Some choices of hash algorithm may cause failures in or on some operating systems, because these methods depend on system libraries for support. + Some choices of hash algorithm can cause failures in or on some operating systems, because these methods depend on system libraries for support. The hash algorithm used on a fresh installation of Windows 7 when exporting via as a PKCS#12 PFX is with an iteration count of 2000. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better; however, some PFX readers may only support SHA1. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better; however, some PFX readers might only support SHA-1. ]]> @@ -471,15 +471,15 @@ The iteration count for the Key Derivation Function (KDF) used in computing the MAC. Seals the PFX against further changes by applying a password-based Message Authentication Code (MAC) over the contents with a password from a string. - class. - Some choices of hash algorithm may cause failures in or on some operating systems, because these methods depend on system libraries for support. + Some choices of hash algorithm can cause failures in or on some operating systems, because these methods depend on system libraries for support. The hash algorithm used on a fresh installation of Windows 7 when exporting via as a PKCS#12 PFX is with an iteration count of 2000. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better; however, some PFX readers may only support SHA1. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better; however, some PFX readers might only support SHA-1. ]]> @@ -513,9 +513,9 @@ Seals the PFX from further changes without applying tamper-protection. - or which do not accept a password parameter, use the method with as the password. diff --git a/xml/System.Security.Cryptography.X509Certificates/X509Certificate.xml b/xml/System.Security.Cryptography.X509Certificates/X509Certificate.xml index a938febb58f..9599d7616fc 100644 --- a/xml/System.Security.Cryptography.X509Certificates/X509Certificate.xml +++ b/xml/System.Security.Cryptography.X509Certificates/X509Certificate.xml @@ -95,27 +95,27 @@ Provides methods that help you use X.509 v.3 certificates. - class instead. - + class instead. + > [!IMPORTANT] -> Starting with the .NET Framework 4.6, this type implements the interface. When you have finished using the type, you should dispose of it either directly or indirectly. To dispose of the type directly, call its method in a `try`/`catch` block. To dispose of it indirectly, use a language construct such as `using` (in C#) or `Using` (in Visual Basic). For more information, see the "Using an Object that Implements IDisposable" section in the interface topic. -> -> For apps that target the .NET Framework 4.5.2 and earlier versions, the class does not implement the interface and therefore does not have a `Dispose` method. - - - -## Examples - The following example loads an X.509 certificate from a file, calls the method, and displays the results to the console. - +> Starting with the .NET Framework 4.6, this type implements the interface. When you have finished using the type, you should dispose of it either directly or indirectly. To dispose of the type directly, call its method in a `try`/`catch` block. To dispose of it indirectly, use a language construct such as `using` (in C#) or `Using` (in Visual Basic). For more information, see the "Using an Object that Implements IDisposable" section in the interface topic. +> +> For apps that target the .NET Framework 4.5.2 and earlier versions, the class does not implement the interface and therefore does not have a `Dispose` method. + + + +## Examples + The following example loads an X.509 certificate from a file, calls the method, and displays the results to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/Cryptography.X509Certificates.X509Certificate/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/Overview/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/Cryptography.X509Certificates.X509Certificate/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/Cryptography.X509Certificates.X509Certificate/VB/example.vb" id="Snippet1"::: + ]]> @@ -184,11 +184,11 @@ Initializes a new instance of the class. - @@ -247,35 +247,35 @@ A byte array containing data from an X.509 certificate. Initializes a new instance of the class defined from a sequence of bytes representing an X.509v3 certificate. - certificate by specifying a PKCS7 signed file store for `data`, the is created for the certificate that signed the store rather than for any of the certificates within the store. - - - -## Examples - The following example loads an X.509 certificate file into an object, exports the certificate as a byte array, and then imports the byte array into another object. - + certificate by specifying a PKCS7 signed file store for `data`, the is created for the certificate that signed the store rather than for any of the certificates within the store. + + + +## Examples + The following example loads an X.509 certificate file into an object, exports the certificate as a byte array, and then imports the byte array into another object. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/Cryptography.X509Certificates.X509Certificate.Import-Export/CPP/sample.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/.ctor/sample.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/Cryptography.X509Certificates.X509Certificate.Import-Export/VB/sample.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/Cryptography.X509Certificates.X509Certificate.Import-Export/VB/sample.vb" id="Snippet1"::: + ]]> - An error with the certificate occurs. For example: - -- The certificate file does not exist. - -- The certificate is invalid. - + An error with the certificate occurs. For example: + +- The certificate file does not exist. + +- The certificate is invalid. + - The certificate's password is incorrect. - The parameter is . - - -or- - + The parameter is . + + -or- + The length of the parameter is 0. @@ -333,22 +333,22 @@ A handle to an unmanaged structure. Initializes a new instance of the class using a handle to an unmanaged structure. - object using a handle for the Microsoft Cryptographic API certificate context, `PCCERT_CONTEXT`. - + object using a handle for the Microsoft Cryptographic API certificate context, `PCCERT_CONTEXT`. + > [!IMPORTANT] -> This constructor creates a copy of the certificate context. Do not assume that the context structure you passed to the constructor is valid; it may have been released. You can get a copy of the current `PCCERT_CONTEXT` structure from the property, but it is valid only during the lifetime of the object. - +> This constructor creates a copy of the certificate context. Do not assume that the context structure you passed to the constructor is valid; it may have been released. You can get a copy of the current `PCCERT_CONTEXT` structure from the property, but it is valid only during the lifetime of the object. + ]]> - An error with the certificate occurs. For example: - -- The certificate file does not exist. - -- The certificate is invalid. - + An error with the certificate occurs. For example: + +- The certificate file does not exist. + +- The certificate is invalid. + - The certificate's password is incorrect. The handle parameter does not represent a valid structure. @@ -405,19 +405,19 @@ A class from which to initialize this class. Initializes a new instance of the class using another class. - - An error with the certificate occurs. For example: - -- The certificate file does not exist. - -- The certificate is invalid. - + An error with the certificate occurs. For example: + +- The certificate file does not exist. + +- The certificate is invalid. + - The certificate's password is incorrect. The value of the parameter is . @@ -479,30 +479,30 @@ The name of a PKCS7 signed file. Initializes a new instance of the class using the name of a PKCS7 signed file. - certificate by specifying a PKCS7 signed file store for `fileName`, the is created for the certificate that signed the store rather than for any of the certificates within the store. - - - -## Examples - The following example loads an X.509 certificate from a file, calls the method, and displays the results to the console. - + certificate by specifying a PKCS7 signed file store for `fileName`, the is created for the certificate that signed the store rather than for any of the certificates within the store. + + + +## Examples + The following example loads an X.509 certificate from a file, calls the method, and displays the results to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/Cryptography.X509Certificates.X509Certificate/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/Overview/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/Cryptography.X509Certificates.X509Certificate/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/Cryptography.X509Certificates.X509Certificate/VB/example.vb" id="Snippet1"::: + ]]> - An error with the certificate occurs. For example: - -- The certificate file does not exist. - -- The certificate is invalid. - + An error with the certificate occurs. For example: + +- The certificate file does not exist. + +- The certificate is invalid. + - The certificate's password is incorrect. The parameter is . @@ -572,29 +572,29 @@ The password required to access the X.509 certificate data. Initializes a new instance of the class using a byte array and a password. - [!IMPORTANT] -> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. - - If you create an certificate by specifying a PKCS7 signed file store for `rawData`, the is created for the certificate that signed the store rather than for any of the certificates within the store. - +> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. + + If you create an certificate by specifying a PKCS7 signed file store for `rawData`, the is created for the certificate that signed the store rather than for any of the certificates within the store. + ]]> - An error with the certificate occurs. For example: - -- The certificate file does not exist. - -- The certificate is invalid. - + An error with the certificate occurs. For example: + +- The certificate file does not exist. + +- The certificate is invalid. + - The certificate's password is incorrect. - The parameter is . - - -or- - + The parameter is . + + -or- + The length of the parameter is 0. @@ -661,29 +661,29 @@ The password required to access the X.509 certificate data. Initializes a new instance of the class using a byte array and a password. - [!IMPORTANT] -> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. - - If you create an certificate by specifying a PKCS7 signed file store for `rawData`, the is created for the certificate that signed the store rather than for any of the certificates within the store. - +> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. + + If you create an certificate by specifying a PKCS7 signed file store for `rawData`, the is created for the certificate that signed the store rather than for any of the certificates within the store. + ]]> - An error with the certificate occurs. For example: - -- The certificate file does not exist. - -- The certificate is invalid. - + An error with the certificate occurs. For example: + +- The certificate file does not exist. + +- The certificate is invalid. + - The certificate's password is incorrect. - The parameter is . - - -or- - + The parameter is . + + -or- + The length of the parameter is 0. @@ -740,12 +740,12 @@ A structure that describes how serialization should be performed. Initializes a new instance of the class using a object and a structure. To be added. - An error with the certificate occurs. For example: - -- The certificate file does not exist. - -- The certificate is invalid. - + An error with the certificate occurs. For example: + +- The certificate file does not exist. + +- The certificate is invalid. + - The certificate's password is incorrect. @@ -818,24 +818,24 @@ The password required to access the X.509 certificate data. Initializes a new instance of the class using a certificate file name and a password. - [!IMPORTANT] -> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. - - If you create an certificate by specifying a PKCS7 signed file store for `fileName`, the is created for the certificate that signed the store rather than for any of the certificates within the store. - +> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. + + If you create an certificate by specifying a PKCS7 signed file store for `fileName`, the is created for the certificate that signed the store rather than for any of the certificates within the store. + ]]> - An error with the certificate occurs. For example: - -- The certificate file does not exist. - -- The certificate is invalid. - + An error with the certificate occurs. For example: + +- The certificate file does not exist. + +- The certificate is invalid. + - The certificate's password is incorrect. The parameter is . @@ -907,21 +907,21 @@ The password required to access the X.509 certificate data. Initializes a new instance of the class using the name of a PKCS7 signed file and a password to access the certificate. - certificate by specifying a PKCS7 signed file store for `fileName`, the is created for the certificate that signed the store rather than for any of the certificates within the store. - + certificate by specifying a PKCS7 signed file store for `fileName`, the is created for the certificate that signed the store rather than for any of the certificates within the store. + ]]> - An error with the certificate occurs. For example: - -- The certificate file does not exist. - -- The certificate is invalid. - + An error with the certificate occurs. For example: + +- The certificate file does not exist. + +- The certificate is invalid. + - The certificate's password is incorrect. The parameter is . @@ -993,31 +993,31 @@ A bitwise combination of the enumeration values that control where and how to import the certificate. Initializes a new instance of the class using a byte array, a password, and a key storage flag. - [!IMPORTANT] -> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. - - If you create an certificate by specifying a PKCS7 signed file store for `rawData`, the is created for the certificate that signed the store rather than for any of the certificates within the store. - +> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. + + If you create an certificate by specifying a PKCS7 signed file store for `rawData`, the is created for the certificate that signed the store rather than for any of the certificates within the store. + ]]> - An error with the certificate occurs. For example: - -- The certificate file does not exist. - -- The certificate is invalid. - + An error with the certificate occurs. For example: + +- The certificate file does not exist. + +- The certificate is invalid. + - The certificate's password is incorrect. - The parameter is . - - -or- - + The parameter is . + + -or- + The length of the parameter is 0. @@ -1086,33 +1086,33 @@ A bitwise combination of the enumeration values that control where and how to import the certificate. Initializes a new instance of the class using a byte array, a password, and a key storage flag. - object using a byte array, a password that is needed to access the certificate data, and a key storage flag. Calling this constructor with the correct password decrypts the private key and saves it to a Microsoft Cryptographic API Cryptographic Service Provider (CSP). - - The value can be used to control where and how the private key is imported. - - ASN.1 DER is the only certificate format supported by this class. - + object using a byte array, a password that is needed to access the certificate data, and a key storage flag. Calling this constructor with the correct password decrypts the private key and saves it to a Microsoft Cryptographic API Cryptographic Service Provider (CSP). + + The value can be used to control where and how the private key is imported. + + ASN.1 DER is the only certificate format supported by this class. + > [!IMPORTANT] -> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. - - If you create an certificate by specifying a PKCS7 signed file store for `rawData`, the is created for the certificate that signed the store rather than for any of the certificates within the store. - +> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. + + If you create an certificate by specifying a PKCS7 signed file store for `rawData`, the is created for the certificate that signed the store rather than for any of the certificates within the store. + ]]> - An error with the certificate occurs. For example: - -- The certificate file does not exist. - -- The certificate is invalid. - + An error with the certificate occurs. For example: + +- The certificate file does not exist. + +- The certificate is invalid. + - The certificate's password is incorrect. - The parameter is . - - -or- - + The parameter is . + + -or- + The length of the parameter is 0. @@ -1187,19 +1187,19 @@ A bitwise combination of the enumeration values that control where and how to import the certificate. Initializes a new instance of the class using a certificate file name, a password, and a key storage flag. - certificate by specifying a PKCS7 signed file store for `fileName`, the is created for the certificate that signed the store rather than for any of the certificates within the store. - + certificate by specifying a PKCS7 signed file store for `fileName`, the is created for the certificate that signed the store rather than for any of the certificates within the store. + ]]> - An error with the certificate occurs. For example: - -- The certificate file does not exist. - -- The certificate is invalid. - + An error with the certificate occurs. For example: + +- The certificate file does not exist. + +- The certificate is invalid. + - The certificate's password is incorrect. The parameter is . @@ -1273,19 +1273,19 @@ A bitwise combination of the enumeration values that control where and how to import the certificate. Initializes a new instance of the class using the name of a PKCS7 signed file, a password to access the certificate, and a key storage flag. - certificate by specifying a PKCS7 signed file store for `fileName`, the is created for the certificate that signed the store rather than for any of the certificates within the store. - + certificate by specifying a PKCS7 signed file store for `fileName`, the is created for the certificate that signed the store rather than for any of the certificates within the store. + ]]> - An error with the certificate occurs. For example: - -- The certificate file does not exist. - -- The certificate is invalid. - + An error with the certificate occurs. For example: + +- The certificate file does not exist. + +- The certificate is invalid. + - The certificate's password is incorrect. The parameter is . @@ -1350,23 +1350,23 @@ Creates an X.509v3 certificate from the specified PKCS7 signed file. The newly created X.509 certificate. - [!NOTE] -> The certificate file is not restricted to .cer files. Any PKCS7 signed file can be used, including an Authenticode signed .pfx file. - - - -## Examples - The following example creates an from a specified certification file. - +> The certificate file is not restricted to .cer files. Any PKCS7 signed file can be used, including an Authenticode signed .pfx file. + + + +## Examples + The following example creates an from a specified certification file. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.ToString Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/CreateFromCertFile/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.ToString Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.ToString Method/VB/example.vb" id="Snippet1"::: + ]]> The parameter is . @@ -1432,11 +1432,11 @@ Creates an X.509v3 certificate from the specified signed file. The newly created X.509 certificate. - @@ -1450,13 +1450,13 @@ Releases the resources used by the current object. - [!NOTE] -> implements the interface starting with the .NET Framework 4.6; in previous versions of the .NET Framework, the class does not implement this interface, and therefore the `Dispose` method does not exist. - +> implements the interface starting with the .NET Framework 4.6; in previous versions of the .NET Framework, the class does not implement this interface, and therefore the `Dispose` method does not exist. + ]]> @@ -1506,13 +1506,13 @@ Releases all resources used by the current object. - [!NOTE] -> implements the interface starting with the .NET Framework 4.6; in previous versions of the .NET Framework, the class does not implement this interface, and therefore the `Dispose` method does not exist. - +> implements the interface starting with the .NET Framework 4.6; in previous versions of the .NET Framework, the class does not implement this interface, and therefore the `Dispose` method does not exist. + ]]> @@ -1569,13 +1569,13 @@ to release both managed and unmanaged resources; to release only unmanaged resources. Releases all of the unmanaged resources used by this and optionally releases the managed resources. - [!NOTE] -> implements the interface starting with the .NET Framework 4.6; in previous versions of the .NET Framework, the class does not implement this interface, and therefore the `Dispose` method does not exist. - +> implements the interface starting with the .NET Framework 4.6; in previous versions of the .NET Framework, the class does not implement this interface, and therefore the `Dispose` method does not exist. + ]]> @@ -1653,21 +1653,21 @@ if the current object is equal to the object specified by the parameter; otherwise, . - objects and they have the same issuer and serial number. - + objects and they have the same issuer and serial number. + > [!IMPORTANT] -> The `Equals` method should not be used when comparing certificates for security purposes. Instead, use a hash of the property, or the property. - -## Examples - The following example compares two certificates for equality. - +> The `Equals` method should not be used when comparing certificates for security purposes. Instead, use a hash of the property, or the property. + +## Examples + The following example compares two certificates for equality. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.Equals Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/Equals/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.Equals Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.Equals Method/VB/example.vb" id="Snippet1"::: + ]]> @@ -1735,21 +1735,21 @@ if the current object is equal to the object specified by the parameter; otherwise, . - objects are considered equal if they have the same issuer and serial number. - + objects are considered equal if they have the same issuer and serial number. + > [!IMPORTANT] -> The `Equals` method should not be used when comparing certificates for security purposes. Instead, use a hash of the property, or the property. - -## Examples - The following example compares two certificates for equality. - +> The `Equals` method should not be used when comparing certificates for security purposes. Instead, use a hash of the property, or the property. + +## Examples + The following example compares two certificates for equality. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.Equals Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/Equals/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.Equals Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.Equals Method/VB/example.vb" id="Snippet1"::: + ]]> @@ -1822,26 +1822,26 @@ Exports the current object to a byte array in a format described by one of the values. An array of bytes that represents the current object. - enumeration: , , and . Passing any other value causes a to be thrown. - - - -## Examples - The following example loads an X.509 certificate file into an object, exports the certificate as a byte array, and then imports the byte array into another object. - + enumeration: , , and . Passing any other value causes a to be thrown. + + + +## Examples + The following example loads an X.509 certificate file into an object, exports the certificate as a byte array, and then imports the byte array into another object. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/Cryptography.X509Certificates.X509Certificate.Import-Export/CPP/sample.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/.ctor/sample.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/Cryptography.X509Certificates.X509Certificate.Import-Export/VB/sample.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/Cryptography.X509Certificates.X509Certificate.Import-Export/VB/sample.vb" id="Snippet1"::: + ]]> - A value other than , , or was passed to the parameter. - - -or- - + A value other than , , or was passed to the parameter. + + -or- + The certificate could not be exported. @@ -1910,20 +1910,20 @@ Exports the current object to a byte array using the specified format and a password. A byte array that represents the current object. - enumeration: , , and . Passing any other value causes a to be thrown. - + enumeration: , , and . Passing any other value causes a to be thrown. + > [!IMPORTANT] -> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. - +> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. + ]]> - A value other than , , or was passed to the parameter. - - -or- - + A value other than , , or was passed to the parameter. + + -or- + The certificate could not be exported. @@ -1994,20 +1994,20 @@ Exports the current object to a byte array in a format described by one of the values, and using the specified password. An array of bytes that represents the current object. - enumeration: , , and . Passing any other value causes a to be thrown. - + enumeration: , , and . Passing any other value causes a to be thrown. + > [!IMPORTANT] -> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. - +> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. + ]]> - A value other than , , or was passed to the parameter. - - -or- - + A value other than , , or was passed to the parameter. + + -or- + The certificate could not be exported. @@ -2055,11 +2055,11 @@ Converts the specified date and time to a string. A string representation of the value of the object. - falls back to a calendar that can express the date. If the value is , the calendar is changed to the class; otherwise, it is changed to the . - + falls back to a calendar that can express the date. If the value is , the calendar is changed to the class; otherwise, it is changed to the . + ]]> @@ -2114,15 +2114,15 @@ Returns the hash value for the X.509v3 certificate as an array of bytes. The hash value for the X.509 certificate. - method to fill an array of bytes with the hash value for an X.509 certificate. - + method to fill an array of bytes with the hash value for an X.509 certificate. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetCertHash Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetCertHash/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetCertHash Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetCertHash Method/VB/example.vb" id="Snippet1"::: + ]]> @@ -2226,18 +2226,18 @@ - Returns the SHA1 hash value for the X.509v3 certificate as a hexadecimal string. + Returns the SHA-1 hash value for the X.509v3 certificate as a hexadecimal string. The hexadecimal string representation of the X.509 certificate hash value. - method to get an X.509 certificate hash value, convert it to a string, and display it to the console. - + method to get an X.509 certificate hash value, convert it to a string, and display it to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetCertHashString Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetCertHashString/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetCertHashString Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetCertHashString Method/VB/example.vb" id="Snippet1"::: + ]]> @@ -2332,22 +2332,22 @@ Returns the effective date of this X.509v3 certificate. The effective date for this X.509 certificate. - method returns a string that shows the date formatted in Short Date Pattern followed by the time formatted in Long Time Pattern. The date and time are formatted using the current culture and time zone. - - - -## Examples - The following example uses the method to get the effective date of a certificate and displays it to the console. - + method returns a string that shows the date formatted in Short Date Pattern followed by the time formatted in Long Time Pattern. The date and time are formatted using the current culture and time zone. + + + +## Examples + The following example uses the method to get the effective date of a certificate and displays it to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetEffectiveDateString Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetEffectiveDateString/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetEffectiveDateString Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetEffectiveDateString Method/VB/example.vb" id="Snippet1"::: + ]]> @@ -2395,25 +2395,25 @@ Returns the expiration date of this X.509v3 certificate. The expiration date for this X.509 certificate. - method returns a string that shows the date formatted in Short Date Pattern followed by the time formatted in Long Time Pattern. The date and time are formatted using the current culture and time zone. - + method returns a string that shows the date formatted in Short Date Pattern followed by the time formatted in Long Time Pattern. The date and time are formatted using the current culture and time zone. + > [!NOTE] -> This method may return a different string format on Macintosh computers, although the underlying object will represent the same value. - - - -## Examples - The following example uses the method to get the expiration date of a certificate and displays it to the console. - +> This method may return a different string format on Macintosh computers, although the underlying object will represent the same value. + + + +## Examples + The following example uses the method to get the expiration date of a certificate and displays it to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetExpirationDateString Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetExpirationDateString/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetExpirationDateString Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetExpirationDateString Method/VB/example.vb" id="Snippet1"::: + ]]> @@ -2463,20 +2463,20 @@ Returns the name of the format of this X.509v3 certificate. The format of this X.509 certificate. - method to get the format of a certificate and displays it to the console. - + method to get the format of a certificate and displays it to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetFormat Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetFormat/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetFormat Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetFormat Method/VB/example.vb" id="Snippet1"::: + ]]> @@ -2532,20 +2532,20 @@ Returns the hash code for the X.509v3 certificate as an integer. The hash code for the X.509 certificate as an integer. - method to return an integer representation of a certificate's hash code and displays it to the console. - + method to return an integer representation of a certificate's hash code and displays it to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetHashCode Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetHashCode/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetHashCode Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetHashCode Method/VB/example.vb" id="Snippet1"::: + ]]> @@ -2611,23 +2611,23 @@ Returns the name of the certification authority that issued the X.509v3 certificate. The name of the certification authority that issued the X.509 certificate. - method to return the certificate issuer's name and displays it to the console. - + method to return the certificate issuer's name and displays it to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetIssuerName Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetIssuerName/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetIssuerName Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetIssuerName Method/VB/example.vb" id="Snippet1"::: + ]]> - An error with the certificate occurs. For example: - -- The certificate file does not exist. - -- The certificate is invalid. - + An error with the certificate occurs. For example: + +- The certificate file does not exist. + +- The certificate is invalid. + - The certificate's password is incorrect. @@ -2682,15 +2682,15 @@ Returns the key algorithm information for this X.509v3 certificate as a string. The key algorithm information for this X.509 certificate as a string. - method to get a certificate's key algorithm in string format and displays it to the console. - + method to get a certificate's key algorithm in string format and displays it to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetKeyAlgorithm Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetKeyAlgorithm/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetKeyAlgorithm Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetKeyAlgorithm Method/VB/example.vb" id="Snippet1"::: + ]]> The certificate context is invalid. @@ -2747,15 +2747,15 @@ Returns the key algorithm parameters for the X.509v3 certificate as an array of bytes. The key algorithm parameters for the X.509 certificate as an array of bytes. - method to return a certificate's key algorithm parameters as an array of bytes and displays it to the console. - + method to return a certificate's key algorithm parameters as an array of bytes and displays it to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetKeyAlgorithmParameters Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetKeyAlgorithmParameters/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetKeyAlgorithmParameters Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetKeyAlgorithmParameters Method/VB/example.vb" id="Snippet1"::: + ]]> The certificate context is invalid. @@ -2812,15 +2812,15 @@ Returns the key algorithm parameters for the X.509v3 certificate as a hexadecimal string. The key algorithm parameters for the X.509 certificate as a hexadecimal string. - method to return a certificate's key algorithm parameters in string format and displays it to the console. - + method to return a certificate's key algorithm parameters in string format and displays it to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetKeyAlgorithmParametersString/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetKeyAlgorithmParametersString/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetKeyAlgorithmParametersString/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetKeyAlgorithmParametersString/VB/example.vb" id="Snippet1"::: + ]]> The certificate context is invalid. @@ -2887,15 +2887,15 @@ Returns the name of the principal to which the certificate was issued. The name of the principal to which the certificate was issued. - method to return the name of a certificate's principal and displays it to the console. - + method to return the name of a certificate's principal and displays it to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetName Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetName/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetName Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetName Method/VB/example.vb" id="Snippet1"::: + ]]> The certificate context is invalid. @@ -2952,17 +2952,17 @@ Returns the public key for the X.509v3 certificate as an array of bytes. The public key for the X.509 certificate as an array of bytes. - method to return a certificate's public key as an array of bytes and displays it to the console. - + +## Examples + The following example uses the method to return a certificate's public key as an array of bytes and displays it to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetPublicKey Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetPublicKey/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetPublicKey Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetPublicKey Method/VB/example.vb" id="Snippet1"::: + ]]> The certificate context is invalid. @@ -3011,17 +3011,17 @@ This value corresponds to the contents of the `subjectPublicKey` field of the Su Returns the public key for the X.509v3 certificate as a hexadecimal string. The public key for the X.509 certificate as a hexadecimal string. - method to return a certificate's public key as a string and displays it to the console. - + +## Examples + The following example uses the method to return a certificate's public key as a string and displays it to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetPublicKeyString Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetPublicKeyString/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetPublicKeyString Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetPublicKeyString Method/VB/example.vb" id="Snippet1"::: + ]]> @@ -3075,17 +3075,17 @@ This value corresponds to the contents of the `subjectPublicKey` field of the Su Returns the raw data for the entire X.509v3 certificate as an array of bytes. A byte array containing the X.509 certificate data. - method with an output encoding of . - -## Examples - The following example uses the method to return a certificate's raw data as an array of bytes and displays it to the console. - + +## Examples + The following example uses the method to return a certificate's raw data as an array of bytes and displays it to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetRawCertData Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetRawCertData/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetRawCertData Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetRawCertData Method/VB/example.vb" id="Snippet1"::: + ]]> @@ -3133,15 +3133,15 @@ The output of this method is equivalent to the output of the Returns the raw data for the entire X.509v3 certificate as a hexadecimal string. The X.509 certificate data as a hexadecimal string. - method to return a certificate's raw data as a string and displays it to the console. - + method to return a certificate's raw data as a string and displays it to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetRawCertDataString Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetRawCertDataString/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetRawCertDataString Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetRawCertDataString Method/VB/example.vb" id="Snippet1"::: + ]]> @@ -3197,15 +3197,15 @@ The output of this method is equivalent to the output of the Returns the serial number of the X.509v3 certificate as an array of bytes in little-endian order. The serial number of the X.509 certificate as an array of bytes in little-endian order. - method to return a certificate's serial number as an array of bytes and displays it to the console. - + method to return a certificate's serial number as an array of bytes and displays it to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetSerialNumber Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetSerialNumber/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetSerialNumber Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetSerialNumber Method/VB/example.vb" id="Snippet1"::: + ]]> The certificate context is invalid. @@ -3254,15 +3254,15 @@ The output of this method is equivalent to the output of the Returns the serial number of the X.509v3 certificate as a little-endian hexadecimal string . The serial number of the X.509 certificate as a little-endian hexadecimal string. - method to return a certificate's serial number as a string and displays it to the console. - + method to return a certificate's serial number as a string and displays it to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.GetSerialNumberString Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/GetSerialNumberString/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetSerialNumberString Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.GetSerialNumberString Method/VB/example.vb" id="Snippet1"::: + ]]> @@ -3320,11 +3320,11 @@ The output of this method is equivalent to the output of the Gets a handle to a Microsoft Cryptographic API certificate context described by an unmanaged structure. An structure that represents an unmanaged structure. - object. - + object. + ]]> @@ -3401,17 +3401,17 @@ The output of this method is equivalent to the output of the A byte array containing data from an X.509 certificate. Populates the object with data from a byte array. - object with its associated values. - + object with its associated values. + ]]> - The parameter is . - - -or- - + The parameter is . + + -or- + The length of the parameter is 0. .NET Core and .NET 5+ only: In all cases. @@ -3478,20 +3478,20 @@ The output of this method is equivalent to the output of the The name of a certificate file represented as a string. Populates the object with information from a certificate file. - object with the certificate that the file contains. - - - -## Examples - The following example loads an X.509 certificate from a file, calls the method, and displays the results to the console. - + object with the certificate that the file contains. + + + +## Examples + The following example loads an X.509 certificate from a file, calls the method, and displays the results to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/Cryptography.X509Certificates.X509Certificate.Import/CPP/sample.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/Import/sample.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/Cryptography.X509Certificates.X509Certificate.Import/VB/sample.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/Cryptography.X509Certificates.X509Certificate.Import/VB/sample.vb" id="Snippet1"::: + ]]> The parameter is . @@ -3572,19 +3572,19 @@ The output of this method is equivalent to the output of the A bitwise combination of the enumeration values that control where and how to import the certificate. Populates an object using data from a byte array, a password, and a key storage flag. - [!IMPORTANT] -> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. - +> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. + ]]> - The parameter is . - - -or- - + The parameter is . + + -or- + The length of the parameter is 0. .NET Core and .NET 5+ only: In all cases. @@ -3663,17 +3663,17 @@ The output of this method is equivalent to the output of the A bitwise combination of the enumeration values that control where and how to import the certificate. Populates the object using data from a byte array, a password, and flags for determining how the private key is imported. - object using a password for the certificate represented by the byte array. The value can be used to control where and how the private key is imported. - + object using a password for the certificate represented by the byte array. The value can be used to control where and how the private key is imported. + ]]> - The parameter is . - - -or- - + The parameter is . + + -or- + The length of the parameter is 0. .NET Core and .NET 5+ only: In all cases. @@ -3752,13 +3752,13 @@ The output of this method is equivalent to the output of the A bitwise combination of the enumeration values that control where and how to import the certificate. Populates an object with information from a certificate file, a password, and a key storage flag. - [!IMPORTANT] -> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. - +> Never hard code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. + ]]> The parameter is . @@ -3839,13 +3839,13 @@ The output of this method is equivalent to the output of the A bitwise combination of the enumeration values that control where and how to import the certificate. Populates the object with information from a certificate file, a password, and a value. - [!IMPORTANT] -> Never hard-code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. - +> Never hard-code a password within your source code. Hard-coded passwords can be retrieved from an assembly using the [Ildasm.exe (IL Disassembler)](/dotnet/framework/tools/ildasm-exe-il-disassembler), a hex editor, or by simply opening the assembly in a text editor such as Notepad.exe. + ]]> The parameter is . @@ -3955,11 +3955,11 @@ The output of this method is equivalent to the output of the Resets the state of the object. - method to reset the state of the certificate. This method also frees any resources associated with the certificate. - + method to reset the state of the certificate. This method also frees any resources associated with the certificate. + ]]> @@ -4216,15 +4216,15 @@ The output of this method is equivalent to the output of the Returns a string representation of the current object. A string representation of the current object. - method to display the value of a certificate to the console. - + method to display the value of a certificate to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.ToString Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/CreateFromCertFile/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.ToString Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.ToString Method/VB/example.vb" id="Snippet1"::: + ]]> @@ -4284,15 +4284,15 @@ The output of this method is equivalent to the output of the Returns a string representation of the current object, with extra information, if specified. A string representation of the current object. - method to display the value of a certificate to the console. - + method to display the value of a certificate to the console. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/X509Certificate.ToString Method/CPP/example.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.X509Certificates/X509Certificate/CreateFromCertFile/example.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.ToString Method/VB/example.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/X509Certificate.ToString Method/VB/example.vb" id="Snippet1"::: + ]]> diff --git a/xml/System.Security.Cryptography.Xml/Reference.xml b/xml/System.Security.Cryptography.Xml/Reference.xml index 87e538379d7..6b564ff911e 100644 --- a/xml/System.Security.Cryptography.Xml/Reference.xml +++ b/xml/System.Security.Cryptography.Xml/Reference.xml @@ -39,34 +39,34 @@ Represents the element of an XML signature. - object represents the `` element of an XML digital signature defined by the XML digital signature specification. - - Use the object to specify the following information: - -- The digest algorithm used to sign of the data object. This value is required. - -- The Uniform Resource Identifier (URI) of the data object to sign. The URI can specify a file path or specific elements within an XML document. This value is required. - -- A chain of transforms to apply before generating the digest. This value is optional. - -- The type of object to sign. This value is optional. - -- A unique identifier used to reference the current `` element. This value is optional. - - For more information about the `` element, see the [W3C specification](https://www.w3.org/TR/xmldsig-core/). - - - -## Examples - The following code example demonstrates how to generate and verify an enveloped XML signature using the object. - + object represents the `` element of an XML digital signature defined by the XML digital signature specification. + + Use the object to specify the following information: + +- The digest algorithm used to sign of the data object. This value is required. + +- The Uniform Resource Identifier (URI) of the data object to sign. The URI can specify a file path or specific elements within an XML document. This value is required. + +- A chain of transforms to apply before generating the digest. This value is optional. + +- The type of object to sign. This value is optional. + +- A unique identifier used to reference the current `` element. This value is optional. + + For more information about the `` element, see the [W3C specification](https://www.w3.org/TR/xmldsig-core/). + + + +## Examples + The following code example demonstrates how to generate and verify an enveloped XML signature using the object. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigEnvelope/CPP/xmldsigenv.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.Xml/KeyInfo/Overview/xmldsigenv.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigEnvelope/VB/xmldsigenv.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigEnvelope/VB/xmldsigenv.vb" id="Snippet1"::: + ]]> @@ -108,21 +108,21 @@ Initializes a new instance of the class with default properties. - object. - + object. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigEnvelope/CPP/xmldsigenv.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.Xml/KeyInfo/Overview/xmldsigenv.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigEnvelope/VB/xmldsigenv.vb" id="Snippet1"::: - - The following code example demonstrates how to generate and verify a detached XML signature using the object. - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigEnvelope/VB/xmldsigenv.vb" id="Snippet1"::: + + The following code example demonstrates how to generate and verify a detached XML signature using the object. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigDetached/CPP/xmldsigdetach.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.Xml/KeyInfo/Overview/xmldsigdetach.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigDetached/VB/xmldsigdetach.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigDetached/VB/xmldsigdetach.vb" id="Snippet1"::: + ]]> @@ -159,11 +159,11 @@ The with which to initialize the new instance of . Initializes a new instance of the class with a hash value of the specified . - object to the hash value that corresponds to the `stream` parameter. - + object to the hash value that corresponds to the `stream` parameter. + ]]> @@ -201,20 +201,20 @@ The with which to initialize the new instance of . Initializes a new instance of the class with the specified . - object to the data at the URI with special processing for `""`, `#xpointer(/)`, and `#xxxx`. - - - -## Examples - The following code example uses the class to sign and verify an XML document using an envelope signature. - + object to the data at the URI with special processing for `""`, `#xpointer(/)`, and `#xxxx`. + + + +## Examples + The following code example uses the class to sign and verify an XML document using an envelope signature. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/Cryptography.XML.Signature - Envelope/CPP/sample.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.Xml/Reference/.ctor/sample.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/Cryptography.XML.Signature - Envelope/VB/sample.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/Cryptography.XML.Signature - Envelope/VB/sample.vb" id="Snippet1"::: + ]]> @@ -254,30 +254,30 @@ The transform to be added to the list of transforms. Adds a object to the list of transforms to be performed on the data before passing it to the digest algorithm. - method modifies the `` element and associated subelements of an XML digital signature. - - Transforms are applied in the order in which they were added. If no transforms are specified, the minimum required transforms are added automatically. - - For more information about XML digital signatures, see the [W3C specification](https://www.w3.org/TR/xmldsig-core/). - - - -## Examples - The following code example demonstrates how to generate and verify an enveloped XML signature using the object. - + method modifies the `` element and associated subelements of an XML digital signature. + + Transforms are applied in the order in which they were added. If no transforms are specified, the minimum required transforms are added automatically. + + For more information about XML digital signatures, see the [W3C specification](https://www.w3.org/TR/xmldsig-core/). + + + +## Examples + The following code example demonstrates how to generate and verify an enveloped XML signature using the object. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigEnvelope/CPP/xmldsigenv.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.Xml/KeyInfo/Overview/xmldsigenv.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigEnvelope/VB/xmldsigenv.vb" id="Snippet1"::: - - The following code example demonstrates how to generate and verify a detached XML signature using the object. - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigEnvelope/VB/xmldsigenv.vb" id="Snippet1"::: + + The following code example demonstrates how to generate and verify a detached XML signature using the object. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigDetached/CPP/xmldsigdetach.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.Xml/KeyInfo/Overview/xmldsigdetach.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigDetached/VB/xmldsigdetach.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigDetached/VB/xmldsigdetach.vb" id="Snippet1"::: + ]]> The parameter is . @@ -321,15 +321,15 @@ Gets or sets the digest method Uniform Resource Identifier (URI) of the current . The digest method URI of the current . The default value is http://www.w3.org/2001/04/xmlenc#sha256. - property uses a URI string to represent the `` element of an XML digital signature. - - The digest method is the algorithm used to hash the . The default algorithm is . - - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. For more information about XML digital signatures, see the [W3C specification](https://www.w3.org/TR/xmldsig-core/). - + property uses a URI string to represent the `` element of an XML digital signature. + + The digest method is the algorithm used to hash the . The default algorithm is . + + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. For more information about XML digital signatures, see the [W3C specification](https://www.w3.org/TR/xmldsig-core/). + ]]> @@ -367,17 +367,17 @@ Gets or sets the digest value of the current . The digest value of the current . - property uses an array of bytes to represent the `` element of an XML digital signature. - - The property contains the Base 64 encoded value of the digest of the object described by the property. - - The property is automatically populated with the appropriate value whenever you make a call to . - - For more information about XML digital signatures, see the [W3C specification](https://www.w3.org/TR/xmldsig-core/). - + property uses an array of bytes to represent the `` element of an XML digital signature. + + The property contains the Base 64 encoded value of the digest of the object described by the property. + + The property is automatically populated with the appropriate value whenever you make a call to . + + For more information about XML digital signatures, see the [W3C specification](https://www.w3.org/TR/xmldsig-core/). + ]]> @@ -415,10 +415,10 @@ Returns the XML representation of the . The XML representation of the . To be added. - The property is . - - -or- - + The property is . + + -or- + The property is . @@ -455,11 +455,11 @@ Gets or sets the ID of the current . The ID of the current . The default is . - property to add a string ID to the XML representation of the current element. The ID is used to reference the element from another location. - + property to add a string ID to the XML representation of the current element. The ID is used to reference the element from another location. + ]]> @@ -510,10 +510,10 @@ Loads a state from an XML element. To be added. The parameter is . - The parameter does not contain any transforms. - - -or- - + The parameter does not contain any transforms. + + -or- + The parameter contains an unknown transform. @@ -563,15 +563,15 @@ Gets the transform chain of the current . The transform chain of the current . - property represents the `` element and associated subelements of an XML digital signature. - - The transform chain is an ordered list of transforms. The output of these transforms constitutes the input to the hash algorithm specified in the property. - - For more information about XML digital signatures, see the [W3C specification](https://www.w3.org/TR/xmldsig-core/). - + property represents the `` element and associated subelements of an XML digital signature. + + The transform chain is an ordered list of transforms. The output of these transforms constitutes the input to the hash algorithm specified in the property. + + For more information about XML digital signatures, see the [W3C specification](https://www.w3.org/TR/xmldsig-core/). + ]]> @@ -644,32 +644,32 @@ Gets or sets the of the current . The of the current . - property uses a string Uniform Resource Identifier (URI) to represent the `` element of an XML digital signature. - - Use the property to specify the location of a document to sign, and to specify which element of the current XML document to sign or to indicate that the entire document should be signed. - - To successfully create an XML digital signature, you must set the property. The following table describes the values that you can pass to the property. - -|Object to sign|Value passed to the property| -|--------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -|An entire XML document using an enveloped signature.|An empty string: ""| -|A specific element within an XML document using an enveloped signature.|The name of an XML element identified by an attribute name ID. The string should take the following form where `IDname` is the name of a valid attribute name ID:

"#Idname"| -|A file using a detached signature.|The URI of a file: "c:\data.jpg" or "c:\data.xml".| - - For more information about XML digital signatures, see the World Wide Web Consortium (W3C) [XML Signature Syntax and Processing Specification](https://www.w3.org/TR/xmldsig-core/). - - - -## Examples - The following code example demonstrates how to generate and verify an enveloped XML signature using the object. - + property uses a string Uniform Resource Identifier (URI) to represent the `` element of an XML digital signature. + + Use the property to specify the location of a document to sign, and to specify which element of the current XML document to sign or to indicate that the entire document should be signed. + + To successfully create an XML digital signature, you must set the property. The following table describes the values that you can pass to the property. + +|Object to sign|Value passed to the property| +|--------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +|An entire XML document using an enveloped signature.|An empty string: ""| +|A specific element within an XML document using an enveloped signature.|The name of an XML element identified by an attribute name ID. The string should take the following form where `IDname` is the name of a valid attribute name ID:

"#Idname"| +|A file using a detached signature.|The URI of a file: "c:\data.jpg" or "c:\data.xml".| + + For more information about XML digital signatures, see the World Wide Web Consortium (W3C) [XML Signature Syntax and Processing Specification](https://www.w3.org/TR/xmldsig-core/). + + + +## Examples + The following code example demonstrates how to generate and verify an enveloped XML signature using the object. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigEnvelope/CPP/xmldsigenv.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography.Xml/KeyInfo/Overview/xmldsigenv.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigEnvelope/VB/xmldsigenv.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.XML-XMLDsigEnvelope/VB/xmldsigenv.vb" id="Snippet1"::: + ]]>
diff --git a/xml/System.Security.Cryptography.Xml/SignedInfo.xml b/xml/System.Security.Cryptography.Xml/SignedInfo.xml index 35887f11b94..a88a6084b24 100644 --- a/xml/System.Security.Cryptography.Xml/SignedInfo.xml +++ b/xml/System.Security.Cryptography.Xml/SignedInfo.xml @@ -54,15 +54,15 @@ Contains information about the canonicalization algorithm and signature algorithm used for the XML signature. - class represents the `` element of an XML signature defined by the XML digital signature specification. The `` element, which is a subelement of the `` element, contains the canonicalization method used for signing, the algorithm used for signing and validation, and references that describe a digital signature. - - For most scenarios, you should use the class available from the property to sign and verify XML digital signatures. - - For more information about the `` element, see the [World Wide Web Consortium (W3C) specification](https://www.w3.org/TR/xmldsig-core/). - + class represents the `` element of an XML signature defined by the XML digital signature specification. The `` element, which is a subelement of the `` element, contains the canonicalization method used for signing, the algorithm used for signing and validation, and references that describe a digital signature. + + For most scenarios, you should use the class available from the property to sign and verify XML digital signatures. + + For more information about the `` element, see the [World Wide Web Consortium (W3C) specification](https://www.w3.org/TR/xmldsig-core/). + ]]> @@ -132,11 +132,11 @@ The reference to add to the list of references. Adds a object to the list of references to digest and sign. - method adds a object to a collection that is accessible using the property. - + method adds a object to a collection that is accessible using the property. + ]]> The reference parameter is . @@ -174,24 +174,24 @@ Gets or sets the canonicalization algorithm that is used before signing for the current object. The canonicalization algorithm used before signing for the current object. - property uses a string Uniform Resource Identifier (URI) to represent the `` element of an XML digital signature. - - Use the property to specify the canonicalization algorithm applied to the XML output of the class before performing signature calculations. - - Use one of the URIs listed in the following table with this property. - -|Canonicalization Method|Value| -|-----------------------------|-----------| -|Canonical XML|

This is default method. Also defined in the following static field: | -|Canonical XML with comments|

Also defined in the following static field: | -|Exclusive Canonical XML|

Also defined in the following static field: | -|Exclusive Canonical XML with comments|

Also defined in the following static field: | - - For more information about XML digital signatures, see the [World Wide Web Consortium (W3C) specification](https://www.w3.org/TR/xmldsig-core/). - + property uses a string Uniform Resource Identifier (URI) to represent the `` element of an XML digital signature. + + Use the property to specify the canonicalization algorithm applied to the XML output of the class before performing signature calculations. + + Use one of the URIs listed in the following table with this property. + +|Canonicalization Method|Value| +|-----------------------------|-----------| +|Canonical XML|

This is default method. Also defined in the following static field: | +|Canonical XML with comments|

Also defined in the following static field: | +|Exclusive Canonical XML|

Also defined in the following static field: | +|Exclusive Canonical XML with comments|

Also defined in the following static field: | + + For more information about XML digital signatures, see the [World Wide Web Consortium (W3C) specification](https://www.w3.org/TR/xmldsig-core/). + ]]>
@@ -233,13 +233,13 @@ Gets a object used for canonicalization. A object used for canonicalization. - property contains the object used by the class to canonicalize an XML document before signing or verifying. - - The property is read-only. You can modify the object within this property by passing the desired transform Uniform Resource Identifier (URI) to the property. - + property contains the object used by the class to canonicalize an XML document before signing or verifying. + + The property is read-only. You can modify the object within this property by passing the desired transform Uniform Resource Identifier (URI) to the property. + ]]> @@ -408,10 +408,10 @@ Returns the XML representation of the object. The XML representation of the instance. To be added. - The property is . - - -or- - + The property is . + + -or- + The property is empty. @@ -454,11 +454,11 @@ Gets or sets the ID of the current object. The ID of the current object. - property to add a string ID to the XML representation of the current element. The ID is used to reference the from another location. - + property to add a string ID to the XML representation of the current element. The ID is used to reference the from another location. + ]]> @@ -580,14 +580,14 @@ Loads a state from an XML element. To be added. The parameter is . - The parameter is not a valid element. - - -or- - - The parameter does not contain a valid property. - - -or- - + The parameter is not a valid element. + + -or- + + The parameter does not contain a valid property. + + -or- + The parameter does not contain a valid property. @@ -623,15 +623,15 @@ Gets a list of the objects of the current object. A list of the elements of the current object. - property uses a list of objects to represent the `` elements of an XML digital signature. - - Use the property to describe the transforms, digest algorithms, and digest values of an XML digital signature. - - For more information about XML digital signatures, see the [World Wide Web Consortium (W3C) specification](https://www.w3.org/TR/xmldsig-core/). - + property uses a list of objects to represent the `` elements of an XML digital signature. + + Use the property to describe the transforms, digest algorithms, and digest values of an XML digital signature. + + For more information about XML digital signatures, see the [World Wide Web Consortium (W3C) specification](https://www.w3.org/TR/xmldsig-core/). + ]]> @@ -716,23 +716,23 @@ Gets or sets the name of the algorithm used for signature generation and validation for the current object. The name of the algorithm used for signature generation and validation for the current object. - property uses a string Uniform Resource Identifier (URI) to represents the `` element of an XML digital signature. - - Use the property to specify the algorithm to use for signature generation and verification. This property identifies all cryptographic functions involved in creating an XML digital signature, including hashing, public key algorithms, Message Authentication Codes (MACs), and padding. - - Use one of the URIs in the following table with this property. - -|Signature Method|Value| -|----------------------|-----------| -|HMAC-SHA1|`http://www.w3.org/2000/09/xmldsig#hmac-sha1`

Also defined in the following static field: | -|DSA with SHA1|`http://www.w3.org/2000/09/xmldsig#dsa-sha1`

Also defined in the following static field: | -|RSA with SHA1|`http://www.w3.org/2000/09/xmldsig#rsa-sha1`

Also defined in the following static field: | - - For more information about XML digital signatures, see the World Wide Web Consortium (W3C) [XML Signature Syntax and Processing Specification](https://www.w3.org/TR/xmldsig-core/). - + property uses a string Uniform Resource Identifier (URI) to represents the `` element of an XML digital signature. + + Use the property to specify the algorithm to use for signature generation and verification. This property identifies all cryptographic functions involved in creating an XML digital signature, including hashing, public key algorithms, Message Authentication Codes (MACs), and padding. + + Use one of the URIs in the following table with this property. + +|Signature Method|Value| +|----------------------|-----------| +|HMAC SHA-1|`http://www.w3.org/2000/09/xmldsig#hmac-sha1`

Also defined in the following static field: | +|DSA with SHA-1|`http://www.w3.org/2000/09/xmldsig#dsa-sha1`

Also defined in the following static field: | +|RSA with SHA-1|`http://www.w3.org/2000/09/xmldsig#rsa-sha1`

Also defined in the following static field: | + + For more information about XML digital signatures, see the World Wide Web Consortium (W3C) [XML Signature Syntax and Processing Specification](https://www.w3.org/TR/xmldsig-core/). + ]]>
diff --git a/xml/System.Security.Cryptography.Xml/SignedXml.xml b/xml/System.Security.Cryptography.Xml/SignedXml.xml index 8d713912b96..2295e750831 100644 --- a/xml/System.Security.Cryptography.Xml/SignedXml.xml +++ b/xml/System.Security.Cryptography.Xml/SignedXml.xml @@ -2298,7 +2298,7 @@ The following code example shows how to sign and verify a single element of an X For more information, see the [World Wide Web Consortium (W3C) specification](https://www.w3.org/2000/09/xmldsig#hmac-sha1). - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> @@ -2432,7 +2432,7 @@ The following code example shows how to sign and verify a single element of an X For more information, see the [World Wide Web Consortium (W3C) schema](https://www.w3.org/2000/09/xmldsig#rsa-sha1). - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> @@ -2604,7 +2604,7 @@ The following code example shows how to sign and verify a single element of an X For more information, see the [World Wide Web Consortium (W3C) schema](https://www.w3.org/2000/09/xmldsig#sha1). - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> diff --git a/xml/System.Security.Cryptography/CngAlgorithm.xml b/xml/System.Security.Cryptography/CngAlgorithm.xml index cb4cd32ec8d..d7c067b7bbb 100644 --- a/xml/System.Security.Cryptography/CngAlgorithm.xml +++ b/xml/System.Security.Cryptography/CngAlgorithm.xml @@ -62,17 +62,17 @@ Encapsulates the name of an encryption algorithm. - class is a utility class. It consists of static properties, comparison methods, and a private, internally maintained, algorithm name string. - - The static properties return objects. Each object's internal string is initialized to the algorithm name that corresponds to the name of the static property. - - You can also use this class to create objects for algorithm types that are not covered by the static properties. - - Several Cryptography Next Generation (CNG) classes (such as ) accept objects through an `algorithm` parameter. When the class receives the object, it retrieves the embedded algorithm name by calling the object's property. - + class is a utility class. It consists of static properties, comparison methods, and a private, internally maintained, algorithm name string. + + The static properties return objects. Each object's internal string is initialized to the algorithm name that corresponds to the name of the static property. + + You can also use this class to create objects for algorithm types that are not covered by the static properties. + + Several Cryptography Next Generation (CNG) classes (such as ) accept objects through an `algorithm` parameter. When the class receives the object, it retrieves the embedded algorithm name by calling the object's property. + Therefore, serves as an enumeration of well-known algorithms. It lets you specify a well-known algorithm by using a strongly typed value instead of a string. > [!NOTE] @@ -123,13 +123,13 @@ The name of the algorithm to initialize. Initializes a new instance of the class. - class internally maintain the algorithm name that is specified by the `algorithm` parameter. - - The primary purpose of this constructor is to provide a method for creating objects for algorithm types that are not represented by the static properties of the class. This capacity enables future .NET Framework releases, service packs, and third-party developers to add new algorithms, which can be accessed just like the algorithms that are currently available. - + class internally maintain the algorithm name that is specified by the `algorithm` parameter. + + The primary purpose of this constructor is to provide a method for creating objects for algorithm types that are not represented by the static properties of the class. This capacity enables future .NET Framework releases, service packs, and third-party developers to add new algorithms, which can be accessed just like the algorithms that are currently available. + ]]> The parameter is . @@ -735,7 +735,7 @@ Gets a new object that specifies the Message Digest 5 (MD5) hash algorithm. An object that specifies the MD5 algorithm. - Due to collision problems with MD5, Microsoft recommends a security model based on SHA256. + Due to collision problems with MD5, Microsoft recommends a security model based on SHA-256. diff --git a/xml/System.Security.Cryptography/CryptoConfig.xml b/xml/System.Security.Cryptography/CryptoConfig.xml index 2b41cbc8686..0c7ca1c956e 100644 --- a/xml/System.Security.Cryptography/CryptoConfig.xml +++ b/xml/System.Security.Cryptography/CryptoConfig.xml @@ -65,60 +65,60 @@ Accesses the cryptography configuration information. - | -|AES, System.Security.Cryptography.AesCryptoServiceProvider|| -|AesManaged, System.Security.Cryptography.AesManaged|| -|System.Security.Cryptography.AsymmetricAlgorithm|| -|DES, System.Security.Cryptography.DES|| -|DSA, System.Security.Cryptography.DSA|| -|ECDH, ECDiffieHellman, ECDiffieHellmanCng, System.Security.Cryptography.ECDiffieHellmanCng|| -|ECDsa, ECDsaCng, System.Security.Cryptography.ECDsaCng|| -|System.Security.Cryptography.HashAlgorithm|| -|HMAC, System.Security.Cryptography.HMAC|| -|HMACMD5, System.Security.Cryptography.HMACMD5|| -|HMACRIPEMD160, System.Security.Cryptography.HMACRIPEMD160|| -|HMACSHA1, System.Security.Cryptography.HMACSHA1|| -|HMACSHA256, System.Security.Cryptography.HMACSHA256|| -|HMACSHA384, System.Security.Cryptography.HMACSHA384|| -|HMACSHA512, System.Security.Cryptography.HMACSHA512|| -|System.Security.Cryptography.KeyedHashAlgorithm|| -|MACTripleDES, System.Security.Cryptography.MACTripleDES|| -|MD5, System.Security.Cryptography.MD5|| -|System.Security.Cryptography.MD5Cng|| -|RandomNumberGenerator|| -|RC2, System.Security.Cryptography.RC2|| -|Rijndael, System.Security.Cryptography.Rijndael|| -|RIPEMD160, RIPEMD-160, System.Security.Cryptography.RIPEMD160Managed|| -|RSA, System.Security.Cryptography.RSA|| -|SHA, SHA1, System.Security.Cryptography.SHA1|| -|System.Security.Cryptography.SHA1Cng|| -|SHA256, SHA-256, System.Security.Cryptography.SHA256|| -|System.Security.Cryptography.SHA256Cng|| -|System.Security.Cryptography.SHA256CryptoServiceProvider|| -|SHA384, SHA-384, System.Security.Cryptography.SHA384|| -|System.Security.Cryptography.SHA384Cng|| -|System.Security.Cryptography.SHA384CryptoServiceProvider|| -|SHA512, SHA-512, System.Security.Cryptography.SHA512|| -|System.Security.Cryptography.SHA512Cng|| -|System.Security.Cryptography.SHA512CryptoServiceProvider|| -|System.Security.Cryptography.SymmetricAlgorithm|| - - - -## Examples - The following code example demonstrates how to use members of the class. - + | +|AES, System.Security.Cryptography.AesCryptoServiceProvider|| +|AesManaged, System.Security.Cryptography.AesManaged|| +|System.Security.Cryptography.AsymmetricAlgorithm|| +|DES, System.Security.Cryptography.DES|| +|DSA, System.Security.Cryptography.DSA|| +|ECDH, ECDiffieHellman, ECDiffieHellmanCng, System.Security.Cryptography.ECDiffieHellmanCng|| +|ECDsa, ECDsaCng, System.Security.Cryptography.ECDsaCng|| +|System.Security.Cryptography.HashAlgorithm|| +|HMAC, System.Security.Cryptography.HMAC|| +|HMACMD5, System.Security.Cryptography.HMACMD5|| +|HMACRIPEMD160, System.Security.Cryptography.HMACRIPEMD160|| +|HMACSHA1, System.Security.Cryptography.HMACSHA1|| +|HMACSHA256, System.Security.Cryptography.HMACSHA256|| +|HMACSHA384, System.Security.Cryptography.HMACSHA384|| +|HMACSHA512, System.Security.Cryptography.HMACSHA512|| +|System.Security.Cryptography.KeyedHashAlgorithm|| +|MACTripleDES, System.Security.Cryptography.MACTripleDES|| +|MD5, System.Security.Cryptography.MD5|| +|System.Security.Cryptography.MD5Cng|| +|RandomNumberGenerator|| +|RC2, System.Security.Cryptography.RC2|| +|Rijndael, System.Security.Cryptography.Rijndael|| +|RIPEMD160, RIPEMD-160, System.Security.Cryptography.RIPEMD160Managed|| +|RSA, System.Security.Cryptography.RSA|| +|SHA, SHA1, System.Security.Cryptography.SHA1|| +|System.Security.Cryptography.SHA1Cng|| +|SHA256, SHA-256, System.Security.Cryptography.SHA256|| +|System.Security.Cryptography.SHA256Cng|| +|System.Security.Cryptography.SHA256CryptoServiceProvider|| +|SHA384, SHA-384, System.Security.Cryptography.SHA384|| +|System.Security.Cryptography.SHA384Cng|| +|System.Security.Cryptography.SHA384CryptoServiceProvider|| +|SHA512, SHA-512, System.Security.Cryptography.SHA512|| +|System.Security.Cryptography.SHA512Cng|| +|System.Security.Cryptography.SHA512CryptoServiceProvider|| +|System.Security.Cryptography.SymmetricAlgorithm|| + + + +## Examples + The following code example demonstrates how to use members of the class. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_System/system.Security.Cryptography.CryptoConfig/CPP/members.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography/CryptoConfig/Overview/members.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.CryptoConfig/VB/members.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.CryptoConfig/VB/members.vb" id="Snippet1"::: + ]]> Cryptographic Services @@ -227,19 +227,19 @@ An array of names to map to the algorithm. Adds a set of names to algorithm mappings to be used for the current application domain. - The or parameter is . - cannot be accessed from outside the assembly. - - -or- - + cannot be accessed from outside the assembly. + + -or- + One of the entries in the parameter is empty or . @@ -305,11 +305,11 @@ An array of names to map to the OID. Adds a set of names to object identifier (OID) mappings to be used for the current application domain. - The or parameter is . @@ -363,11 +363,11 @@ to enforce the policy; otherwise, . - @@ -445,20 +445,18 @@ Creates a new instance of the specified cryptographic object. A new instance of the specified cryptographic object. - . - - - -## Examples - The following code example demonstrates how to call the method to create a new SHA1 provider. This code example is part of a larger example provided for the class. - + . + +## Examples + The following code example demonstrates how to call the method to create a new SHA-1 provider. This code example is part of a larger example provided for the class. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_System/system.Security.Cryptography.CryptoConfig/CPP/members.cpp" id="Snippet4"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography/CryptoConfig/Overview/members.cs" id="Snippet4"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.CryptoConfig/VB/members.vb" id="Snippet4"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.CryptoConfig/VB/members.vb" id="Snippet4"::: + ]]> The parameter is . @@ -542,20 +540,20 @@ Creates a new instance of the specified cryptographic object with the specified arguments. A new instance of the specified cryptographic object. - . - - - -## Examples - The following code example demonstrates how to call the method to initialize a new RSA provider instance accessing the `TestContainer` key container. This code example is part of a larger example provided for the class. - + . + + + +## Examples + The following code example demonstrates how to call the method to initialize a new RSA provider instance accessing the `TestContainer` key container. This code example is part of a larger example provided for the class. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_System/system.Security.Cryptography.CryptoConfig/CPP/members.cpp" id="Snippet5"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography/CryptoConfig/Overview/members.cs" id="Snippet5"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.CryptoConfig/VB/members.vb" id="Snippet5"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.CryptoConfig/VB/members.vb" id="Snippet5"::: + ]]> The parameter is . @@ -623,15 +621,15 @@ Encodes the specified object identifier (OID). A byte array containing the encoded OID. - method to encode the specified object identifier. This code example is part of a larger example provided for the class. - + method to encode the specified object identifier. This code example is part of a larger example provided for the class. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_System/system.Security.Cryptography.CryptoConfig/CPP/members.cpp" id="Snippet6"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography/CryptoConfig/Overview/members.cs" id="Snippet6"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.CryptoConfig/VB/members.vb" id="Snippet6"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.CryptoConfig/VB/members.vb" id="Snippet6"::: + ]]> The parameter is . @@ -702,20 +700,18 @@ Gets the object identifier (OID) of the algorithm corresponding to the specified simple name. The OID of the specified algorithm. - . - - - -## Examples - The following code example demonstrates how to call the method to retrieve an object identifier (OID) from the string name of the SHA1 algorithm. This code example is part of a larger example provided for the class. - + . + +## Examples + The following code example demonstrates how to call the method to retrieve an object identifier (OID) from the string name of the SHA-1 algorithm. This code example is part of a larger example provided for the class. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_System/system.Security.Cryptography.CryptoConfig/CPP/members.cpp" id="Snippet3"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography/CryptoConfig/Overview/members.cs" id="Snippet3"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.CryptoConfig/VB/members.vb" id="Snippet3"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.Security.Cryptography.CryptoConfig/VB/members.vb" id="Snippet3"::: + ]]> The parameter is . diff --git a/xml/System.Security.Cryptography/DSACryptoServiceProvider.xml b/xml/System.Security.Cryptography/DSACryptoServiceProvider.xml index 5e3f6d8e41a..f3fe2e01573 100644 --- a/xml/System.Security.Cryptography/DSACryptoServiceProvider.xml +++ b/xml/System.Security.Cryptography/DSACryptoServiceProvider.xml @@ -1774,9 +1774,9 @@ This algorithm supports key lengths from 512 bits to 1024 bits in increments of ## Remarks This method verifies the digital signature produced by . - If the `str` parameter is `null`, the default hash algorithm (SHA1) is used. The valid hash algorithms is . + If the `str` parameter is `null`, the default hash algorithm (SHA-1) is used. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> diff --git a/xml/System.Security.Cryptography/ECDiffieHellmanCng.xml b/xml/System.Security.Cryptography/ECDiffieHellmanCng.xml index d05b609412c..6d889a8299d 100644 --- a/xml/System.Security.Cryptography/ECDiffieHellmanCng.xml +++ b/xml/System.Security.Cryptography/ECDiffieHellmanCng.xml @@ -1188,7 +1188,7 @@ This instance represents only a public key.
Other custom hash algorithms may also be used. - Due to collision problems with MD5 and SHA1, Microsoft recommends . The default algorithm is . + Due to collision problems with MD5 and SHA-1, Microsoft recommends . The default algorithm is . ]]> diff --git a/xml/System.Security.Cryptography/ECDsaCng.xml b/xml/System.Security.Cryptography/ECDsaCng.xml index bafab47bc67..55e49df7cd4 100644 --- a/xml/System.Security.Cryptography/ECDsaCng.xml +++ b/xml/System.Security.Cryptography/ECDsaCng.xml @@ -755,7 +755,7 @@ If a key is loaded via the . The default algorithm is . + Due to collision problems with MD5 and SHA-1, Microsoft recommends . The default algorithm is . This property is not used if you are signing or verifying data that is already hashed. diff --git a/xml/System.Security.Cryptography/HMACMD5.xml b/xml/System.Security.Cryptography/HMACMD5.xml index 95727d6bff0..fe7b9cef7ee 100644 --- a/xml/System.Security.Cryptography/HMACMD5.xml +++ b/xml/System.Security.Cryptography/HMACMD5.xml @@ -67,20 +67,20 @@ Computes a Hash-based Message Authentication Code (HMAC) by using the hash function. - is a type of keyed hash algorithm that is constructed from the Message Digest Algorithm 5 (MD5) hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 128 bits in length. - - An HMAC can be used to determine whether a message sent over an insecure channel has been tampered with, provided that the sender and receiver share a secret key. The sender computes the hash value for the original data and sends both the original data and hash value as a single message. The receiver recalculates the hash value on the received message and checks that the computed HMAC matches the transmitted HMAC. - - Any change to the data or the hash value results in a mismatch, because knowledge of the secret key is required to change the message and reproduce the correct hash value. Therefore, if the original and computed hash values match, the message is authenticated. - - MD5 is a cryptographic hash algorithm developed at RSA Laboratories. accepts keys of any size, and produces a hash sequence that is 128 bits in length. - - Due to collision problems with MD5, Microsoft recommends SHA256. - - + is a type of keyed hash algorithm that is constructed from the Message Digest Algorithm 5 (MD5) hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 128 bits in length. + + An HMAC can be used to determine whether a message sent over an insecure channel has been tampered with, provided that the sender and receiver share a secret key. The sender computes the hash value for the original data and sends both the original data and hash value as a single message. The receiver recalculates the hash value on the received message and checks that the computed HMAC matches the transmitted HMAC. + + Any change to the data or the hash value results in a mismatch, because knowledge of the secret key is required to change the message and reproduce the correct hash value. Therefore, if the original and computed hash values match, the message is authenticated. + + MD5 is a cryptographic hash algorithm developed at RSA Laboratories. accepts keys of any size, and produces a hash sequence that is 128 bits in length. + + Due to collision problems with MD5, Microsoft recommends SHA-256. + + ]]> Cryptographic Services @@ -144,15 +144,15 @@ Initializes a new instance of the class by using a randomly generated key. - is a type of keyed hash algorithm that is constructed from the MD5 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 128 bits in length. - - This constructor uses a 64-byte, randomly generated key. + is a type of keyed hash algorithm that is constructed from the MD5 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 128 bits in length. + + This constructor uses a 64-byte, randomly generated key. + + Due to collision problems with MD5, Microsoft recommends SHA-256. - Due to collision problems with MD5, Microsoft recommends SHA256. - ]]> Cryptographic Services @@ -208,18 +208,18 @@ The secret key for HMAC computation. The key can be any length, but if it is more than 64 bytes long it will be hashed (using MD5) to derive a 16-byte key. Therefore, the recommended size of the secret key is 64 bytes. Initializes a new instance of the class by using the specified key. - is a type of keyed hash algorithm that is constructed from the MD5 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 128 bits in length. - - This constructor uses a key you provide to create the object. - - Due to collision problems with MD5, Microsoft recommends SHA256. - -## Examples - For an example of how to use this constructor, see the class. - + is a type of keyed hash algorithm that is constructed from the MD5 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 128 bits in length. + + This constructor uses a key you provide to create the object. + + Due to collision problems with MD5, Microsoft recommends SHA-256. + +## Examples + For an example of how to use this constructor, see the class. + ]]> The parameter is . diff --git a/xml/System.Security.Cryptography/HMACRIPEMD160.xml b/xml/System.Security.Cryptography/HMACRIPEMD160.xml index 5d3704a36cc..4fa72c1ed10 100644 --- a/xml/System.Security.Cryptography/HMACRIPEMD160.xml +++ b/xml/System.Security.Cryptography/HMACRIPEMD160.xml @@ -24,28 +24,28 @@ Computes a Hash-based Message Authentication Code (HMAC) by using the hash function. - is a type of keyed hash algorithm that is constructed from the RIPEMD-160 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 160 bits in length. - - An HMAC can be used to determine whether a message sent over an insecure channel has been tampered with, provided that the sender and receiver share a secret key. The sender computes the hash value for the original data and sends both the original data and the hash value as a single message. The receiver recalculates the hash value on the received message and checks that the computed HMAC matches the transmitted HMAC. - - Any change to the data or the hash value results in a mismatch, because knowledge of the secret key is required to change the message and reproduce the correct hash value. Therefore, if the original and computed hash values match, the message is authenticated. - - accepts keys of any size, and produces a hash sequence that is 160 bits long. - - The RIPEMD hash algorithm and its successors were developed by the European RIPE project. The original RIPEMD algorithm was designed to replace MD4 and MD5 and was later strengthened and renamed RIPEMD-160. The RIPEMD-160 hash algorithm produces a 160-bit hash value. The algorithm's designers have placed it in the public domain. - - Due to collision problems with MD4 and MD5, Microsoft recommends SHA256 or better. - -## Examples - The following example shows how to sign a file by using the object and then how to verify the file. - + is a type of keyed hash algorithm that is constructed from the RIPEMD-160 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 160 bits in length. + + An HMAC can be used to determine whether a message sent over an insecure channel has been tampered with, provided that the sender and receiver share a secret key. The sender computes the hash value for the original data and sends both the original data and the hash value as a single message. The receiver recalculates the hash value on the received message and checks that the computed HMAC matches the transmitted HMAC. + + Any change to the data or the hash value results in a mismatch, because knowledge of the secret key is required to change the message and reproduce the correct hash value. Therefore, if the original and computed hash values match, the message is authenticated. + + accepts keys of any size, and produces a hash sequence that is 160 bits long. + + The RIPEMD hash algorithm and its successors were developed by the European RIPE project. The original RIPEMD algorithm was designed to replace MD4 and MD5 and was later strengthened and renamed RIPEMD-160. The RIPEMD-160 hash algorithm produces a 160-bit hash value. The algorithm's designers have placed it in the public domain. + + Due to collision problems with MD4 and MD5, Microsoft recommends SHA-256 or better. + +## Examples + The following example shows how to sign a file by using the object and then how to verify the file. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/HMACRIPEMD160/CPP/hmacripemd160.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography/HMACRIPEMD160/Overview/hmacripemd160.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/HMACRIPEMD160/vb/hmacripemd160.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/HMACRIPEMD160/vb/hmacripemd160.vb" id="Snippet1"::: + ]]> Cryptographic Services @@ -77,13 +77,13 @@ Initializes a new instance of the class with a randomly generated 64-byte key. - is a type of keyed hash algorithm that is constructed from the RIPEMD-160 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 160 bytes in length. - - This constructor uses a 64-byte, randomly generated key. - + is a type of keyed hash algorithm that is constructed from the RIPEMD-160 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 160 bytes in length. + + This constructor uses a 64-byte, randomly generated key. + ]]> Cryptographic Services @@ -109,16 +109,16 @@ The secret key for encryption. The key can be any length, but if it is more than 64 bytes long it is hashed (using SHA-1) to derive a 64-byte key. Therefore, the recommended size of the secret key is 64 bytes. Initializes a new instance of the class with the specified key data. - is a type of keyed hash algorithm that is constructed from the RIPEMD-160 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 160 bytes in length. - - - -## Examples - For an example of how to use this constructor, see the class. - + is a type of keyed hash algorithm that is constructed from the RIPEMD-160 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 160 bytes in length. + + + +## Examples + For an example of how to use this constructor, see the class. + ]]> The parameter is . diff --git a/xml/System.Security.Cryptography/HMACSHA1.xml b/xml/System.Security.Cryptography/HMACSHA1.xml index 36b12f9fab7..591481f54a6 100644 --- a/xml/System.Security.Cryptography/HMACSHA1.xml +++ b/xml/System.Security.Cryptography/HMACSHA1.xml @@ -74,21 +74,21 @@ Computes a Hash-based Message Authentication Code (HMAC) using the hash function. - is a type of keyed hash algorithm that is constructed from the SHA1 hash function and used as an HMAC, or hash-based message authentication code. The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 160 bits in length. - - An HMAC can be used to determine whether a message sent over an insecure channel has been tampered with, provided that the sender and receiver share a secret key. The sender computes the hash value for the original data and sends both the original data and hash value as a single message. The receiver recalculates the hash value on the received message and checks that the computed HMAC matches the transmitted HMAC. - - Any change to the data or the hash value results in a mismatch, because knowledge of the secret key is required to change the message and reproduce the correct hash value. Therefore, if the original and computed hash values match, the message is authenticated. - - The SHA-1 (Secure Hash Algorithm, also called SHS, Secure Hash Standard) is a cryptographic hash algorithm published by the United States Government. It produces a 160-bit hash value from an arbitrary length string. - - accepts keys of any size, and produces a hash sequence that is 160 bits in length. - - Due to collision problems with SHA1, Microsoft recommends SHA256. - + is a type of keyed hash algorithm that is constructed from the SHA-1 hash function and used as an HMAC, or hash-based message authentication code. The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 160 bits in length. + + An HMAC can be used to determine whether a message sent over an insecure channel has been tampered with, provided that the sender and receiver share a secret key. The sender computes the hash value for the original data and sends both the original data and hash value as a single message. The receiver recalculates the hash value on the received message and checks that the computed HMAC matches the transmitted HMAC. + + Any change to the data or the hash value results in a mismatch, because knowledge of the secret key is required to change the message and reproduce the correct hash value. Therefore, if the original and computed hash values match, the message is authenticated. + + The SHA-1 (Secure Hash Algorithm, also called SHS, Secure Hash Standard) is a cryptographic hash algorithm published by the United States Government. It produces a 160-bit hash value from an arbitrary length string. + + accepts keys of any size, and produces a hash sequence that is 160 bits in length. + + Due to collision problems with SHA-1, Microsoft recommends SHA-256. + ]]> Cryptographic Services @@ -147,15 +147,15 @@ Initializes a new instance of the class with a randomly generated key. - is a type of keyed hash algorithm that is constructed from the SHA1 hash function and used as an HMAC, or hash-based message authentication code. The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 160 bits (20 bytes) in length. - - This constructor uses a 64-byte, randomly generated key. + is a type of keyed hash algorithm that is constructed from the SHA-1 hash function and used as an HMAC, or hash-based message authentication code. The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 160 bits (20 bytes) in length. + + This constructor uses a 64-byte, randomly generated key. + + Due to collision problems with SHA-1, Microsoft recommends SHA-256. - Due to collision problems with SHA1, Microsoft recommends SHA256. - ]]> Cryptographic Services @@ -212,9 +212,9 @@ The secret key for HMAC computation. The key can be any length, but if it is more than 64 bytes long, it is hashed (using SHA-1) to derive a 20-byte key. Therefore, the recommended size of the secret key is 64 bytes. - to use the managed implementation of the SHA1 algorithm (the class); to use the unmanaged implementation (the class). - Initializes a new instance of the class with the specified key data and a value that specifies whether to use the managed version of the SHA1 algorithm. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + to use the managed implementation of the SHA-1 algorithm (the class); to use the unmanaged implementation (the class). + Initializes a new instance of the class with the specified key data and a value that specifies whether to use the managed version of the SHA-1 algorithm. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. @@ -269,19 +269,19 @@ The secret key for encryption. The key can be any length, but if it is more than 64 bytes long it is hashed (using SHA-1) to derive a 64-byte key. Therefore, the recommended size of the secret key is 64 bytes. Initializes a new instance of the class with the specified key data. - is a type of keyed hash algorithm that is constructed from the SHA1 hash function and used as an HMAC, or hash-based message authentication code. The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 160 bits (20 bytes) in length. - + is a type of keyed hash algorithm that is constructed from the SHA-1 hash function and used as an HMAC, or hash-based message authentication code. The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 160 bits (20 bytes) in length. + > [!NOTE] -> This constructor creates an unmanaged instance of the algorithm by using the class. - -Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. - -## Examples - For an example of how to use this constructor, see the class. - +> This constructor creates an unmanaged instance of the algorithm by using the class. + +Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. + +## Examples + For an example of how to use this constructor, see the class. + ]]> The parameter is . @@ -452,7 +452,7 @@ Releases the unmanaged resources used by the The offset into the byte array from which to begin using data. The number of bytes in the array to use as data. Routes data written to the object into the SHA1 hash algorithm for computing the Hash-based Message Authentication Code (HMAC). - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. @@ -487,7 +487,7 @@ Releases the unmanaged resources used by the The HMAC key. The data to HMAC. - Computes the HMAC of data using the SHA1 algorithm. + Computes the HMAC of data using the SHA-1 algorithm. The HMAC of the data. To be added. @@ -525,7 +525,7 @@ Releases the unmanaged resources used by the The HMAC key. The stream to HMAC. - Computes the HMAC of a stream using the SHA1 algorithm. + Computes the HMAC of a stream using the SHA-1 algorithm. The HMAC of the data. To be added. @@ -572,7 +572,7 @@ Releases the unmanaged resources used by the The HMAC key. The stream to HMAC. - Computes the HMAC of a stream using the SHA1 algorithm. + Computes the HMAC of a stream using the SHA-1 algorithm. The HMAC of the data. To be added. @@ -619,7 +619,7 @@ Releases the unmanaged resources used by the The HMAC key. The data to HMAC. - Computes the HMAC of data using the SHA1 algorithm. + Computes the HMAC of data using the SHA-1 algorithm. The HMAC of the data. To be added. @@ -664,7 +664,7 @@ Releases the unmanaged resources used by the The HMAC key. The stream to HMAC. The buffer to receive the HMAC value. - Computes the HMAC of a stream using the SHA1 algorithm. + Computes the HMAC of a stream using the SHA-1 algorithm. The total number of bytes written to . To be added. @@ -672,7 +672,7 @@ Releases the unmanaged resources used by the The buffer in is too small to hold the calculated HMAC - size. The SHA1 algorithm always produces a 160-bit HMAC, or 20 bytes. + size. The SHA-1 algorithm always produces a 160-bit HMAC, or 20 bytes. -or- @@ -715,10 +715,10 @@ Releases the unmanaged resources used by the The HMAC key. The data to HMAC. The buffer to receive the HMAC value. - Computes the HMAC of data using the SHA1 algorithm. + Computes the HMAC of data using the SHA-1 algorithm. The total number of bytes written to . To be added. - The buffer in is too small to hold the calculated hash size. The SHA1 algorithm always produces a 160-bit HMAC, or 20 bytes. + The buffer in is too small to hold the calculated hash size. The SHA-1 algorithm always produces a 160-bit HMAC, or 20 bytes. @@ -760,7 +760,7 @@ Releases the unmanaged resources used by the The stream to HMAC. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA1 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-1 algorithm. The HMAC of the data. This method stores in the task it returns all non-usage exceptions that the method's synchronous counterpart can throw. If an exception is stored into the returned task, that exception will be thrown when the task is awaited. Usage exceptions, such as , are still thrown synchronously. For the stored exceptions, see the exceptions thrown by . @@ -816,7 +816,7 @@ Releases the unmanaged resources used by the The stream to HMAC. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA1 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-1 algorithm. The HMAC of the data. To be added. @@ -868,7 +868,7 @@ Releases the unmanaged resources used by the The buffer to receive the HMAC value. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA1 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-1 algorithm. The total number of bytes written to . To be added. @@ -876,7 +876,7 @@ Releases the unmanaged resources used by the The buffer in is too small to hold the calculated hash - size. The SHA1 algorithm always produces a 160-bit hash, or 20 bytes. + size. The SHA-1 algorithm always produces a 160-bit hash, or 20 bytes. -or- @@ -1018,7 +1018,7 @@ Releases the unmanaged resources used by the 20 - The hash size produced by the HMAC SHA1 algorithm, in bytes. + The hash size produced by the HMAC SHA-1 algorithm, in bytes. To be added. @@ -1174,7 +1174,7 @@ Releases the unmanaged resources used by the The data to HMAC. The buffer to receive the HMAC value. When this method returns, contains the total number of bytes written into . - Attempts to compute the HMAC of data using the SHA1 algorithm. + Attempts to compute the HMAC of data using the SHA-1 algorithm. if is too small to hold the calculated hash, otherwise. To be added. diff --git a/xml/System.Security.Cryptography/HMACSHA256.xml b/xml/System.Security.Cryptography/HMACSHA256.xml index 42d3b55a324..5e5d4acb8b9 100644 --- a/xml/System.Security.Cryptography/HMACSHA256.xml +++ b/xml/System.Security.Cryptography/HMACSHA256.xml @@ -67,26 +67,26 @@ Computes a Hash-based Message Authentication Code (HMAC) by using the hash function. - is a type of keyed hash algorithm that is constructed from the SHA-256 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 256 bits in length. - - An HMAC can be used to determine whether a message sent over an insecure channel has been tampered with, provided that the sender and receiver share a secret key. The sender computes the hash value for the original data and sends both the original data and hash value as a single message. The receiver recalculates the hash value on the received message and checks that the computed HMAC matches the transmitted HMAC. - - Any change to the data or the hash value results in a mismatch, because knowledge of the secret key is required to change the message and reproduce the correct hash value. Therefore, if the original and computed hash values match, the message is authenticated. - - accepts keys of any size, and produces a hash sequence 256 bits in length. - - - -## Examples - The following example shows how to sign a file by using the object and then how to verify the file. - + is a type of keyed hash algorithm that is constructed from the SHA-256 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 256 bits in length. + + An HMAC can be used to determine whether a message sent over an insecure channel has been tampered with, provided that the sender and receiver share a secret key. The sender computes the hash value for the original data and sends both the original data and hash value as a single message. The receiver recalculates the hash value on the received message and checks that the computed HMAC matches the transmitted HMAC. + + Any change to the data or the hash value results in a mismatch, because knowledge of the secret key is required to change the message and reproduce the correct hash value. Therefore, if the original and computed hash values match, the message is authenticated. + + accepts keys of any size, and produces a hash sequence 256 bits in length. + + + +## Examples + The following example shows how to sign a file by using the object and then how to verify the file. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/HMACSHA256/CPP/hmacsha256.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography/HMACSHA256/Overview/hmacsha256.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/HMACSHA256/vb/hmacsha256.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/HMACSHA256/vb/hmacsha256.vb" id="Snippet1"::: + ]]> Cryptographic Services @@ -144,13 +144,13 @@ Initializes a new instance of the class with a randomly generated key. - is a type of keyed hash algorithm that is constructed from the SHA-256 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 256 bits in length. - - This constructor uses a 64-byte, randomly generated key. - + is a type of keyed hash algorithm that is constructed from the SHA-256 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 256 bits in length. + + This constructor uses a 64-byte, randomly generated key. + ]]> Cryptographic Services @@ -200,16 +200,16 @@ The secret key for HMAC computation. The key can be any length. However, the recommended size is 64 bytes. If the key is more than 64 bytes long, it is hashed (using SHA-256) to derive a 32-byte key. Initializes a new instance of the class with the specified key data. - is a type of keyed hash algorithm that is constructed from the SHA-256 hash function and used as a Hash-based Message Authentication Code. The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 256 bits in length. - - - -## Examples - For an example of how to use this constructor, see the class. - + is a type of keyed hash algorithm that is constructed from the SHA-256 hash function and used as a Hash-based Message Authentication Code. The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 256 bits in length. + + + +## Examples + For an example of how to use this constructor, see the class. + ]]> The parameter is . @@ -375,7 +375,7 @@ The HMAC key. The data to HMAC. - Computes the HMAC of data using the SHA256 algorithm. + Computes the HMAC of data using the SHA-256 algorithm. The HMAC of the data. To be added. @@ -413,7 +413,7 @@ The HMAC key. The stream to HMAC. - Computes the HMAC of a stream using the SHA256 algorithm. + Computes the HMAC of a stream using the SHA-256 algorithm. The HMAC of the data. To be added. @@ -460,7 +460,7 @@ The HMAC key. The stream to HMAC. - Computes the HMAC of a stream using the SHA256 algorithm. + Computes the HMAC of a stream using the SHA-256 algorithm. The HMAC of the data. To be added. @@ -507,7 +507,7 @@ The HMAC key. The data to HMAC. - Computes the HMAC of data using the SHA256 algorithm. + Computes the HMAC of data using the SHA-256 algorithm. The HMAC of the data. To be added. @@ -552,7 +552,7 @@ The HMAC key. The stream to HMAC. The buffer to receive the HMAC value. - Computes the HMAC of a stream using the SHA256 algorithm. + Computes the HMAC of a stream using the SHA-256 algorithm. The total number of bytes written to . To be added. @@ -560,7 +560,7 @@ The buffer in is too small to hold the calculated HMAC - size. The SHA256 algorithm always produces a 256-bit HMAC, or 32 bytes. + size. The SHA-256 algorithm always produces a 256-bit HMAC, or 32 bytes. -or- @@ -603,10 +603,10 @@ The HMAC key. The data to HMAC. The buffer to receive the HMAC value. - Computes the HMAC of data using the SHA256 algorithm. + Computes the HMAC of data using the SHA-256 algorithm. The total number of bytes written to . To be added. - The buffer in is too small to hold the calculated hash size. The SHA256 algorithm always produces a 256-bit HMAC, or 32 bytes. + The buffer in is too small to hold the calculated hash size. The SHA-256 algorithm always produces a 256-bit HMAC, or 32 bytes. @@ -648,7 +648,7 @@ The stream to HMAC. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA256 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-256 algorithm. The HMAC of the data. This method stores in the task it returns all non-usage exceptions that the method's synchronous counterpart can throw. If an exception is stored into the returned task, that exception will be thrown when the task is awaited. Usage exceptions, such as , are still thrown synchronously. For the stored exceptions, see the exceptions thrown by . @@ -704,7 +704,7 @@ The stream to HMAC. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA256 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-256 algorithm. The HMAC of the data. To be added. @@ -756,7 +756,7 @@ The buffer to receive the HMAC value. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA256 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-256 algorithm. The total number of bytes written to . To be added. @@ -764,7 +764,7 @@ The buffer in is too small to hold the calculated hash - size. The SHA256 algorithm always produces a 256-bit hash, or 32 bytes. + size. The SHA-256 algorithm always produces a 256-bit hash, or 32 bytes. -or- @@ -872,7 +872,7 @@ 256 - The hash size produced by the HMAC SHA256 algorithm, in bits. + The hash size produced by the HMAC SHA-256 algorithm, in bits. To be added. @@ -902,7 +902,7 @@ 32 - The hash size produced by the HMAC SHA256 algorithm, in bytes. + The hash size produced by the HMAC SHA-256 algorithm, in bytes. To be added. @@ -1020,7 +1020,7 @@ The data to HMAC. The buffer to receive the HMAC value. When this method returns, the total number of bytes written into . - Attempts to compute the HMAC of data using the SHA256 algorithm. + Attempts to compute the HMAC of data using the SHA-256 algorithm. if is too small to hold the calculated hash, otherwise. To be added. diff --git a/xml/System.Security.Cryptography/HMACSHA384.xml b/xml/System.Security.Cryptography/HMACSHA384.xml index 116e9c906f6..23f85773e1c 100644 --- a/xml/System.Security.Cryptography/HMACSHA384.xml +++ b/xml/System.Security.Cryptography/HMACSHA384.xml @@ -67,26 +67,26 @@ Computes a Hash-based Message Authentication Code (HMAC) using the hash function. - is a type of keyed hash algorithm that is constructed from the SHA-384 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data and hashes the result. The hash value is mixed with the secret key again, and then hashed a second time. The output hash is 384 bits long. - - An HMAC can be used to determine whether a message sent over a nonsecure channel has been tampered with, provided that the sender and receiver share a secret key. The sender computes the hash value for the original data and sends both the original data and the hash value as a single message. The receiver recalculates the hash value on the received message and checks that the computed HMAC matches the transmitted HMAC. - - If the original and computed hash values match, the message is authenticated. If they do not match, either the data or the hash value has been changed. HMACs provide security against tampering because knowledge of the secret key is required to change the message and reproduce the correct hash value. - - accepts all key sizes and produces a hash sequence that is 384 bits long. - - - -## Examples - The following example shows how to sign a file by using the object, and then how to verify the file. - + is a type of keyed hash algorithm that is constructed from the SHA-384 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data and hashes the result. The hash value is mixed with the secret key again, and then hashed a second time. The output hash is 384 bits long. + + An HMAC can be used to determine whether a message sent over a nonsecure channel has been tampered with, provided that the sender and receiver share a secret key. The sender computes the hash value for the original data and sends both the original data and the hash value as a single message. The receiver recalculates the hash value on the received message and checks that the computed HMAC matches the transmitted HMAC. + + If the original and computed hash values match, the message is authenticated. If they do not match, either the data or the hash value has been changed. HMACs provide security against tampering because knowledge of the secret key is required to change the message and reproduce the correct hash value. + + accepts all key sizes and produces a hash sequence that is 384 bits long. + + + +## Examples + The following example shows how to sign a file by using the object, and then how to verify the file. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/HMACSHA384/CPP/hmacsha384.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography/HMACSHA384/Overview/hmacsha384.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/HMACSHA384/vb/hmacsha384.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/HMACSHA384/vb/hmacsha384.vb" id="Snippet1"::: + ]]> Cryptographic Services @@ -144,11 +144,11 @@ Initializes a new instance of the class by using a randomly generated key. - Cryptographic Services @@ -204,11 +204,11 @@ The secret key for HMAC computation. The key can be any length. However, the recommended size is 128 bytes. If the key is more than 128 bytes long, it is hashed (using SHA-384) to derive a 48-byte key. Initializes a new instance of the class by using the specified key data. - class. - + class. + ]]> The parameter is . @@ -374,7 +374,7 @@ The HMAC key. The data to HMAC. - Computes the HMAC of data using the SHA384 algorithm. + Computes the HMAC of data using the SHA-384 algorithm. The HMAC of the data. To be added. @@ -412,7 +412,7 @@ The HMAC key. The stream to HMAC. - Computes the HMAC of a stream using the SHA384 algorithm. + Computes the HMAC of a stream using the SHA-384 algorithm. The HMAC of the data. To be added. @@ -459,7 +459,7 @@ The HMAC key. The stream to HMAC. - Computes the HMAC of a stream using the SHA384 algorithm. + Computes the HMAC of a stream using the SHA-384 algorithm. The HMAC of the data. To be added. @@ -506,7 +506,7 @@ The HMAC key. The data to HMAC. - Computes the HMAC of data using the SHA384 algorithm. + Computes the HMAC of data using the SHA-384 algorithm. The HMAC of the data. To be added. @@ -551,7 +551,7 @@ The HMAC key. The stream to HMAC. The buffer to receive the HMAC value. - Computes the HMAC of a stream using the SHA384 algorithm. + Computes the HMAC of a stream using the SHA-384 algorithm. The total number of bytes written to . To be added. @@ -559,7 +559,7 @@ The buffer in is too small to hold the calculated HMAC - size. The SHA384 algorithm always produces a 384-bit HMAC, or 48 bytes. + size. The SHA-384 algorithm always produces a 384-bit HMAC, or 48 bytes. -or- @@ -602,10 +602,10 @@ The HMAC key. The data to HMAC. The buffer to receive the HMAC value. - Computes the HMAC of data using the SHA384 algorithm. + Computes the HMAC of data using the SHA-384 algorithm. The total number of bytes written to . To be added. - The buffer in is too small to hold the calculated hash size. The SHA384 algorithm always produces a 384-bit HMAC, or 48 bytes. + The buffer in is too small to hold the calculated hash size. The SHA-384 algorithm always produces a 384-bit HMAC, or 48 bytes. @@ -647,7 +647,7 @@ The stream to HMAC. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA384 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-384 algorithm. The HMAC of the data. This method stores in the task it returns all non-usage exceptions that the method's synchronous counterpart can throw. If an exception is stored into the returned task, that exception will be thrown when the task is awaited. Usage exceptions, such as , are still thrown synchronously. For the stored exceptions, see the exceptions thrown by . @@ -703,7 +703,7 @@ The stream to HMAC. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA384 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-384 algorithm. The HMAC of the data. To be added. @@ -755,7 +755,7 @@ The buffer to receive the HMAC value. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA384 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-384 algorithm. The total number of bytes written to . To be added. @@ -763,7 +763,7 @@ The buffer in is too small to hold the calculated hash - size. The SHA384 algorithm always produces a 384-bit hash, or 48 bytes. + size. The SHA-384 algorithm always produces a 384-bit hash, or 48 bytes. -or- @@ -871,7 +871,7 @@ 384 - The hash size produced by the HMAC SHA384 algorithm, in bits. + The hash size produced by the HMAC SHA-384 algorithm, in bits. To be added. @@ -901,7 +901,7 @@ 48 - The hash size produced by the HMAC SHA384 algorithm, in bytes. + The hash size produced by the HMAC SHA-384 algorithm, in bytes. To be added. @@ -1031,23 +1031,23 @@ to enable .NET Framework 2.0 Service Pack 1 applications to interact with .NET Framework 2.0 applications; otherwise, . - Boolean property is to enable .NET Framework 2.0 Service Pack 1 applications to interact with .NET Framework 2.0 applications. When you set this property to `true`, the object produces values that match the values produced by the .NET Framework 2.0. You should set this property only once after you create your HMAC object. You will need to reset your key afterwards, as shown in the following example. - + Boolean property is to enable .NET Framework 2.0 Service Pack 1 applications to interact with .NET Framework 2.0 applications. When you set this property to `true`, the object produces values that match the values produced by the .NET Framework 2.0. You should set this property only once after you create your HMAC object. You will need to reset your key afterwards, as shown in the following example. + ```csharp public static void Test() { - var hmac = new HMACSHA384(); - hmac.ProduceLegacyHmacValues = true; - hmac.Key = // ...Get the HMAC key. - // ... - // Use the HMAC algorithm. + var hmac = new HMACSHA384(); + hmac.ProduceLegacyHmacValues = true; + hmac.Key = // ...Get the HMAC key. // ... -} -``` - + // Use the HMAC algorithm. + // ... +} +``` + ]]> Cryptographic Services @@ -1089,7 +1089,7 @@ public static void Test() The data to HMAC. The buffer to receive the HMAC value. When this method returns, the total number of bytes written into . - Attempts to compute the HMAC of data using the SHA384 algorithm. + Attempts to compute the HMAC of data using the SHA-384 algorithm. if is too small to hold the calculated hash, otherwise. To be added. diff --git a/xml/System.Security.Cryptography/HMACSHA3_256.xml b/xml/System.Security.Cryptography/HMACSHA3_256.xml index 6cf4c363f5d..f0a4b4ad5c9 100644 --- a/xml/System.Security.Cryptography/HMACSHA3_256.xml +++ b/xml/System.Security.Cryptography/HMACSHA3_256.xml @@ -22,7 +22,7 @@ - Computes a Hash-based Message Authentication Code (HMAC) by using the SHA3-256 hash function. + Computes a Hash-based Message Authentication Code (HMAC) by using the SHA-3-256 hash function. To be added. @@ -44,9 +44,9 @@ Initializes a new instance of the class with a randomly generated key. - is a type of keyed hash algorithm that is constructed from the SHA3-256 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 256 bits in length. + is a type of keyed hash algorithm that is constructed from the SHA-3-256 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 256 bits in length. - This constructor uses a 136-byte, randomly generated key. + This constructor uses a 136-byte, randomly generated key. @@ -186,7 +186,7 @@ The HMAC key. The data to HMAC. - Computes the HMAC of data using the SHA3-256 algorithm. + Computes the HMAC of data using the SHA-3-256 algorithm. The HMAC of the data. To be added. @@ -217,7 +217,7 @@ The HMAC key. The stream to HMAC. - Computes the HMAC of a stream using the SHA3-256 algorithm. + Computes the HMAC of a stream using the SHA-3-256 algorithm. The HMAC of the data. To be added. @@ -257,7 +257,7 @@ The HMAC key. The stream to HMAC. - Computes the HMAC of a stream using the SHA3-256 algorithm. + Computes the HMAC of a stream using the SHA-3-256 algorithm. The HMAC of the data. To be added. @@ -296,7 +296,7 @@ The HMAC key. The data to HMAC. - Computes the HMAC of data using the SHA3-256 algorithm. + Computes the HMAC of data using the SHA-3-256 algorithm. The HMAC of the data. To be added. @@ -334,19 +334,19 @@ The HMAC key. The stream to HMAC. The buffer to receive the HMAC value. - Computes the HMAC of a stream using the SHA3-256 algorithm. + Computes the HMAC of a stream using the SHA-3-256 algorithm. The total number of bytes written to . To be added. is . - - - The buffer in is too small to hold the calculated HMAC - size. The SHA3-256 algorithm always produces a 256-bit HMAC, or 32 bytes. - --or- - - does not support reading. + + + The buffer in is too small to hold the calculated HMAC + size. The SHA-3-256 algorithm always produces a 256-bit HMAC, or 32 bytes. + +-or- + + does not support reading. @@ -376,11 +376,11 @@ The HMAC key. The data to HMAC. The buffer to receive the HMAC value. - Computes the HMAC of data using the SHA3-256 algorithm. + Computes the HMAC of data using the SHA-3-256 algorithm. The total number of bytes written to . To be added. - The buffer in is too small to hold the calculated hash - size. The SHA3-256 algorithm always produces a 256-bit HMAC, or 32 bytes. + The buffer in is too small to hold the calculated hash + size. The SHA-3-256 algorithm always produces a 256-bit HMAC, or 32 bytes. @@ -413,9 +413,9 @@ The HMAC key. The stream to HMAC. - The token to monitor for cancellation requests. + The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA3-256 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-3-256 algorithm. The HMAC of the data. To be added. @@ -462,9 +462,9 @@ The HMAC key. The stream to HMAC. - The token to monitor for cancellation requests. + The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA3-256 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-3-256 algorithm. The HMAC of the data. To be added. @@ -507,21 +507,21 @@ The HMAC key. The stream to HMAC. The buffer to receive the HMAC value. - The token to monitor for cancellation requests. + The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA3-256 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-3-256 algorithm. The total number of bytes written to . To be added. is . - - - The buffer in is too small to hold the calculated hash - size. The SHA3-256 algorithm always produces a 256-bit hash, or 32 bytes. - --or- - - does not support reading. + + + The buffer in is too small to hold the calculated hash + size. The SHA-3-256 algorithm always produces a 256-bit hash, or 32 bytes. + +-or- + + does not support reading. The cancellation token was canceled. This exception is stored into the returned task. @@ -570,7 +570,7 @@ 256 - The hash size produced by the HMAC SHA3-256 algorithm, in bits. + The hash size produced by the HMAC SHA-3-256 algorithm, in bits. To be added. @@ -593,7 +593,7 @@ 32 - The hash size produced by the HMAC SHA3-256 algorithm, in bytes. + The hash size produced by the HMAC SHA-3-256 algorithm, in bytes. To be added. @@ -697,7 +697,7 @@ The data to HMAC. The buffer to receive the HMAC value. When this method returns, the total number of bytes written into . - Attempts to compute the HMAC of data using the SHA3-256 algorithm. + Attempts to compute the HMAC of data using the SHA-3-256 algorithm. if is too small to hold the calculated hash, otherwise. To be added. diff --git a/xml/System.Security.Cryptography/HMACSHA3_384.xml b/xml/System.Security.Cryptography/HMACSHA3_384.xml index d6b48d0072c..a9e3ada87c8 100644 --- a/xml/System.Security.Cryptography/HMACSHA3_384.xml +++ b/xml/System.Security.Cryptography/HMACSHA3_384.xml @@ -22,7 +22,7 @@ - Computes a Hash-based Message Authentication Code (HMAC) by using the SHA3-384 hash function. + Computes a Hash-based Message Authentication Code (HMAC) by using the SHA-3-384 hash function. To be added. @@ -44,9 +44,9 @@ Initializes a new instance of the class with a randomly generated key. - is a type of keyed hash algorithm that is constructed from the SHA3-384 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 384 bits in length. + is a type of keyed hash algorithm that is constructed from the SHA-3-384 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 384 bits in length. - This constructor uses a 104-byte, randomly generated key. + This constructor uses a 104-byte, randomly generated key. @@ -186,7 +186,7 @@ The HMAC key. The data to HMAC. - Computes the HMAC of data using the SHA3-384 algorithm. + Computes the HMAC of data using the SHA-3-384 algorithm. The HMAC of the data. To be added. @@ -217,7 +217,7 @@ The HMAC key. The stream to HMAC. - Computes the HMAC of a stream using the SHA3-384 algorithm. + Computes the HMAC of a stream using the SHA-3-384 algorithm. The HMAC of the data. To be added. @@ -257,7 +257,7 @@ The HMAC key. The stream to HMAC. - Computes the HMAC of a stream using the SHA3-384 algorithm. + Computes the HMAC of a stream using the SHA-3-384 algorithm. The HMAC of the data. To be added. @@ -296,7 +296,7 @@ The HMAC key. The data to HMAC. - Computes the HMAC of data using the SHA3-384 algorithm. + Computes the HMAC of data using the SHA-3-384 algorithm. The HMAC of the data. To be added. @@ -334,19 +334,19 @@ The HMAC key. The stream to HMAC. The buffer to receive the HMAC value. - Computes the HMAC of a stream using the SHA3-384 algorithm. + Computes the HMAC of a stream using the SHA-3-384 algorithm. The total number of bytes written to . To be added. is . - - - The buffer in is too small to hold the calculated HMAC - size. The SHA3-384 algorithm always produces a 384-bit HMAC, or 48 bytes. - --or- - - does not support reading. + + + The buffer in is too small to hold the calculated HMAC + size. The SHA-3-384 algorithm always produces a 384-bit HMAC, or 48 bytes. + +-or- + + does not support reading. @@ -376,11 +376,11 @@ The HMAC key. The data to HMAC. The buffer to receive the HMAC value. - Computes the HMAC of data using the SHA3-384 algorithm. + Computes the HMAC of data using the SHA-3-384 algorithm. The total number of bytes written to . To be added. - The buffer in is too small to hold the calculated hash - size. The SHA3-384 algorithm always produces a 384-bit HMAC, or 48 bytes. + The buffer in is too small to hold the calculated hash + size. The SHA-3-384 algorithm always produces a 384-bit HMAC, or 48 bytes. @@ -413,9 +413,9 @@ The HMAC key. The stream to HMAC. - The token to monitor for cancellation requests. + The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA3-384 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-3-384 algorithm. The HMAC of the data. To be added. @@ -462,9 +462,9 @@ The HMAC key. The stream to HMAC. - The token to monitor for cancellation requests. + The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA3-384 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-3-384 algorithm. The HMAC of the data. To be added. @@ -507,21 +507,21 @@ The HMAC key. The stream to HMAC. The buffer to receive the HMAC value. - The token to monitor for cancellation requests. + The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA3-384 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-3-384 algorithm. The total number of bytes written to . To be added. is . - - - The buffer in is too small to hold the calculated hash - size. The SHA3-384 algorithm always produces a 384-bit hash, or 48 bytes. - --or- - - does not support reading. + + + The buffer in is too small to hold the calculated hash + size. The SHA-3-384 algorithm always produces a 384-bit hash, or 48 bytes. + +-or- + + does not support reading. The cancellation token was canceled. This exception is stored into the returned task. @@ -570,7 +570,7 @@ 384 - The hash size produced by the HMAC SHA3-384 algorithm, in bits. + The hash size produced by the HMAC SHA-3-384 algorithm, in bits. To be added. @@ -593,7 +593,7 @@ 48 - The hash size produced by the HMAC SHA3-384 algorithm, in bytes. + The hash size produced by the HMAC SHA-3-384 algorithm, in bytes. To be added. @@ -697,7 +697,7 @@ The data to HMAC. The buffer to receive the HMAC value. When this method returns, the total number of bytes written into . - Attempts to compute the HMAC of data using the SHA3-384 algorithm. + Attempts to compute the HMAC of data using the SHA-3-384 algorithm. if is too small to hold the calculated hash, otherwise. To be added. diff --git a/xml/System.Security.Cryptography/HMACSHA3_512.xml b/xml/System.Security.Cryptography/HMACSHA3_512.xml index a973782ec86..71662d5e80d 100644 --- a/xml/System.Security.Cryptography/HMACSHA3_512.xml +++ b/xml/System.Security.Cryptography/HMACSHA3_512.xml @@ -22,7 +22,7 @@ - Computes a Hash-based Message Authentication Code (HMAC) by using the SHA3-512 hash function. + Computes a Hash-based Message Authentication Code (HMAC) by using the SHA-3-512 hash function. To be added. @@ -44,9 +44,9 @@ Initializes a new instance of the class with a randomly generated key. - is a type of keyed hash algorithm that is constructed from the SHA3-512 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 512 bits in length. + is a type of keyed hash algorithm that is constructed from the SHA-3-512 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data, hashes the result with the hash function, mixes that hash value with the secret key again, and then applies the hash function a second time. The output hash is 512 bits in length. - This constructor uses a 72-byte, randomly generated key. + This constructor uses a 72-byte, randomly generated key. @@ -186,7 +186,7 @@ The HMAC key. The data to HMAC. - Computes the HMAC of data using the SHA3-512 algorithm. + Computes the HMAC of data using the SHA-3-512 algorithm. The HMAC of the data. To be added. @@ -217,7 +217,7 @@ The HMAC key. The stream to HMAC. - Computes the HMAC of a stream using the SHA3-512 algorithm. + Computes the HMAC of a stream using the SHA-3-512 algorithm. The HMAC of the data. To be added. @@ -257,7 +257,7 @@ The HMAC key. The stream to HMAC. - Computes the HMAC of a stream using the SHA3-512 algorithm. + Computes the HMAC of a stream using the SHA-3-512 algorithm. The HMAC of the data. To be added. @@ -296,7 +296,7 @@ The HMAC key. The data to HMAC. - Computes the HMAC of data using the SHA3-512 algorithm. + Computes the HMAC of data using the SHA-3-512 algorithm. The HMAC of the data. To be added. @@ -334,19 +334,19 @@ The HMAC key. The stream to HMAC. The buffer to receive the HMAC value. - Computes the HMAC of a stream using the SHA3-512 algorithm. + Computes the HMAC of a stream using the SHA-3-512 algorithm. The total number of bytes written to . To be added. is . - - - The buffer in is too small to hold the calculated HMAC - size. The SHA3-512 algorithm always produces a 512-bit HMAC, or 64 bytes. - --or- - - does not support reading. + + + The buffer in is too small to hold the calculated HMAC + size. The SHA-3-512 algorithm always produces a 512-bit HMAC, or 64 bytes. + +-or- + + does not support reading. @@ -376,11 +376,11 @@ The HMAC key. The data to HMAC. The buffer to receive the HMAC value. - Computes the HMAC of data using the SHA3-512 algorithm. + Computes the HMAC of data using the SHA-3-512 algorithm. The total number of bytes written to . To be added. - The buffer in is too small to hold the calculated hash - size. The SHA3-512 algorithm always produces a 512-bit HMAC, or 64 bytes. + The buffer in is too small to hold the calculated hash + size. The SHA-3-512 algorithm always produces a 512-bit HMAC, or 64 bytes. @@ -413,9 +413,9 @@ The HMAC key. The stream to HMAC. - The token to monitor for cancellation requests. + The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA3-512 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-3-512 algorithm. The HMAC of the data. To be added. @@ -462,9 +462,9 @@ The HMAC key. The stream to HMAC. - The token to monitor for cancellation requests. + The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA3-512 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-3-512 algorithm. The HMAC of the data. To be added. @@ -507,21 +507,21 @@ The HMAC key. The stream to HMAC. The buffer to receive the HMAC value. - The token to monitor for cancellation requests. + The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA3-512 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-3-512 algorithm. The total number of bytes written to . To be added. is . - - - The buffer in is too small to hold the calculated hash - size. The SHA3-512 algorithm always produces a 512-bit hash, or 64 bytes. - --or- - - does not support reading. + + + The buffer in is too small to hold the calculated hash + size. The SHA-3-512 algorithm always produces a 512-bit hash, or 64 bytes. + +-or- + + does not support reading. The cancellation token was canceled. This exception is stored into the returned task. @@ -570,7 +570,7 @@ 512 - The hash size produced by the HMAC SHA3-512 algorithm, in bits. + The hash size produced by the HMAC SHA-3-512 algorithm, in bits. To be added. @@ -593,7 +593,7 @@ 64 - The hash size produced by the HMAC SHA3-512 algorithm, in bytes. + The hash size produced by the HMAC SHA-3-512 algorithm, in bytes. To be added. @@ -697,7 +697,7 @@ The data to HMAC. The buffer to receive the HMAC value. When this method returns, the total number of bytes written into . - Attempts to compute the HMAC of data using the SHA3-512 algorithm. + Attempts to compute the HMAC of data using the SHA-3-512 algorithm. if is too small to hold the calculated hash, otherwise. To be added. diff --git a/xml/System.Security.Cryptography/HMACSHA512.xml b/xml/System.Security.Cryptography/HMACSHA512.xml index 69d725d48c9..2c08947e42e 100644 --- a/xml/System.Security.Cryptography/HMACSHA512.xml +++ b/xml/System.Security.Cryptography/HMACSHA512.xml @@ -67,26 +67,26 @@ Computes a Hash-based Message Authentication Code (HMAC) using the hash function. - is a type of keyed hash algorithm that is constructed from the SHA-512 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data and hashes the result. The hash value is mixed with the secret key again, and then hashed a second time. The output hash is 512 bits in length. - - An HMAC can be used to determine whether a message sent over a nonsecure channel has been tampered with, provided that the sender and receiver share a secret key. The sender computes the hash value for the original data and sends both the original data and hash value as a single message. The receiver recalculates the hash value on the received message and checks that the computed HMAC matches the transmitted HMAC. - - If the original and computed hash values match, the message is authenticated. If they do not match, either the data or the hash value has been changed. HMACs provide security against tampering because knowledge of the secret key is required to change the message and reproduce the correct hash value. - - accepts keys of any size, and produces a hash sequence of length 512 bits. - - - -## Examples - The following example shows how to sign a file by using the object and then how to verify the file. - + is a type of keyed hash algorithm that is constructed from the SHA-512 hash function and used as a Hash-based Message Authentication Code (HMAC). The HMAC process mixes a secret key with the message data and hashes the result. The hash value is mixed with the secret key again, and then hashed a second time. The output hash is 512 bits in length. + + An HMAC can be used to determine whether a message sent over a nonsecure channel has been tampered with, provided that the sender and receiver share a secret key. The sender computes the hash value for the original data and sends both the original data and hash value as a single message. The receiver recalculates the hash value on the received message and checks that the computed HMAC matches the transmitted HMAC. + + If the original and computed hash values match, the message is authenticated. If they do not match, either the data or the hash value has been changed. HMACs provide security against tampering because knowledge of the secret key is required to change the message and reproduce the correct hash value. + + accepts keys of any size, and produces a hash sequence of length 512 bits. + + + +## Examples + The following example shows how to sign a file by using the object and then how to verify the file. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/HMACSHA512/CPP/hmacsha512.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography/HMACSHA512/Overview/hmacsha512.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/HMACSHA512/vb/hmacsha512.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/HMACSHA512/vb/hmacsha512.vb" id="Snippet1"::: + ]]> Cryptographic Services @@ -144,11 +144,11 @@ Initializes a new instance of the class with a randomly generated key. - Cryptographic Services @@ -204,11 +204,11 @@ The secret key for HMAC computation. The key can be any length. However, the recommended size is 128 bytes. If the key is more than 128 bytes long, it is hashed (using SHA-512) to derive a 64-byte key. Initializes a new instance of the class with the specified key data. - class. - + class. + ]]> The parameter is . @@ -374,7 +374,7 @@ The HMAC key. The data to HMAC. - Computes the HMAC of data using the SHA512 algorithm. + Computes the HMAC of data using the SHA-512 algorithm. The HMAC of the data. To be added. @@ -412,7 +412,7 @@ The HMAC key. The stream to HMAC. - Computes the HMAC of a stream using the SHA512 algorithm. + Computes the HMAC of a stream using the SHA-512 algorithm. The HMAC of the data. To be added. @@ -459,7 +459,7 @@ The HMAC key. The stream to HMAC. - Computes the HMAC of a stream using the SHA512 algorithm. + Computes the HMAC of a stream using the SHA-512 algorithm. The HMAC of the data. To be added. @@ -506,7 +506,7 @@ The HMAC key. The data to HMAC. - Computes the HMAC of data using the SHA512 algorithm. + Computes the HMAC of data using the SHA-512 algorithm. The HMAC of the data. To be added. @@ -551,7 +551,7 @@ The HMAC key. The stream to HMAC. The buffer to receive the HMAC value. - Computes the HMAC of a stream using the SHA512 algorithm. + Computes the HMAC of a stream using the SHA-512 algorithm. The total number of bytes written to . To be added. @@ -559,7 +559,7 @@ The buffer in is too small to hold the calculated HMAC - size. The SHA512 algorithm always produces a 512-bit HMAC, or 64 bytes. + size. The SHA-512 algorithm always produces a 512-bit HMAC, or 64 bytes. -or- @@ -602,10 +602,10 @@ The HMAC key. The data to HMAC. The buffer to receive the HMAC value. - Computes the HMAC of data using the SHA512 algorithm. + Computes the HMAC of data using the SHA-512 algorithm. The total number of bytes written to . To be added. - The buffer in is too small to hold the calculated hash size. The SHA512 algorithm always produces a 512-bit HMAC, or 64 bytes. + The buffer in is too small to hold the calculated hash size. The SHA-512 algorithm always produces a 512-bit HMAC, or 64 bytes. @@ -647,7 +647,7 @@ The stream to HMAC. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA512 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-512 algorithm. The HMAC of the data. This method stores in the task it returns all non-usage exceptions that the method's synchronous counterpart can throw. If an exception is stored into the returned task, that exception will be thrown when the task is awaited. Usage exceptions, such as , are still thrown synchronously. For the stored exceptions, see the exceptions thrown by . @@ -703,7 +703,7 @@ The stream to HMAC. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA512 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-512 algorithm. The HMAC of the data. To be added. @@ -755,7 +755,7 @@ The buffer to receive the HMAC value. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the HMAC of a stream using the SHA512 algorithm. + Asynchronously computes the HMAC of a stream using the SHA-512 algorithm. The total number of bytes written to . To be added. @@ -763,7 +763,7 @@ The buffer in is too small to hold the calculated hash - size. The SHA512 algorithm always produces a 512-bit hash, or 64 bytes. + size. The SHA-512 algorithm always produces a 512-bit hash, or 64 bytes. -or- @@ -871,7 +871,7 @@ 512 - The hash size produced by the HMAC SHA512 algorithm, in bits. + The hash size produced by the HMAC SHA-512 algorithm, in bits. To be added. @@ -901,7 +901,7 @@ 64 - The hash size produced by the HMAC SHA512 algorithm, in bytes. + The hash size produced by the HMAC SHA-512 algorithm, in bytes. To be added. @@ -1031,23 +1031,23 @@ to enable .NET Framework 2.0 Service Pack 1 applications to interact with .NET Framework 2.0 applications; otherwise, . - Boolean property is to enable .NET Framework 2.0 Service Pack 1 applications to interact with .NET Framework 2.0 applications. When you set this property to `true`, the object produces values that match the values produced by the .NET Framework 2.0. You should set this property only once after you create your HMAC object. You will need to reset your key afterwards, as shown in the following example. - + Boolean property is to enable .NET Framework 2.0 Service Pack 1 applications to interact with .NET Framework 2.0 applications. When you set this property to `true`, the object produces values that match the values produced by the .NET Framework 2.0. You should set this property only once after you create your HMAC object. You will need to reset your key afterwards, as shown in the following example. + ```csharp public static void Test() -{ - var hmac = new HMACSHA512(); - hmac.ProduceLegacyHmacValues = true; - hmac.Key = // ...Get the HMAC key. - // ... - // Use the HMAC algorithm. +{ + var hmac = new HMACSHA512(); + hmac.ProduceLegacyHmacValues = true; + hmac.Key = // ...Get the HMAC key. // ... -} -``` - + // Use the HMAC algorithm. + // ... +} +``` + ]]> Cryptographic Services @@ -1089,7 +1089,7 @@ public static void Test() The data to HMAC. The buffer to receive the HMAC value. When this method returns, contains the total number of bytes written into . - Attempts to compute the HMAC of data using the SHA512 algorithm. + Attempts to compute the HMAC of data using the SHA-512 algorithm. if is too small to hold the calculated hash, otherwise. To be added. diff --git a/xml/System.Security.Cryptography/HashAlgorithm.xml b/xml/System.Security.Cryptography/HashAlgorithm.xml index 6fab98e0c7a..1a687a01934 100644 --- a/xml/System.Security.Cryptography/HashAlgorithm.xml +++ b/xml/System.Security.Cryptography/HashAlgorithm.xml @@ -85,7 +85,7 @@ The hash is used as a unique value of fixed size representing a large amount of data. Hashes of two sets of data should match if the corresponding data also matches. Small changes to the data result in large unpredictable changes in the hash. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ## Examples The following code example computes the hash for an array. This example assumes that there is a predefined byte array `dataArray[]`. is a derived class of . @@ -608,7 +608,7 @@ This method is obsolete in .NET 5 and later versions. By default, this overload uses the implementation of a hash algorithm. If you want to specify a different implementation, use the overload, which lets you specify an algorithm name, instead. The cryptography configuration system defines the default implementation of . - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> diff --git a/xml/System.Security.Cryptography/HashAlgorithmName.xml b/xml/System.Security.Cryptography/HashAlgorithmName.xml index 37b54cc9e4d..fc348ba0023 100644 --- a/xml/System.Security.Cryptography/HashAlgorithmName.xml +++ b/xml/System.Security.Cryptography/HashAlgorithmName.xml @@ -65,21 +65,20 @@ Specifies the name of a cryptographic hash algorithm. - structure includes some static properties that return predefined hash algorithm names, as well as a property that can represent a custom hash algorithm name as a strongly-typed string. Hash algorithm names are case-sensitive. - - Asymmetric algorithms implemented using Microsoft's CNG (Cryptographic Next Generation) API interpret the underlying string value as a [CNG algorithm identifier](/windows/win32/seccng/cng-algorithm-identifiers). - - Asymmetric algorithms implemented using other technologies: - -- Must recognize at least "MD5", "SHA1", "SHA256", "SHA384", and "SHA512". - -- Should recognize additional CNG identifiers for any additional hash algorithms that they support. - -Due to collision problems with MD5 and SHA1, Microsoft recommends a security model based on SHA256 or better. - + structure includes some static properties that return predefined hash algorithm names, as well as a property that can represent a custom hash algorithm name as a strongly-typed string. Hash algorithm names are case-sensitive. + + Asymmetric algorithms implemented using Microsoft's CNG (Cryptographic Next Generation) API interpret the underlying string value as a [CNG algorithm identifier](/windows/win32/seccng/cng-algorithm-identifiers). + + Asymmetric algorithms implemented using other technologies: + +- Must recognize at least "MD5", "SHA1", "SHA256", "SHA384", and "SHA512". +- Should recognize additional CNG identifiers for any additional hash algorithms that they support. + +Due to collision problems with MD5 and SHA-1, Microsoft recommends a security model based on SHA-256 or better. + ]]> @@ -126,11 +125,11 @@ Due to collision problems with MD5 and SHA1, Microsoft recommends a security mod The custom hash algorithm name. Initializes a new instance of the structure with a custom name. - @@ -376,7 +375,7 @@ Due to collision problems with MD5 and SHA1, Microsoft recommends a security mod Gets a hash algorithm name that represents "MD5". A hash algorithm name that represents "MD5". - Due to collision problems with MD5, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with MD5, Microsoft recommends a security model based on SHA-256 or better. @@ -421,12 +420,12 @@ Due to collision problems with MD5 and SHA1, Microsoft recommends a security mod Gets the underlying string representation of the algorithm name. The string representation of the algorithm name, or if no hash algorithm is available. - @@ -479,11 +478,11 @@ May be `null` or empty to indicate that no hash algorithm is applicable. if both and have the same value; otherwise, . - method defines the operation of the equality operator for values. - + method defines the operation of the equality operator for values. + ]]> @@ -536,11 +535,11 @@ May be `null` or empty to indicate that no hash algorithm is applicable. if both and do not have the same value; otherwise, . - method defines the operation of the inequality operator for values. - + method defines the operation of the inequality operator for values. + ]]> @@ -585,7 +584,7 @@ May be `null` or empty to indicate that no hash algorithm is applicable. Gets a hash algorithm name that represents "SHA1". A hash algorithm name that represents "SHA1". - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. @@ -846,11 +845,11 @@ May be `null` or empty to indicate that no hash algorithm is applicable. Returns the string representation of the current instance. The string representation of the current instance. - method returns the property, if it has been assigned. Otherwise, it returns . - + method returns the property, if it has been assigned. Otherwise, it returns . + ]]> diff --git a/xml/System.Security.Cryptography/KeyedHashAlgorithm.xml b/xml/System.Security.Cryptography/KeyedHashAlgorithm.xml index 599da5dae58..0e2efcadbc1 100644 --- a/xml/System.Security.Cryptography/KeyedHashAlgorithm.xml +++ b/xml/System.Security.Cryptography/KeyedHashAlgorithm.xml @@ -71,7 +71,7 @@ Hash functions are commonly used with digital signatures and for data integrity. The class is an example of a keyed hash algorithm. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ## Examples The following code example demonstrates how to derive from the class. @@ -205,7 +205,7 @@ ## Remarks By default, this overload uses the implementation of a keyed hash algorithm. If you want to specify a different implementation, use the overload, which lets you specify an algorithm name, instead. The cryptography configuration system defines the default implementation of the class. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> diff --git a/xml/System.Security.Cryptography/MD5.xml b/xml/System.Security.Cryptography/MD5.xml index c32caa46fea..b596eee9aba 100644 --- a/xml/System.Security.Cryptography/MD5.xml +++ b/xml/System.Security.Cryptography/MD5.xml @@ -64,21 +64,18 @@ Represents the abstract class from which all implementations of the hash algorithm inherit. - algorithm is 128 bits. - - The methods of the class return the hash as an array of 16 bytes. Note that some MD5 implementations produce a 32-character, hexadecimal-formatted hash. To interoperate with such implementations, format the return value of the methods as a hexadecimal value. - + algorithm is 128 bits. + + The methods of the class return the hash as an array of 16 bytes. Note that some MD5 implementations produce a 32-character, hexadecimal-formatted hash. To interoperate with such implementations, format the return value of the methods as a hexadecimal value. + > [!NOTE] -> Due to collision problems with MD5/SHA1, Microsoft recommends SHA256 or SHA512. Consider using the class or the class instead of the class. Use only for compatibility with legacy applications and data. - - - - +> Due to collision problems with MD5/SHA-1, Microsoft recommends SHA-256 or SHA-512. Consider using the class or the class instead of the class. Use only for compatibility with legacy applications and data. + ]]> Cryptographic Services @@ -125,11 +122,11 @@ Initializes a new instance of . - class, use the method. - + class, use the method. + ]]> Cryptographic Services @@ -274,11 +271,11 @@ Creates an instance of the specified implementation of the hash algorithm. A new instance of the specified implementation of . - The algorithm described by the parameter was used with Federal Information Processing Standards (FIPS) mode enabled, but is not FIPS compatible. diff --git a/xml/System.Security.Cryptography/PKCS1MaskGenerationMethod.xml b/xml/System.Security.Cryptography/PKCS1MaskGenerationMethod.xml index 22254df2304..53ebfc2dc27 100644 --- a/xml/System.Security.Cryptography/PKCS1MaskGenerationMethod.xml +++ b/xml/System.Security.Cryptography/PKCS1MaskGenerationMethod.xml @@ -69,11 +69,11 @@ Computes masks according to PKCS #1 for use by key exchange algorithms. - Cryptographic Services @@ -123,12 +123,12 @@ Initializes a new instance of the class. - to the default hash algorithm name (SHA1). + to the default hash algorithm name (SHA1). + + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> @@ -189,11 +189,11 @@ Generates and returns a mask from the specified random seed of the specified length. A randomly generated mask whose length is equal to the parameter. - Cryptographic Services @@ -241,13 +241,13 @@ Gets or sets the name of the hash algorithm type to use for generating the mask. The name of the type that implements the hash algorithm to use for computing the mask. - is used by default. + is used by default. + + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. - ]]> Cryptographic Services diff --git a/xml/System.Security.Cryptography/RSACryptoServiceProvider.xml b/xml/System.Security.Cryptography/RSACryptoServiceProvider.xml index 7445f99433f..90c2139f0c7 100644 --- a/xml/System.Security.Cryptography/RSACryptoServiceProvider.xml +++ b/xml/System.Security.Cryptography/RSACryptoServiceProvider.xml @@ -2190,7 +2190,7 @@ The supported RSA key sizes depend on the available cryptographic service provid The valid hash algorithms are and . The algorithm identifier can be derived from the hash name by using the method. - Due to collision problems with SHA1 and MD5, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1 and MD5, Microsoft recommends a security model based on SHA-256 or better. ## Examples The following code example encrypts some data, creates a hash of the encrypted data, and then signs hash with a digital signature. @@ -2504,7 +2504,7 @@ The supported RSA key sizes depend on the available cryptographic service provid The valid hash algorithms are and . The algorithm identifier can be derived from the hash name by using the method. - Due to collision problems with SHA1 and MD5, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1 and MD5, Microsoft recommends a security model based on SHA-256 or better. ## Examples The following example shows how to use the method to verify a signature. This code example is part of a larger example provided for the method. diff --git a/xml/System.Security.Cryptography/RSAEncryptionPadding.xml b/xml/System.Security.Cryptography/RSAEncryptionPadding.xml index 61d074c3e20..aac0cbe506d 100644 --- a/xml/System.Security.Cryptography/RSAEncryptionPadding.xml +++ b/xml/System.Security.Cryptography/RSAEncryptionPadding.xml @@ -186,11 +186,11 @@ if is equal to the current instance; otherwise, . - object and the two objects have identical and property values. - + object and the two objects have identical and property values. + ]]> @@ -254,11 +254,11 @@ if is equal to the current instance; otherwise, . - and property values. - + and property values. + ]]> @@ -397,12 +397,12 @@ Gets the hash algorithm used in conjunction with the padding mode. The hash algorithm. - property is not , then will be `null`. - + property is not , then will be `null`. + ]]> @@ -447,9 +447,9 @@ If the value of the System.Security.Cryptography.RSAEncryptionPadding - Gets an object that represents the Optimal Asymmetric Encryption Padding (OAEP) encryption standard with a SHA1 hash algorithm. - An object that represents the OAEP encryption standard with a SHA1 hash algorithm. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Gets an object that represents the Optimal Asymmetric Encryption Padding (OAEP) encryption standard with a SHA-1 hash algorithm. + An object that represents the OAEP encryption standard with a SHA-1 hash algorithm. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. @@ -492,8 +492,8 @@ If the value of the System.Security.Cryptography.RSAEncryptionPadding - Gets an object that represents the Optimal Asymmetric Encryption Padding (OAEP) encryption standard with a SHA256 hash algorithm. - An object that represents the OAEP encryption standard with a SHA256 hash algorithm. + Gets an object that represents the Optimal Asymmetric Encryption Padding (OAEP) encryption standard with a SHA-256 hash algorithm. + An object that represents the OAEP encryption standard with a SHA-256 hash algorithm. To be added. @@ -522,7 +522,7 @@ If the value of the - mode with SHA3-256 hash algorithm. + mode with SHA-3-256 hash algorithm. To be added. To be added. @@ -552,7 +552,7 @@ If the value of the - mode with SHA3-384 hash algorithm. + mode with SHA-3-384 hash algorithm. To be added. To be added. @@ -582,7 +582,7 @@ If the value of the - mode with SHA3-512 hash algorithm. + mode with SHA-3-512 hash algorithm. To be added. To be added. @@ -628,7 +628,7 @@ If the value of the Gets an object that represents the Optimal Asymmetric Encryption Padding (OAEP) encryption standard with a SHA-384 hash algorithm. - An object that represents the OAEP encryption standard with a SHA384 hash algorithm. + An object that represents the OAEP encryption standard with a SHA-384 hash algorithm. To be added. @@ -672,8 +672,8 @@ If the value of the System.Security.Cryptography.RSAEncryptionPadding - Gets an object that represents the Optimal Asymmetric Encryption Padding (OAEP) encryption standard with a SHA512 hash algorithm. - An object that represents the OAEP encryption standard with a SHA512 hash algorithm. + Gets an object that represents the Optimal Asymmetric Encryption Padding (OAEP) encryption standard with a SHA-512 hash algorithm. + An object that represents the OAEP encryption standard with a SHA-512 hash algorithm. To be added. @@ -728,11 +728,11 @@ If the value of the if and are equal; otherwise, . - objects are equal if their and property values are equal. - + objects are equal if their and property values are equal. + ]]> @@ -788,11 +788,11 @@ If the value of the if and are not equal; otherwise, . - objects are not equal if their and property values are not equal. - + objects are not equal if their and property values are not equal. + ]]> @@ -886,11 +886,11 @@ If the value of the Returns the string representation of the current instance. The string representation of the current object. - object is the concatenation of its and `OaepHashAlgorithm.Name` properties. - + object is the concatenation of its and `OaepHashAlgorithm.Name` properties. + ]]> diff --git a/xml/System.Security.Cryptography/SHA1.xml b/xml/System.Security.Cryptography/SHA1.xml index ef677c60cdd..7d7006785af 100644 --- a/xml/System.Security.Cryptography/SHA1.xml +++ b/xml/System.Security.Cryptography/SHA1.xml @@ -60,16 +60,16 @@ Computes the hash for the input data. - algorithm is 160 bits. - - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. - - + algorithm is 160 bits. + + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. + + ]]> Cryptographic Services @@ -116,11 +116,11 @@ Initializes a new instance of . - The policy on this object is not compliant with the FIPS algorithm. @@ -191,11 +191,11 @@ Creates an instance of the default implementation of . A new instance of . - is . - + is . + ]]> Cryptographic Services @@ -267,7 +267,7 @@ The name of the specific implementation of to be used. Creates an instance of the specified implementation of . A new instance of using the specified implementation. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. Cryptographic Services @@ -302,7 +302,7 @@ The data to hash. - Computes the hash of data using the SHA1 algorithm. + Computes the hash of data using the SHA-1 algorithm. The hash of the data. To be added. @@ -338,7 +338,7 @@ The stream to hash. - Computes the hash of a stream using the SHA1 algorithm. + Computes the hash of a stream using the SHA-1 algorithm. The hash of the data. To be added. @@ -384,7 +384,7 @@ The data to hash. - Computes the hash of data using the SHA1 algorithm. + Computes the hash of data using the SHA-1 algorithm. The hash of the data. To be added. @@ -427,7 +427,7 @@ The stream to hash. The buffer to receive the hash value. - Computes the hash of a stream using the SHA1 algorithm. + Computes the hash of a stream using the SHA-1 algorithm. The total number of bytes written to . To be added. @@ -435,7 +435,7 @@ The buffer in is too small to hold the calculated hash - size. The SHA1 algorithm always produces a 160-bit hash, or 20 bytes. + size. The SHA-1 algorithm always produces a 160-bit hash, or 20 bytes. -or- @@ -477,10 +477,10 @@ The data to hash. The buffer to receive the hash value. - Computes the hash of data using the SHA1 algorithm. + Computes the hash of data using the SHA-1 algorithm. The total number of bytes written to . To be added. - The buffer in is too small to hold the calculated hash size. The SHA1 algorithm always produces a 160-bit hash, or 20 bytes. + The buffer in is too small to hold the calculated hash size. The SHA-1 algorithm always produces a 160-bit hash, or 20 bytes. @@ -520,7 +520,7 @@ The stream to hash. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the hash of a stream using the SHA1 algorithm. + Asynchronously computes the hash of a stream using the SHA-1 algorithm. The hash of the data. This method stores in the task it returns all non-usage exceptions that the method's synchronous counterpart can throw. If an exception is stored into the returned task, that exception will be thrown when the task is awaited. Usage exceptions, such as , are still thrown synchronously. For the stored exceptions, see the exceptions thrown by . @@ -570,7 +570,7 @@ The buffer to receive the hash value. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the hash of a stream using the SHA1 algorithm. + Asynchronously computes the hash of a stream using the SHA-1 algorithm. The total number of bytes written to . To be added. @@ -578,7 +578,7 @@ The buffer in is too small to hold the calculated hash - size. The SHA1 algorithm always produces a 160-bit hash, or 20 bytes. + size. The SHA-1 algorithm always produces a 160-bit hash, or 20 bytes. -or- @@ -614,7 +614,7 @@ 160 - The hash size produced by the SHA1 algorithm, in bits. + The hash size produced by the SHA-1 algorithm, in bits. To be added. @@ -644,7 +644,7 @@ 20 - The hash size produced by the SHA1 algorithm, in bytes. + The hash size produced by the SHA-1 algorithm, in bytes. To be added. @@ -683,7 +683,7 @@ The data to hash. The buffer to receive the hash value. When this method returns, the total number of bytes written into . - Attempts to compute the hash of data using the SHA1 algorithm. + Attempts to compute the hash of data using the SHA-1 algorithm. if is too small to hold the calculated hash, otherwise. To be added. diff --git a/xml/System.Security.Cryptography/SHA1Cng.xml b/xml/System.Security.Cryptography/SHA1Cng.xml index c3f65b56df2..49a2c6577df 100644 --- a/xml/System.Security.Cryptography/SHA1Cng.xml +++ b/xml/System.Security.Cryptography/SHA1Cng.xml @@ -17,13 +17,13 @@ Provides a Cryptography Next Generation (CNG) implementation of the Secure Hash Algorithm (SHA). - diff --git a/xml/System.Security.Cryptography/SHA1CryptoServiceProvider.xml b/xml/System.Security.Cryptography/SHA1CryptoServiceProvider.xml index f1f829d70b3..7d4fae452b0 100644 --- a/xml/System.Security.Cryptography/SHA1CryptoServiceProvider.xml +++ b/xml/System.Security.Cryptography/SHA1CryptoServiceProvider.xml @@ -66,16 +66,16 @@ Computes the hash value for the input data using the implementation provided by the cryptographic service provider (CSP). This class cannot be inherited. - class is 160 bits. - + class is 160 bits. + > [!IMPORTANT] -> This type implements the interface. When you have finished using the type, you should dispose of it either directly or indirectly. To dispose of the type directly, call its method in a `try`/`catch` block. To dispose of it indirectly, use a language construct such as `using` (in C#) or `Using` (in Visual Basic). For more information, see the "Using an Object that Implements IDisposable" section in the interface topic. - -Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. - +> This type implements the interface. When you have finished using the type, you should dispose of it either directly or indirectly. To dispose of the type directly, call its method in a `try`/`catch` block. To dispose of it indirectly, use a language construct such as `using` (in C#) or `Using` (in Visual Basic). For more information, see the "Using an Object that Implements IDisposable" section in the interface topic. + +Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. + ]]> Cryptographic Services diff --git a/xml/System.Security.Cryptography/SHA1Managed.xml b/xml/System.Security.Cryptography/SHA1Managed.xml index 37d69e82381..eb47da3f712 100644 --- a/xml/System.Security.Cryptography/SHA1Managed.xml +++ b/xml/System.Security.Cryptography/SHA1Managed.xml @@ -78,7 +78,7 @@ The hash size for the algorithm is 160 bits. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> @@ -122,7 +122,7 @@ Initializes a new instance of the class. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. This class is not compliant with the FIPS algorithm. Cryptographic Services @@ -326,7 +326,7 @@ This method is called by the public Returns the computed hash value after all data has been written to the object. The computed hash code. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. Cryptographic Services @@ -373,7 +373,7 @@ This method is called by the public Initializes an instance of . - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. Cryptographic Services diff --git a/xml/System.Security.Cryptography/SHA256.xml b/xml/System.Security.Cryptography/SHA256.xml index 44b9c9d7d8d..84b2ff59f48 100644 --- a/xml/System.Security.Cryptography/SHA256.xml +++ b/xml/System.Security.Cryptography/SHA256.xml @@ -60,22 +60,22 @@ Computes the hash for the input data. - algorithm is 256 bits. - - This is an abstract class. - -## Examples - The following example calculates the SHA-256 hash for all files in a directory. - + algorithm is 256 bits. + + This is an abstract class. + +## Examples + The following example calculates the SHA-256 hash for all files in a directory. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_Classic/classic SHA256 Example/CPP/source.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography/HashAlgorithm/ComputeHash/source.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_Classic/classic SHA256 Example/VB/source.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_Classic/classic SHA256 Example/VB/source.vb" id="Snippet1"::: + ]]> Cryptographic Services @@ -126,11 +126,11 @@ Initializes a new instance of . - Cryptographic Services @@ -272,9 +272,9 @@ Creates an instance of a specified implementation of . A new instance of using the specified implementation. - The data to hash. - Computes the hash of data using the SHA256 algorithm. + Computes the hash of data using the SHA-256 algorithm. The hash of the data. To be added. @@ -356,7 +356,7 @@ The .NET Framework includes the implementations and their associated hashName va The stream to hash. - Computes the hash of a stream using the SHA256 algorithm. + Computes the hash of a stream using the SHA-256 algorithm. The hash of the data. To be added. @@ -402,7 +402,7 @@ The .NET Framework includes the implementations and their associated hashName va The data to hash. - Computes the hash of data using the SHA256 algorithm. + Computes the hash of data using the SHA-256 algorithm. The hash of the data. To be added. @@ -445,13 +445,13 @@ The .NET Framework includes the implementations and their associated hashName va The stream to hash. The buffer to receive the hash value. - Computes the hash of a stream using the SHA256 algorithm. + Computes the hash of a stream using the SHA-256 algorithm. The total number of bytes written to . To be added. is . - The buffer in is too small to hold the calculated hash size. The SHA256 algorithm always produces a 256-bit hash, or 32 bytes. + The buffer in is too small to hold the calculated hash size. The SHA-256 algorithm always produces a 256-bit hash, or 32 bytes. -or- does not support reading. @@ -491,10 +491,10 @@ The .NET Framework includes the implementations and their associated hashName va The data to hash. The buffer to receive the hash value. - Computes the hash of data using the SHA256 algorithm. + Computes the hash of data using the SHA-256 algorithm. The total number of bytes written to . To be added. - The buffer in is too small to hold the calculated hash size. The SHA256 algorithm always produces a 256-bit hash, or 32 bytes. + The buffer in is too small to hold the calculated hash size. The SHA-256 algorithm always produces a 256-bit hash, or 32 bytes. @@ -534,7 +534,7 @@ The .NET Framework includes the implementations and their associated hashName va The stream to hash. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the hash of a stream using the SHA256 algorithm. + Asynchronously computes the hash of a stream using the SHA-256 algorithm. The hash of the data. This method stores in the task it returns all non-usage exceptions that the method's synchronous counterpart can throw. If an exception is stored into the returned task, that exception will be thrown when the task is awaited. Usage exceptions, such as , are still thrown synchronously. For the stored exceptions, see the exceptions thrown by . @@ -584,7 +584,7 @@ The .NET Framework includes the implementations and their associated hashName va The buffer to receive the hash value. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the hash of a stream using the SHA256 algorithm. + Asynchronously computes the hash of a stream using the SHA-256 algorithm. The total number of bytes written to . To be added. @@ -592,7 +592,7 @@ The .NET Framework includes the implementations and their associated hashName va The buffer in is too small to hold the calculated hash - size. The SHA256 algorithm always produces a 256-bit hash, or 32 bytes. + size. The SHA-256 algorithm always produces a 256-bit hash, or 32 bytes. -or- @@ -628,7 +628,7 @@ The .NET Framework includes the implementations and their associated hashName va 256 - The hash size produced by the SHA256 algorithm, in bits. + The hash size produced by the SHA-256 algorithm, in bits. To be added. @@ -658,7 +658,7 @@ The .NET Framework includes the implementations and their associated hashName va 32 - The hash size produced by the SHA256 algorithm, in bytes. + The hash size produced by the SHA-256 algorithm, in bytes. To be added. @@ -697,7 +697,7 @@ The .NET Framework includes the implementations and their associated hashName va The data to hash. The buffer to receive the hash value. When this method returns, the total number of bytes written into . - Attempts to compute the hash of data using the SHA256 algorithm. + Attempts to compute the hash of data using the SHA-256 algorithm. if is too small to hold the calculated hash, otherwise. To be added. diff --git a/xml/System.Security.Cryptography/SHA384.xml b/xml/System.Security.Cryptography/SHA384.xml index f7d2c3cbd45..cf56d6e8e7e 100644 --- a/xml/System.Security.Cryptography/SHA384.xml +++ b/xml/System.Security.Cryptography/SHA384.xml @@ -60,22 +60,22 @@ Computes the hash for the input data. - algorithm is 384 bits. - - - -## Examples - The following example computes the hash for `data` and stores it in `result`. This example assumes that there is a predefined constant `DATA_SIZE`. - + algorithm is 384 bits. + + + +## Examples + The following example computes the hash for `data` and stores it in `result`. This example assumes that there is a predefined constant `DATA_SIZE`. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_Classic/classic SHA384 Example/CPP/source.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography/SHA384/Overview/source.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_Classic/classic SHA384 Example/VB/source.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_Classic/classic SHA384 Example/VB/source.vb" id="Snippet1"::: + ]]> Cryptographic Services @@ -126,11 +126,11 @@ Initializes a new instance of . - Cryptographic Services @@ -306,7 +306,7 @@ The data to hash. - Computes the hash of data using the SHA384 algorithm. + Computes the hash of data using the SHA-384 algorithm. The hash of the data. To be added. @@ -342,7 +342,7 @@ The stream to hash. - Computes the hash of a stream using the SHA384 algorithm. + Computes the hash of a stream using the SHA-384 algorithm. The hash of the data. To be added. @@ -388,7 +388,7 @@ The data to hash. - Computes the hash of data using the SHA384 algorithm. + Computes the hash of data using the SHA-384 algorithm. The hash of the data. To be added. @@ -431,7 +431,7 @@ The stream to hash. The buffer to receive the hash value. - Computes the hash of a stream using the SHA384 algorithm. + Computes the hash of a stream using the SHA-384 algorithm. The total number of bytes written to . To be added. @@ -439,7 +439,7 @@

The buffer in is too small to hold the calculated hash - size. The SHA384 algorithm always produces a 384-bit hash, or 48 bytes. + size. The SHA-384 algorithm always produces a 384-bit hash, or 48 bytes.

-or-

@@ -481,10 +481,10 @@ The data to hash. The buffer to receive the hash value. -

Computes the hash of data using the SHA384 algorithm. + Computes the hash of data using the SHA-384 algorithm. The total number of bytes written to . To be added. - The buffer in is too small to hold the calculated hash size. The SHA384 algorithm always produces a 384-bit hash, or 48 bytes. + The buffer in is too small to hold the calculated hash size. The SHA-384 algorithm always produces a 384-bit hash, or 48 bytes.
@@ -524,7 +524,7 @@ The stream to hash. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the hash of a stream using the SHA384 algorithm. + Asynchronously computes the hash of a stream using the SHA-384 algorithm. The hash of the data. This method stores in the task it returns all non-usage exceptions that the method's synchronous counterpart can throw. If an exception is stored into the returned task, that exception will be thrown when the task is awaited. Usage exceptions, such as , are still thrown synchronously. For the stored exceptions, see the exceptions thrown by . @@ -574,7 +574,7 @@ The buffer to receive the hash value. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the hash of a stream using the SHA384 algorithm. + Asynchronously computes the hash of a stream using the SHA-384 algorithm. The total number of bytes written to . To be added. @@ -582,7 +582,7 @@

The buffer in is too small to hold the calculated hash - size. The SHA384 algorithm always produces a 384-bit hash, or 48 bytes. + size. The SHA-384 algorithm always produces a 384-bit hash, or 48 bytes.

-or-

@@ -618,7 +618,7 @@ 384 -

The hash size produced by the SHA384 algorithm, in bits. + The hash size produced by the SHA-384 algorithm, in bits. To be added.
@@ -648,7 +648,7 @@ 48 - The hash size produced by the SHA384 algorithm, in bytes. + The hash size produced by the SHA-384 algorithm, in bytes. To be added. @@ -687,7 +687,7 @@ The data to hash. The buffer to receive the hash value. When this method returns, the total number of bytes written into . - Attempts to compute the hash of data using the SHA384 algorithm. + Attempts to compute the hash of data using the SHA-384 algorithm. if is too small to hold the calculated hash, otherwise. To be added. diff --git a/xml/System.Security.Cryptography/SHA3_256.xml b/xml/System.Security.Cryptography/SHA3_256.xml index 2c1e9f88050..45a1190a680 100644 --- a/xml/System.Security.Cryptography/SHA3_256.xml +++ b/xml/System.Security.Cryptography/SHA3_256.xml @@ -16,7 +16,7 @@ - Computes the SHA3-256 hash for the input data. + Computes the SHA-3-256 hash for the input data. This algorithm is specified by FIPS 202. @@ -61,7 +61,7 @@ Creates an instance of the default implementation of . A new instance of . To be added. - The platform does not support SHA3-256. + The platform does not support SHA-3-256.
@@ -86,12 +86,12 @@ The data to hash. - Computes the hash of data using the SHA3-256 algorithm. + Computes the hash of data using the SHA-3-256 algorithm. The hash of the data. To be added. is . - The platform does not support SHA3-256. + The platform does not support SHA-3-256. @@ -116,14 +116,14 @@ The stream to hash. - Computes the hash of a stream using the SHA3-256 algorithm. + Computes the hash of a stream using the SHA-3-256 algorithm. The hash of the data. To be added. is . does not support reading. - The platform does not support SHA3-256. + The platform does not support SHA-3-256. @@ -154,10 +154,10 @@ The data to hash. - Computes the hash of data using the SHA3-256 algorithm. + Computes the hash of data using the SHA-3-256 algorithm. The hash of the data. To be added. - The platform does not support SHA3-256. + The platform does not support SHA-3-256. @@ -191,22 +191,22 @@ The stream to hash. The buffer to receive the hash value. - Computes the hash of a stream using the SHA3-256 algorithm. + Computes the hash of a stream using the SHA-3-256 algorithm. The total number of bytes written to . To be added. is . -

- The buffer in is too small to hold the calculated hash - size. The SHA3-256 algorithm always produces a 256-bit hash, or 32 bytes. +

+ The buffer in is too small to hold the calculated hash + size. The SHA-3-256 algorithm always produces a 256-bit hash, or 32 bytes.

-or-

- does not support reading. + does not support reading.

- The platform does not support SHA3-256. + The platform does not support SHA-3-256.
@@ -233,12 +233,12 @@ The data to hash. The buffer to receive the hash value. - Computes the hash of data using the SHA3-256 algorithm. + Computes the hash of data using the SHA-3-256 algorithm. The total number of bytes written to . To be added. - The buffer in is too small to hold the calculated hash - size. The SHA3-256 algorithm always produces a 256-bit hash, or 32 bytes. - The platform does not support SHA3-256. + The buffer in is too small to hold the calculated hash + size. The SHA-3-256 algorithm always produces a 256-bit hash, or 32 bytes. + The platform does not support SHA-3-256. @@ -269,16 +269,16 @@ The stream to hash. - The token to monitor for cancellation requests. + The token to monitor for cancellation requests. The default value is . - Asynchronously computes the hash of a stream using the SHA3-256 algorithm. + Asynchronously computes the hash of a stream using the SHA-3-256 algorithm. The hash of the data. To be added. is . does not support reading. - The platform does not support SHA3-256. + The platform does not support SHA-3-256. The cancellation token was canceled. This exception is stored into the returned task. @@ -313,24 +313,24 @@ The stream to hash. The buffer to receive the hash value. - The token to monitor for cancellation requests. + The token to monitor for cancellation requests. The default value is . - Asynchronously computes the hash of a stream using the SHA3-256 algorithm. + Asynchronously computes the hash of a stream using the SHA-3-256 algorithm. The total number of bytes written to . To be added. is . -

- The buffer in is too small to hold the calculated hash - size. The SHA3-256 algorithm always produces a 256-bit hash, or 32 bytes. +

+ The buffer in is too small to hold the calculated hash + size. The SHA-3-256 algorithm always produces a 256-bit hash, or 32 bytes.

-or-

- does not support reading. + does not support reading.

- The platform does not support SHA3-256. + The platform does not support SHA-3-256. The cancellation token was canceled. This exception is stored into the returned task.
@@ -353,7 +353,7 @@ 256 - The hash size produced by the SHA3-256 algorithm, in bits. + The hash size produced by the SHA-3-256 algorithm, in bits. To be added. @@ -376,7 +376,7 @@ 32 - The hash size produced by the SHA3-256 algorithm, in bytes. + The hash size produced by the SHA-3-256 algorithm, in bytes. To be added. @@ -430,11 +430,11 @@ The data to hash. The buffer to receive the hash value. When this method returns, the total number of bytes written into . - Attempts to compute the hash of data using the SHA3-256 algorithm. + Attempts to compute the hash of data using the SHA-3-256 algorithm. if is too small to hold the calculated hash, otherwise. To be added. - The platform does not support SHA3-256. + The platform does not support SHA-3-256.
diff --git a/xml/System.Security.Cryptography/SHA3_384.xml b/xml/System.Security.Cryptography/SHA3_384.xml index bc160daba22..9a80c8e1f57 100644 --- a/xml/System.Security.Cryptography/SHA3_384.xml +++ b/xml/System.Security.Cryptography/SHA3_384.xml @@ -16,7 +16,7 @@ - Computes the SHA3-384 hash for the input data. + Computes the SHA-3-384 hash for the input data. This algorithm is specified by FIPS 202. @@ -61,7 +61,7 @@ Creates an instance of the default implementation of . A new instance of . To be added. - The platform does not support SHA3-384. + The platform does not support SHA-3-384. @@ -86,12 +86,12 @@ The data to hash. - Computes the hash of data using the SHA3-384 algorithm. + Computes the hash of data using the SHA-3-384 algorithm. The hash of the data. To be added. is . - The platform does not support SHA3-384. + The platform does not support SHA-3-384. @@ -116,14 +116,14 @@ The stream to hash. - Computes the hash of a stream using the SHA3-384 algorithm. + Computes the hash of a stream using the SHA-3-384 algorithm. The hash of the data. To be added. is . does not support reading. - The platform does not support SHA3-384. + The platform does not support SHA-3-384. @@ -154,10 +154,10 @@ The data to hash. - Computes the hash of data using the SHA3-384 algorithm. + Computes the hash of data using the SHA-3-384 algorithm. The hash of the data. To be added. - The platform does not support SHA3-384. + The platform does not support SHA-3-384. @@ -191,21 +191,21 @@ The stream to hash. The buffer to receive the hash value. - Computes the hash of a stream using the SHA3-384 algorithm. + Computes the hash of a stream using the SHA-3-384 algorithm. The total number of bytes written to . To be added. is . - - - The buffer in is too small to hold the calculated hash - size. The SHA3-384 algorithm always produces a 384-bit hash, or 48 bytes. - --or- - - does not support reading. + + + The buffer in is too small to hold the calculated hash + size. The SHA-3-384 algorithm always produces a 384-bit hash, or 48 bytes. + +-or- + + does not support reading. - The platform does not support SHA3-384. + The platform does not support SHA-3-384. @@ -232,12 +232,12 @@ The data to hash. The buffer to receive the hash value. - Computes the hash of data using the SHA3-384 algorithm. + Computes the hash of data using the SHA-3-384 algorithm. The total number of bytes written to . To be added. - The buffer in is too small to hold the calculated hash - size. The SHA3-384 algorithm always produces a 384-bit hash, or 48 bytes. - The platform does not support SHA3-384. + The buffer in is too small to hold the calculated hash + size. The SHA-3-384 algorithm always produces a 384-bit hash, or 48 bytes. + The platform does not support SHA-3-384. @@ -268,16 +268,16 @@ The stream to hash. - The token to monitor for cancellation requests. + The token to monitor for cancellation requests. The default value is . - Asynchronously computes the hash of a stream using the SHA3-384 algorithm. + Asynchronously computes the hash of a stream using the SHA-3-384 algorithm. The hash of the data. To be added. is . does not support reading. - The platform does not support SHA3-384. + The platform does not support SHA-3-384. The cancellation token was canceled. This exception is stored into the returned task. @@ -312,23 +312,23 @@ The stream to hash. The buffer to receive the hash value. - The token to monitor for cancellation requests. + The token to monitor for cancellation requests. The default value is . - Asynchronously computes the hash of a stream using the SHA3-384 algorithm. + Asynchronously computes the hash of a stream using the SHA-3-384 algorithm. The total number of bytes written to . To be added. is . - - - The buffer in is too small to hold the calculated hash - size. The SHA3-384 algorithm always produces a 384-bit hash, or 48 bytes. - --or- - - does not support reading. + + + The buffer in is too small to hold the calculated hash + size. The SHA-3-384 algorithm always produces a 384-bit hash, or 48 bytes. + +-or- + + does not support reading. - The platform does not support SHA3-384. + The platform does not support SHA-3-384. The cancellation token was canceled. This exception is stored into the returned task. @@ -351,7 +351,7 @@ 384 - The hash size produced by the SHA3-384 algorithm, in bits. + The hash size produced by the SHA-3-384 algorithm, in bits. To be added. @@ -374,7 +374,7 @@ 48 - The hash size produced by the SHA3-384 algorithm, in bytes. + The hash size produced by the SHA-3-384 algorithm, in bytes. To be added. @@ -428,11 +428,11 @@ The data to hash. The buffer to receive the hash value. When this method returns, the total number of bytes written into . - Attempts to compute the hash of data using the SHA3-384 algorithm. + Attempts to compute the hash of data using the SHA-3-384 algorithm. if is too small to hold the calculated hash, otherwise. To be added. - The platform does not support SHA3-384. + The platform does not support SHA-3-384. diff --git a/xml/System.Security.Cryptography/SHA3_512.xml b/xml/System.Security.Cryptography/SHA3_512.xml index fb93703be0f..b868eed615c 100644 --- a/xml/System.Security.Cryptography/SHA3_512.xml +++ b/xml/System.Security.Cryptography/SHA3_512.xml @@ -16,7 +16,7 @@ - Computes the SHA3-512 hash for the input data. + Computes the SHA-3-512 hash for the input data. This algorithm is specified by FIPS 202. @@ -61,7 +61,7 @@ Creates an instance of the default implementation of . A new instance of . To be added. - The platform does not support SHA3-512. + The platform does not support SHA-3-512. @@ -86,12 +86,12 @@ The data to hash. - Computes the hash of data using the SHA3-512 algorithm. + Computes the hash of data using the SHA-3-512 algorithm. The hash of the data. To be added. is . - The platform does not support SHA3-512. + The platform does not support SHA-3-512. @@ -116,14 +116,14 @@ The stream to hash. - Computes the hash of a stream using the SHA3-512 algorithm. + Computes the hash of a stream using the SHA-3-512 algorithm. The hash of the data. To be added. is . does not support reading. - The platform does not support SHA3-512. + The platform does not support SHA-3-512. @@ -154,10 +154,10 @@ The data to hash. - Computes the hash of data using the SHA3-512 algorithm. + Computes the hash of data using the SHA-3-512 algorithm. The hash of the data. To be added. - The platform does not support SHA3-512. + The platform does not support SHA-3-512. @@ -191,21 +191,21 @@ The stream to hash. The buffer to receive the hash value. - Computes the hash of a stream using the SHA3-512 algorithm. + Computes the hash of a stream using the SHA-3-512 algorithm. The total number of bytes written to . To be added. is . - - - The buffer in is too small to hold the calculated hash - size. The SHA3-512 algorithm always produces a 512-bit hash, or 64 bytes. - --or- - - does not support reading. + + + The buffer in is too small to hold the calculated hash + size. The SHA-3-512 algorithm always produces a 512-bit hash, or 64 bytes. + +-or- + + does not support reading. - The platform does not support SHA3-512. + The platform does not support SHA-3-512. @@ -232,12 +232,12 @@ The data to hash. The buffer to receive the hash value. - Computes the hash of data using the SHA3-512 algorithm. + Computes the hash of data using the SHA-3-512 algorithm. The total number of bytes written to . To be added. - The buffer in is too small to hold the calculated hash - size. The SHA3-512 algorithm always produces a 512-bit hash, or 64 bytes. - The platform does not support SHA3-512. + The buffer in is too small to hold the calculated hash + size. The SHA-3-512 algorithm always produces a 512-bit hash, or 64 bytes. + The platform does not support SHA-3-512. @@ -268,16 +268,16 @@ The stream to hash. - The token to monitor for cancellation requests. + The token to monitor for cancellation requests. The default value is . - Asynchronously computes the hash of a stream using the SHA3-512 algorithm. + Asynchronously computes the hash of a stream using the SHA-3-512 algorithm. The hash of the data. To be added. is . does not support reading. - The platform does not support SHA3-512. + The platform does not support SHA-3-512. The cancellation token was canceled. This exception is stored into the returned task. @@ -312,23 +312,23 @@ The stream to hash. The buffer to receive the hash value. - The token to monitor for cancellation requests. + The token to monitor for cancellation requests. The default value is . - Asynchronously computes the hash of a stream using the SHA3-512 algorithm. + Asynchronously computes the hash of a stream using the SHA-3-512 algorithm. The total number of bytes written to . To be added. is . - - - The buffer in is too small to hold the calculated hash - size. The SHA3-512 algorithm always produces a 512-bit hash, or 64 bytes. - --or- - - does not support reading. + + + The buffer in is too small to hold the calculated hash + size. The SHA-3-512 algorithm always produces a 512-bit hash, or 64 bytes. + +-or- + + does not support reading. - The platform does not support SHA3-512. + The platform does not support SHA-3-512. The cancellation token was canceled. This exception is stored into the returned task. @@ -351,7 +351,7 @@ 512 - The hash size produced by the SHA3-512 algorithm, in bits. + The hash size produced by the SHA-3-512 algorithm, in bits. To be added. @@ -374,7 +374,7 @@ 64 - The hash size produced by the SHA3-512 algorithm, in bytes. + The hash size produced by the SHA-3-512 algorithm, in bytes. To be added. @@ -428,11 +428,11 @@ The data to hash. The buffer to receive the hash value. When this method returns, the total number of bytes written into . - Attempts to compute the hash of data using the SHA3-512 algorithm. + Attempts to compute the hash of data using the SHA-3-512 algorithm. if is too small to hold the calculated hash, otherwise. To be added. - The platform does not support SHA3-512. + The platform does not support SHA-3-512. diff --git a/xml/System.Security.Cryptography/SHA512.xml b/xml/System.Security.Cryptography/SHA512.xml index 06e94e0ffe8..75b97dd9458 100644 --- a/xml/System.Security.Cryptography/SHA512.xml +++ b/xml/System.Security.Cryptography/SHA512.xml @@ -60,24 +60,24 @@ Computes the hash for the input data. - algorithm is 512 bits. - - This is an abstract class. The only implementation of this class is . - - - -## Examples - The following example computes the hash for `data` and stores it in `result`. This example assumes that there is a predefined constant `DATA_SIZE`. - + algorithm is 512 bits. + + This is an abstract class. The only implementation of this class is . + + + +## Examples + The following example computes the hash for `data` and stores it in `result`. This example assumes that there is a predefined constant `DATA_SIZE`. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_Classic/classic SHA512 Example/CPP/source.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Cryptography/SHA512/Overview/source.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_Classic/classic SHA512 Example/VB/source.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_Classic/classic SHA512 Example/VB/source.vb" id="Snippet1"::: + ]]> Cryptographic Services @@ -128,11 +128,11 @@ Initializes a new instance of . - Cryptographic Services @@ -273,11 +273,11 @@ Creates an instance of a specified implementation of . A new instance of using the specified implementation. - The algorithm described by the parameter was used with Federal Information Processing Standards (FIPS) mode enabled, but is not FIPS compatible. @@ -315,7 +315,7 @@ The data to hash. - Computes the hash of data using the SHA512 algorithm. + Computes the hash of data using the SHA-512 algorithm. The hash of the data. To be added. @@ -351,7 +351,7 @@ The stream to hash. - Computes the hash of a stream using the SHA512 algorithm. + Computes the hash of a stream using the SHA-512 algorithm. The hash of the data. To be added. @@ -397,7 +397,7 @@ The data to hash. - Computes the hash of data using the SHA512 algorithm. + Computes the hash of data using the SHA-512 algorithm. The hash of the data. To be added. @@ -440,7 +440,7 @@ The stream to hash. The buffer to receive the hash value. - Computes the hash of a stream using the SHA512 algorithm. + Computes the hash of a stream using the SHA-512 algorithm. The total number of bytes written to . To be added. @@ -448,7 +448,7 @@

The buffer in is too small to hold the calculated hash - size. The SHA512 algorithm always produces a 512-bit hash, or 64 bytes. + size. The SHA-512 algorithm always produces a 512-bit hash, or 64 bytes.

-or-

@@ -490,10 +490,10 @@ The data to hash. The buffer to receive the hash value. -

Computes the hash of data using the SHA512 algorithm. + Computes the hash of data using the SHA-512 algorithm. The total number of bytes written to . To be added. - The buffer in is too small to hold the calculated hash size. The SHA512 algorithm always produces a 512-bit hash, or 64 bytes. + The buffer in is too small to hold the calculated hash size. The SHA-512 algorithm always produces a 512-bit hash, or 64 bytes.
@@ -533,7 +533,7 @@ The stream to hash. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the hash of a stream using the SHA512 algorithm. + Asynchronously computes the hash of a stream using the SHA-512 algorithm. The hash of the data. This method stores in the task it returns all non-usage exceptions that the method's synchronous counterpart can throw. If an exception is stored into the returned task, that exception will be thrown when the task is awaited. Usage exceptions, such as , are still thrown synchronously. For the stored exceptions, see the exceptions thrown by . @@ -583,7 +583,7 @@ The buffer to receive the hash value. The token to monitor for cancellation requests. The default value is . - Asynchronously computes the hash of a stream using the SHA512 algorithm. + Asynchronously computes the hash of a stream using the SHA-512 algorithm. The total number of bytes written to . To be added. @@ -591,7 +591,7 @@

The buffer in is too small to hold the calculated hash - size. The SHA512 algorithm always produces a 512-bit hash, or 64 bytes. + size. The SHA-512 algorithm always produces a 512-bit hash, or 64 bytes.

-or-

@@ -627,7 +627,7 @@ 512 -

The hash size produced by the SHA512 algorithm, in bits. + The hash size produced by the SHA-512 algorithm, in bits. To be added.
@@ -657,7 +657,7 @@ 64 - The hash size produced by the SHA512 algorithm, in bytes. + The hash size produced by the SHA-512 algorithm, in bytes. To be added. @@ -696,7 +696,7 @@ The data to hash. The buffer to receive the hash value. When this method returns, the total number of bytes written into . - Attempts to compute the hash of data using the SHA512 algorithm. + Attempts to compute the hash of data using the SHA-512 algorithm. if is too small to hold the calculated hash, otherwise. To be added. diff --git a/xml/System.Security.Policy/Hash.xml b/xml/System.Security.Policy/Hash.xml index 729c2abdd07..bd779ed7755 100644 --- a/xml/System.Security.Policy/Hash.xml +++ b/xml/System.Security.Policy/Hash.xml @@ -55,14 +55,14 @@ Provides evidence about the hash value for an assembly. This class cannot be inherited. - and hash algorithms is supported, although any hash algorithm can be used through . + and hash algorithms is supported, although any hash algorithm can be used through . + + Due to collision problems with MD5 and SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> @@ -101,11 +101,11 @@ The assembly for which to compute the hash value. Initializes a new instance of the class. - The parameter is . @@ -174,12 +174,12 @@ Creates a object that contains an hash value. An object that contains the hash value provided by the parameter. - object contains only the property. + object contains only the property. + + Due to collision problems with MD5, Microsoft recommends a security model based on SHA-256 or better. ]]> @@ -222,12 +222,12 @@ Creates a object that contains a hash value. An object that contains the hash value provided by the parameter. - object contains only the property. + object contains only the property. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. ]]> @@ -268,11 +268,11 @@ Creates a object that contains a hash value. A hash object that contains the hash value provided by the parameter. - object contains only the property. - + object contains only the property. + ]]> The parameter is . @@ -315,11 +315,11 @@ Computes the hash value for the assembly using the specified hash algorithm. A byte array that represents the hash value for the assembly. - . The returned hash value is of the type identified by `hashAlg`. - + . The returned hash value is of the type identified by `hashAlg`. + ]]> The parameter is . @@ -381,11 +381,11 @@ The contextual information about the source or destination. Gets the object with the parameter name and additional exception information. - interface. - + interface. + ]]> @@ -423,14 +423,14 @@ Gets the hash value for the assembly. A byte array that represents the hash value for the assembly. -
@@ -468,20 +468,20 @@ Gets the hash value for the assembly. A byte array that represents the hash value for the assembly. - hash for `myAssembly` and stores it in `hashcode`. - + hash for `myAssembly` and stores it in `hashcode`. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_Classic/classic Hash.SHA1 Example/CPP/source.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Security.Policy/Hash/SHA1/source.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_Classic/classic Hash.SHA1 Example/VB/source.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_Classic/classic Hash.SHA1 Example/VB/source.vb" id="Snippet1"::: + ]]>
@@ -516,11 +516,11 @@ Gets the hash value for the assembly. A byte array that represents the hash value for the assembly. - constructor provides the bytes for the hash computation. - + constructor provides the bytes for the hash computation. + ]]>
@@ -559,11 +559,11 @@ Returns a string representation of the current . A representation of the current . - diff --git a/xml/System.ServiceModel.Security/Basic128SecurityAlgorithmSuite.xml b/xml/System.ServiceModel.Security/Basic128SecurityAlgorithmSuite.xml index 78ded59bd35..41ee693748e 100644 --- a/xml/System.ServiceModel.Security/Basic128SecurityAlgorithmSuite.xml +++ b/xml/System.ServiceModel.Security/Basic128SecurityAlgorithmSuite.xml @@ -80,7 +80,7 @@ Gets the default asymmetric signature algorithm, RsaSha1Signature. The default asymmetric signature algorithm, RsaSha1Signature. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. @@ -122,7 +122,7 @@ Gets the default digest algorithm, Sha1Digest. The default digest algorithm, Sha1Digest. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. @@ -248,7 +248,7 @@ Gets the default symmetric signature algorithm, HmacSha1Signature. The default symmetric signature algorithm, HmacSha1Signature. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. diff --git a/xml/System.ServiceModel.Security/Basic192SecurityAlgorithmSuite.xml b/xml/System.ServiceModel.Security/Basic192SecurityAlgorithmSuite.xml index 3b42c29cb2b..35204969d8b 100644 --- a/xml/System.ServiceModel.Security/Basic192SecurityAlgorithmSuite.xml +++ b/xml/System.ServiceModel.Security/Basic192SecurityAlgorithmSuite.xml @@ -80,7 +80,7 @@ Gets the default asymmetric signature algorithm, RsaSha1Signature. The default asymmetric signature algorithm, RsaSha1Signature. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. @@ -122,7 +122,7 @@ Gets the default digest algorithm, Sha1Digest. The default digest algorithm, Sha1Digest. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. @@ -248,7 +248,7 @@ Gets the default symmetric signature algorithm, HmacSha1Signature. The default symmetric signature algorithm, HmacSha1Signature. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. diff --git a/xml/System.ServiceModel.Security/Basic256SecurityAlgorithmSuite.xml b/xml/System.ServiceModel.Security/Basic256SecurityAlgorithmSuite.xml index dadbcb5fc20..1c7db09969d 100644 --- a/xml/System.ServiceModel.Security/Basic256SecurityAlgorithmSuite.xml +++ b/xml/System.ServiceModel.Security/Basic256SecurityAlgorithmSuite.xml @@ -114,7 +114,7 @@ Gets the default asymmetric signature algorithm, RsaSha1Signature. The default asymmetric signature algorithm, RsaSha1Signature. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. @@ -172,7 +172,7 @@ Gets the default digest algorithm, Sha1Digest. The default digest algorithm, Sha1Digest. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. @@ -346,7 +346,7 @@ Gets the default symmetric signature algorithm, HmacSha1Signature. The default symmetric signature algorithm, HmacSha1Signature. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. diff --git a/xml/System.ServiceModel.Security/SecurityKeyEntropyMode.xml b/xml/System.ServiceModel.Security/SecurityKeyEntropyMode.xml index 23f8cca1136..c9d0b82f86a 100644 --- a/xml/System.ServiceModel.Security/SecurityKeyEntropyMode.xml +++ b/xml/System.ServiceModel.Security/SecurityKeyEntropyMode.xml @@ -44,11 +44,11 @@ Describes the source of entropy used for key generation. - @@ -120,7 +120,7 @@ 2 - The client and server both provide entropy that is combined using the P-SHA1 function to derive the key of the issued token. Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + The client and server both provide entropy that is combined using the P-SHA1 function to derive the key of the issued token. Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. diff --git a/xml/System.ServiceModel.Security/TripleDesSecurityAlgorithmSuite.xml b/xml/System.ServiceModel.Security/TripleDesSecurityAlgorithmSuite.xml index f42744883b4..8e15b8b654f 100644 --- a/xml/System.ServiceModel.Security/TripleDesSecurityAlgorithmSuite.xml +++ b/xml/System.ServiceModel.Security/TripleDesSecurityAlgorithmSuite.xml @@ -114,7 +114,7 @@ Gets the default asymmetric signature algorithm, RsaSha1Signature. The default asymmetric signature algorithm, RsaSha1Signature. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. @@ -172,7 +172,7 @@ Gets the default digest algorithm, Sha1Digest. The default digest algorithm, Sha1Digest. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. @@ -346,7 +346,7 @@ Gets the default symmetric signature algorithm, HmacSha1Signature. The default symmetric signature algorithm, HmacSha1Signature. - Due to collision problems with SHA1, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with SHA-1, Microsoft recommends a security model based on SHA-256 or better. diff --git a/xml/System.ServiceModel/MsmqSecureHashAlgorithm.xml b/xml/System.ServiceModel/MsmqSecureHashAlgorithm.xml index f08056b50b0..523042e6787 100644 --- a/xml/System.ServiceModel/MsmqSecureHashAlgorithm.xml +++ b/xml/System.ServiceModel/MsmqSecureHashAlgorithm.xml @@ -17,13 +17,13 @@ Contains the hashing algorithms that Message Queuing (MSMQ) can use to sign messages. - class is an enumeration that contains the hashing algorithms that Message Queuing can use to sign messages. - - Sha256 and Sha512 are supported only on Windows Vista. - + class is an enumeration that contains the hashing algorithms that Message Queuing can use to sign messages. + + Sha256 and Sha512 are supported only on Windows Vista. + ]]> @@ -67,7 +67,7 @@ 1 - The Secure Hash Algorithm (SHA-1). Due to collision problems with SHA1, Microsoft recommends SHA256. + The Secure Hash Algorithm (SHA-1). Due to collision problems with SHA-1, Microsoft recommends SHA-256. diff --git a/xml/System.ServiceModel/MsmqTransportSecurity.xml b/xml/System.ServiceModel/MsmqTransportSecurity.xml index 561eb923cb4..cf79e7e0fd0 100644 --- a/xml/System.ServiceModel/MsmqTransportSecurity.xml +++ b/xml/System.ServiceModel/MsmqTransportSecurity.xml @@ -100,11 +100,11 @@ Gets or sets the that is associated with this instance of the class. The that is associated with this instance of the class. - . - + . + ]]> The value is not one of values. @@ -140,11 +140,11 @@ Gets or sets the that is associated with this instance of the class. The that is associated with this instance of the class. - . - + . + ]]> The value is not one of values. @@ -180,11 +180,11 @@ Gets or sets the that is associated with this instance of the class. The that is associated with this instance of the class. - . - + . + ]]> The value is not one of the values. @@ -224,13 +224,13 @@ Gets or sets the that is associated with this instance of the class. The that is associated with this instance of the class. - . + . + + Due to collision problems with SHA-1, Microsoft recommends SHA-256. - Due to collision problems with SHA1, Microsoft recommends SHA256. - ]]> The value is not one of values. diff --git a/xml/System.Workflow.ComponentModel.Compiler/WorkflowMarkupSourceAttribute.xml b/xml/System.Workflow.ComponentModel.Compiler/WorkflowMarkupSourceAttribute.xml index f421431cdf5..71e2b4961e2 100644 --- a/xml/System.Workflow.ComponentModel.Compiler/WorkflowMarkupSourceAttribute.xml +++ b/xml/System.Workflow.ComponentModel.Compiler/WorkflowMarkupSourceAttribute.xml @@ -27,13 +27,13 @@ Attribute that contains information about a Workflow markup file. This class cannot be inherited. - [!NOTE] -> [!INCLUDE[DeprecatedContent](~/includes/deprecatedcontent-md.md)] - +> [!INCLUDE[DeprecatedContent](~/includes/deprecatedcontent-md.md)] + ]]> @@ -59,7 +59,7 @@ A string that contains the file name of the mark up file. A string representing the for the file. Initializes a new instance of the class, initializing the values of and . - Due to collision problems with MD5, Microsoft recommends a security model based on SHA256 or better. + Due to collision problems with MD5, Microsoft recommends a security model based on SHA-256 or better. @@ -104,12 +104,12 @@ Gets the MD5 hash algorithm computed checksum that is associated with the workflow markup source file. A that contains the checksum associated with the workflow markup source file. -