Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Web Development
  3. ASP.NET
  4. asp.net 2.0 forms authentication needing multiple logins

asp.net 2.0 forms authentication needing multiple logins

Scheduled Pinned Locked Moved ASP.NET
securityquestioncsharpasp-netdatabase
6 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    janetb99
    wrote on last edited by
    #1

    Would like best advise on following situation (been looking and haven't found much). Have a .net 2 site with custom forms authentication enabled for subfolder /calendar working fine (uses an already existing sql2005 database to lookup user/pwd combinations). authentication mode="Forms" loginUrl="calendar/login.aspx" name=".myName" path="calendar/" defaultUrl="calendar/default.aspx" enableCrossAppRedirects="false" <location path="calendar/admin"> <system.web> <authorization> <allow roles="adm"/> <deny users="*"/> </authorization> </system.web> </location> But, I now have a need for a smaller subset of folks to gain access to another subfolder /conference with a DIFFERENT lookup to an sql2005 database for it's subfolder /conference/admin. Totally separate from the scenario in paragraph 2. If I put a stripped-out webconfig in the /conference subfolder with only the location path information and the login information using a different cookie name, will that work? Or, how can I do this? Janet

    L 1 Reply Last reply
    0
    • J janetb99

      Would like best advise on following situation (been looking and haven't found much). Have a .net 2 site with custom forms authentication enabled for subfolder /calendar working fine (uses an already existing sql2005 database to lookup user/pwd combinations). authentication mode="Forms" loginUrl="calendar/login.aspx" name=".myName" path="calendar/" defaultUrl="calendar/default.aspx" enableCrossAppRedirects="false" <location path="calendar/admin"> <system.web> <authorization> <allow roles="adm"/> <deny users="*"/> </authorization> </system.web> </location> But, I now have a need for a smaller subset of folks to gain access to another subfolder /conference with a DIFFERENT lookup to an sql2005 database for it's subfolder /conference/admin. Totally separate from the scenario in paragraph 2. If I put a stripped-out webconfig in the /conference subfolder with only the location path information and the login information using a different cookie name, will that work? Or, how can I do this? Janet

      L Offline
      L Offline
      led mike
      wrote on last edited by
      #2

      janetb99 wrote:

      If I put a stripped-out webconfig in the /conference subfolder with only the location path information and the login information using a different cookie name, will that work?

      Will what work? Putting a webconfig in a subfolder? They hide that information in the documentation[^]

      led mike

      J 1 Reply Last reply
      0
      • L led mike

        janetb99 wrote:

        If I put a stripped-out webconfig in the /conference subfolder with only the location path information and the login information using a different cookie name, will that work?

        Will what work? Putting a webconfig in a subfolder? They hide that information in the documentation[^]

        led mike

        J Offline
        J Offline
        janetb99
        wrote on last edited by
        #3

        Sorry to have offended, I was asking for a more experienced developer's advice. Hence a forum??? I know you referenced the documentation page, which I've tried to look through, but doesn't seem to address what I'm speaking of? The items I've found referencing this topic tend to imply that one must include a subWeb config file. That, however, stops any pages from within that sub area from referencing higher heirarchy master pages, sitemap files, etc. That seems terribly wasteful to me - duplicating everything in a subFolder/subWeb? So, is there a way to perhaps have two very different folders/login pages/roles referenced in the root webconfig file? OR, is there another way to do this of which I'm not aware? Better?

        L 1 Reply Last reply
        0
        • J janetb99

          Sorry to have offended, I was asking for a more experienced developer's advice. Hence a forum??? I know you referenced the documentation page, which I've tried to look through, but doesn't seem to address what I'm speaking of? The items I've found referencing this topic tend to imply that one must include a subWeb config file. That, however, stops any pages from within that sub area from referencing higher heirarchy master pages, sitemap files, etc. That seems terribly wasteful to me - duplicating everything in a subFolder/subWeb? So, is there a way to perhaps have two very different folders/login pages/roles referenced in the root webconfig file? OR, is there another way to do this of which I'm not aware? Better?

          L Offline
          L Offline
          led mike
          wrote on last edited by
          #4

          Well I just read your latest post and your first post several times again attempting to gain an understanding of what you are trying to ask and/or do but I just can't get there. I guess you do need a more experienced developers advice. Good luck

          led mike

          J 1 Reply Last reply
          0
          • L led mike

            Well I just read your latest post and your first post several times again attempting to gain an understanding of what you are trying to ask and/or do but I just can't get there. I guess you do need a more experienced developers advice. Good luck

            led mike

            J Offline
            J Offline
            janetb99
            wrote on last edited by
            #5

            Umm, let me try again. I'll do my best to be a bit clearer. (IIS6, Server2003) I have a web app that has a subfolder (/subfolderA) requiring a login page with forms authentication and roles. Goes against a custom sql2005 database for authentication and that's working fine. But, I have another subfolder (/subfolderB) that requires its own login that goes against a different sql2005 database for authentication - one having nothing to do with the other. When I tried to put a separate webconfig file in /subfolderB, it required that the subfolder be a separate app. That meant that references to MasterPages, images, etc., be in /subfolderB (or referenced explicitly). That seems to be contrary to what I've read on good development? Does anyone know a way in the original webconfig to have two separate login page references, or is there a better way to do this? Sorry for the confusion, and thanks. Janet

            L 1 Reply Last reply
            0
            • J janetb99

              Umm, let me try again. I'll do my best to be a bit clearer. (IIS6, Server2003) I have a web app that has a subfolder (/subfolderA) requiring a login page with forms authentication and roles. Goes against a custom sql2005 database for authentication and that's working fine. But, I have another subfolder (/subfolderB) that requires its own login that goes against a different sql2005 database for authentication - one having nothing to do with the other. When I tried to put a separate webconfig file in /subfolderB, it required that the subfolder be a separate app. That meant that references to MasterPages, images, etc., be in /subfolderB (or referenced explicitly). That seems to be contrary to what I've read on good development? Does anyone know a way in the original webconfig to have two separate login page references, or is there a better way to do this? Sorry for the confusion, and thanks. Janet

              L Offline
              L Offline
              led mike
              wrote on last edited by
              #6

              That seems mostly clear now. Yes you do seem to be running into an inherent premise that different logins means different applications. I assume there is some reason beyond your control that there are different membership databases since that would certainly not be a typical good practice design. Before accepting the situation and therefore solution as you have described it, I would certainly make an exhaustive effort to look for a way to make those two membership systems look like one from a project perspective. That would allow you to have a single sign on scenario for the site, the users and your project thereby eliminating all the added complexity for everyone just because of the poor membership database design. I would imagine this is possible and there might be a variety of choices in regards to how to do it. The first options would be to look at using database technology to integrate the two disparate systems.

              led mike

              1 Reply Last reply
              0
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • World
              • Users
              • Groups