MiddleTierAuthenticationBuilderExtensions.UsePasswordAuthentication(IMiddleTierAuthenticationBuilder, Action<MiddleTierPasswordAuthenticationOptions>) Method
In This Article
Enables standard authentication (with a login and password) in the Middle Tier application server.
Namespace: DevExpress.ExpressApp.Win.ApplicationBuilder
Assembly: DevExpress.ExpressApp.Win.v24.2.dll
NuGet Packages: DevExpress.ExpressApp.Win, DevExpress.ExpressApp.Win.Design
#Declaration
public static IMiddleTierAuthenticationBuilder UsePasswordAuthentication(
this IMiddleTierAuthenticationBuilder builder,
Action<MiddleTierPasswordAuthenticationOptions> configureOptions = null
)
#Parameters
Name | Type | Description |
---|---|---|
builder | IMiddle |
Allows you to enable and configure the Security System in your application, and chain further configuration. |
#Optional Parameters
Name | Type | Default | Description |
---|---|---|---|
configure |
Action<DevExpress. |
null | For internal use. Do not specify these settings in your application. |
#Returns
Type |
---|
IMiddle |
#Remarks
The following example demonstrates how to use this method:
File: MySolution.Win\Startup.cs.
using DevExpress.ExpressApp.ApplicationBuilder;
using DevExpress.ExpressApp.Win.ApplicationBuilder;
// ...
public class ApplicationBuilder : IDesignTimeApplicationFactory {
public static WinApplication BuildApplication(string connectionString) {
var builder = WinApplication.CreateBuilder();
builder.UseApplication<MySolutionWindowsFormsApplication>();
// ...
builder.Security
.UseMiddleTierMode(options => {
// ...
})
.UsePasswordAuthentication();
// ...
}
// ...
}
See Also