NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

Message.UseAuthentication

Gets or sets a value indicating whether a message must be authenticated.

[Visual Basic]
Overridable Public Property UseAuthentication As Boolean
[C#]
public bool UseAuthentication {virtual get; virtual set;}
[C++]
public: __property virtual bool get_UseAuthentication();
public: __property virtual void set_UseAuthentication(bool);
[JScript]
public function get UseAuthentication() : Boolean;
public function set UseAuthentication(Boolean);

Property Value

true if the sending application requested authentication for the message; otherwise, false. The default is false.

Exceptions

Exception Type Condition
InvalidOperationException The message queue is filtered not to read the UseAuthentication property.

Remarks

UseAuthentication provides access to the IsAuthenticated property of the Message Queuing MSMQMessage object.

Note   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.

Example

See Also

Message Class | Message Members | System.Messaging Namespace | Authenticated | ConnectorType | AuthenticationProviderName | AuthenticationProviderType | DigitalSignature | Authenticate