Partager via


SoapContext.Credentials Property

Gets the security tokens that are associated with the Web service and the Web service client.

Namespace: Microsoft.Web.Services3
Assembly: Microsoft.Web.Services3 (in microsoft.web.services3.dll)

Usage

'Usage
Dim soapContext1 As SoapContext

Dim returnValue As CredentialContext
returnValue = soapContext1.Credentials

Syntax

'Declaration
Public ReadOnly Property Credentials() As CredentialContext
public CredentialContext Credentials {get;}
public:
property CredentialContext^ Credentials {
    CredentialContext^ get();
}
public CredentialContext get_Credentials();
public function get Credentials() : CredentialContext;

Property Value

A CredentialContext that contains the security tokens that are associated with the Web service and the Web service client.

Remarks

Use the SetCredentials method of the Credentials property to specify the security tokens that authenticate the client and protect the SOAP messages. This is commonly done in a filter within a custom policy assertion or when a client secures SOAP messages uses mixed policy or does not use a policy file. For more information about creating custom policy assertions, see Custom Policy Assertions. For more information about a client that secures SOAP messages using mixed policy or does not use a policy file, see How to: Secure a Client Using Mixed Policy and Code and How to: Secure a Client Without Using a Policy File, respectively.

Thread Safety

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

Platforms

Development Platforms

Windows XP Home Edition, Windows XP Professional, Windows Server 2003, Windows 2000, Windows 2000 Server, Windows 2000 Advanced Server

Target Platforms

See Also

Reference

SoapContext Class
SoapContext Members
Microsoft.Web.Services3 Namespace