UserNamePasswordServiceCredential::UserNamePasswordValidationMode Property


Gets or sets the method of validating the user name and password.

Namespace:   System.ServiceModel.Security
Assembly:  System.ServiceModel (in System.ServiceModel.dll)

property UserNamePasswordValidationMode UserNamePasswordValidationMode {
	UserNamePasswordValidationMode get();
	void set(UserNamePasswordValidationMode value);

Possible values are:

If this property is set to Custom, the service uses the object returned by CustomUserNamePasswordValidator to validate user names and passwords in incoming messages.


When a WCF service is hosted in Internet Information Services (IIS) using transport-level security and the UserNamePasswordValidationMode property is set to Custom, the custom authentication scheme uses a subset of Windows authentication. That is because in this scenario, IIS performs Windows authentication prior to WCF invoking the custom authenticator.

When the value of this property is set to MembershipProvider, specify the membership provider by setting the MembershipProvider property, and then the membership provider instance specified by the MembershipProvider property is used to validate the username and password in incoming messages.

The following example gets the value of this property.

No code example is currently available or this language may not be supported.

.NET Framework
Available since 3.0
Return to top