Membership Learning (1) Introduction to Membership

Source: Internet
Author: User

Asp.net's membership provides a unified path for storing, verifying, and managing user information and permissions. The authentication method for membership is asp.net Forms authentication (note: There are several authentication methods for asp.net, including windows Authentication Forms authentication Passport authentication, of course, there is still no authentication ). In vs2005, membership also provides a series of controls (login controls) to conveniently implement membership in asp.net.
Specifically, membership can be implemented as follows:
1. Create a user
2. You can save the membership Information in SQL server, Active Directory, and other data storage methods.
3. identify who is visiting your website. If you use the login control, you can do this without writing code.
4. Manage the password. Including creating, modifying, and resetting
5. Create a unique value to mark each login user, which enables User Personalization and role management.
6. A user-defined membership provider is provided to save and manage the unique data of your website.

Some work to make membership work:
1. in the web. in config, enter some membership settings. In asp.net, membership is allowed by default, and the default data is saved on SQL server using ms. you can make some settings to provide other data storage methods, including custom methods. This will be detailed in the subsequent articles
2. Set your website to use Forms authentication,
3. Define a user account for membership. You can use the web administrator tool provided by vs2005 for configuration, or you can create a user page by yourself. On the custom page, you only need to call membership. createuser to conveniently create a user.

Membership management and Configuration:
In web. config, the easiest way to configure and manage membership is to use the Web Site Administration Tool (in the websits menu of vs2005 ). You can specify whether the membership provider is SQL server or other. Password Management includes whether to encrypt and save the password and whether to provide users with a mechanism to recover the password Based on the preset problems. Of course, the web site administration tool can be used to directly create and manage users and roles.

 

The convenience of Membership is that after a user passes authentication, the storage of his information is automatically completed by the system, so how can I safely and completely transmit Login User information on various pages can be solved.

If you use the login control that comes with vs2005, you must be clear that the function implementation of the login Control calls the membership class functions. We can write all the controls by ourselves.

Later, we will introduce the use of membership. My introduction also provides some translation and arrangement for msdn.

Post from: http://www.cnblogs.com/dotLive

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.