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
  1. Home
  2. Web Development
  3. ASP.NET
  4. Custom membership provider

Custom membership provider

Scheduled Pinned Locked Moved ASP.NET
csharpasp-netdatabasewindows-adminhelp
3 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.
  • Y Offline
    Y Offline
    Yoyosch
    wrote on last edited by
    #1

    I implemented custom membership provider by deriving from MembershipProvider class. I added login control to my web page and associated my membership provider with my custom database, where I`m keeping all users. This works great. Whats more, I would like to enable 'Change password' scenario by using the standard ASP.NET control. I created dedicated web page for it and put this control onto form. When I`m willing to change my password (after I logged in to my web application), GetUser(string username, bool) method is being called from my custom membership provider. It`s cool, but why I`m getting my OS login name instead of the login which I used to log onto my web site? In other words: assume that I logged into my web application with {user: User1, password: qwert} credentials. I expect that GetUser method will pass 'User1' as a first argument. Currently it passes '[domainName]/[WindowsLoginName]'. I believe there is some magical switch in IIS (I`m using v7.5) or web.config file. Could you please help me?

    N 1 Reply Last reply
    0
    • Y Yoyosch

      I implemented custom membership provider by deriving from MembershipProvider class. I added login control to my web page and associated my membership provider with my custom database, where I`m keeping all users. This works great. Whats more, I would like to enable 'Change password' scenario by using the standard ASP.NET control. I created dedicated web page for it and put this control onto form. When I`m willing to change my password (after I logged in to my web application), GetUser(string username, bool) method is being called from my custom membership provider. It`s cool, but why I`m getting my OS login name instead of the login which I used to log onto my web site? In other words: assume that I logged into my web application with {user: User1, password: qwert} credentials. I expect that GetUser method will pass 'User1' as a first argument. Currently it passes '[domainName]/[WindowsLoginName]'. I believe there is some magical switch in IIS (I`m using v7.5) or web.config file. Could you please help me?

      N Offline
      N Offline
      Not Active
      wrote on last edited by
      #2

      Have you set the web.config to use your custom implementation or is it still the default provider?


      I know the language. I've read a book. - _Madmatt

      Y 1 Reply Last reply
      0
      • N Not Active

        Have you set the web.config to use your custom implementation or is it still the default provider?


        I know the language. I've read a book. - _Madmatt

        Y Offline
        Y Offline
        Yoyosch
        wrote on last edited by
        #3

        It is using my custom implementation - otherwise loggin feature would not work

        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