Export (0) Print
Expand All

SimpleWebTokenCredential Class

Note: This API is now obsolete.

Represents the Simple Web Token credential used for a client endpoint.


Namespace:  Microsoft.ServiceBus.Description
Assembly:  Microsoft.ServiceBus (in Microsoft.ServiceBus.dll)

[ObsoleteAttribute("This class is deprecated.  Please use SimpleWebTokenProvider instead.  See TokenProvider.CreateSimpleWebTokenProvider for details.")]
public class SimpleWebTokenCredential : TransportClientCredentialBase

The SimpleWebTokenCredential type exposes the following members.

Public propertySimpleWebTokenGets or sets the token string for a Simple Web Token assertion.

Public methodEquals (Inherited from Object.)
Protected methodFinalize (Inherited from Object.)
Public methodGetHashCode (Inherited from Object.)
Public methodGetType (Inherited from Object.)
Protected methodMemberwiseClone (Inherited from Object.)
Public methodToString (Inherited from Object.)

The following code example sets the credential type of the TransportClientEndpointBehavior to the Simple Web Token credential type. Next, it computes a Simple Web Token string value and sets it to the endpoint behavior through the SimpleWebToken property of the TransportClientCredentials..::..SimpleWebToken credential of type SimpleWebTokenCredential.

TransportClientEndpointBehavior behavior = new TransportClientEndpointBehavior();
behavior.CredentialType = TransportClientCredentialType.SimpleWebToken;
behavior.Credentials.SimpleWebToken.SimpleWebToken = SharedSecretCredential.ComputeSimpleWebTokenString(issuerName, issuerSecret);

Dim behavior As New TransportClientEndpointBehavior()
behavior.CredentialType = TransportClientCredentialType.SimpleWebToken
behavior.Credentials.SimpleWebToken.SimpleWebToken = SharedSecretCredential.ComputeSimpleWebTokenString(issuerName, issuerSecret)

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Community Additions

© 2014 Microsoft