SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Zealot
    Join Date
    Dec 2003
    Location
    springfield,IL
    Posts
    102
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    ASP.Net 2.0 "Build Your Own Website" - Membership and Roles

    This was posted under another forum and it doesnt seem like it gets much attention. I thought I would repost it here and hope it get a quicker response. This is more active area, I apologize in advance if I am doing this incorrectly. I too would like to find an answer to the OP question since I thought about this too.

    Quote Originally Posted by eatme View Post
    I recently purchased "Build you own ASP.NET 2.0 Web Site.." which is an excellent book for the site I'm creating, however, I'm a little bit confused with Chapter 13 (Security and User Authentication).

    As I understand from this chapter, you can use the ASP.NET Web Site Configuration Tool to create new membership profiles with user names and passwords, etc.. This tool also automatically creates 11 new database tables within the specified database to store these new profiles.

    I've created new user names along with passwords using the Configuration Tool and these all seem to work fine when I login through my Login.aspx page (that uses a <asp:Login/> tag).

    Earlier on in the book, I had created an Employees table that stored fields such as Username, Password, etc.. So for example, the first employee's details were "Username = zak" and "Password = zak". Yet, I'm unable to login to the site using the user names and passwords that I had previously created in the Employees table.

    My question is how am I supposed to login using the Employee user names and passwords without having to go through the Configuration Tool and set one up for each employee?

    If it is generally best to use the Configuration Tool to create every employees user name and password, is it then a case of connecting the aspnet_Membership table with the Employees table using some relationship?

    I'd really appreciate any useful feedback, thanks.

  2. #2
    SitePoint Guru Chroniclemaster1's Avatar
    Join Date
    Jun 2007
    Location
    San Diego, CA
    Posts
    784
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    From what I know, The ASPNET tables are fairly important because they implement a lot of default security. Stuff that's pretty sophistacated and MUCH better than 99&#37; of developers would be able to create on their own. As far as best practices is concerned, I'm pretty sure you want to get those employees into the default tables (with the added bonus that those are working fine).

    Now that's not to say that you should be manually entering all that information into the configuration tool. There should be some way to pass the information from the employee table to that ASPNET tables so that each one is created as a new user account. This however, is a little beyond me. I hope someone who's used this a bit more has some feedback too. But I think that's the direction you should be looking, and I'm certain there are even conversion tools out there, though how much they cost may be a drawback.
    Whatever you can do or dream you can, begin it.
    Boldness has genius, power and magic in it. Begin it now.

    Chroniclemaster1, Founder of Earth Chronicle
    A Growing History of our Planet, by our Planet, for our Planet.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •