Message.DestinationSymmetricKey Property
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets or sets the symmetric key used to encrypt application-encrypted messages or messages sent to foreign queues.
public:
property cli::array <System::Byte> ^ DestinationSymmetricKey { cli::array <System::Byte> ^ get(); void set(cli::array <System::Byte> ^ value); };
[System.Messaging.MessagingDescription("MsgDestinationSymmetricKey")]
public byte[] DestinationSymmetricKey { get; set; }
[<System.Messaging.MessagingDescription("MsgDestinationSymmetricKey")>]
member this.DestinationSymmetricKey : byte[] with get, set
Public Property DestinationSymmetricKey As Byte()
An array of byte values that specifies the destination symmetric key used to encrypt the message. The default is a zero-length array.
- Attributes
The message queue is filtered to ignore the DestinationSymmetricKey property.
The DestinationSymmetricKey is null
.
Two scenarios require you to use the DestinationSymmetricKey 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 DestinationSymmetricKey property, you must also set the ConnectorType property. When the message is sent, Message Queuing ignores the DestinationSymmetricKey property if the ConnectorType property is not also set.
The DestinationSymmetricKey property has a maximum array size of 256.
Product | Versions |
---|---|
.NET Framework | 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
.NET feedback
.NET is an open source project. Select a link to provide feedback: