PortSight Secure Access Documentation

Using ASP.NET 2.0 Membership with Secure Access


ASP.NET membership enables you to validate and manage user information for your Web application. It is primarily intended for use with ASP.NET forms authentication, but can be used anywhere within an ASP.NET application. For more information, see Managing Users by Using Membership in Visual Studio documentation.

ASP.NET membership consists primarily of built-in membership providers, which communicate with the data source, and the static membership class that exposes the functionality of the membership providers. If you want to use Secure Access as a membership provider in your application, proceed the following steps:


  1. Add ARWebSecurity.dll to your project's references.


  2. Specify Secure Access database connection:
    1. If your application is not going to use any other Secure Access functionality (inlcuding Secure Access user controls), add an entry to the /configuration/connectionStrings section of your Web.config file, since this is the default connection string management approach in ASP.NET 2.0 configuration.

           <add name="SecureAccessConnectionString"
              connectionString="data source=localhost;initial catalog=SecureAccess;user id=portsight;password=p0sight%.x"/>

    2. If your application already uses some Secure Access classes or user controls, continue using its connection string configuration placed in the /configuration/appSettings section of your Web.config file.

           <add key="SecureAccessConnectionString"
              value="data source=localhost;initial catalog=SecureAccess;user id=portsight;password=p0sight%.x" />		 

  3. Modify the /configuration/system.web/membership section so that it contains the following text:

       <membership defaultProvider="SecureAccessProvider">
             <add name="SecureAccessProvider"

What you did:

Save the configuration file. Since now, you can use the built-in Web Site Administration Tool to manage access rights to your pages using the information saved in the Secure Access database. Also feel free to use all of the ASP.NET 2.0 login controls.